Commit 4c66101e authored by Robert Knight's avatar Robert Knight

Read parsed CLI options from `commander.opts()`

See https://github.com/tj/commander.js/blob/master/CHANGELOG.md#migration-tips.
parent 394953bf
......@@ -39,7 +39,7 @@ function parseCommandLine() {
.parse(process.argv);
return {
grep: commander.grep,
grep: commander.opts().grep,
};
}
......
......@@ -154,12 +154,14 @@ commander
.option('--no-cache-entry', 'Prevent CDN/browser caching of entry point')
.parse(process.argv);
const cliOpts = commander.opts();
const options = {
tag: commander.tag,
cacheEntry: commander.cacheEntry,
tag: cliOpts.tag,
cacheEntry: cliOpts.cacheEntry,
};
uploadPackageToS3(commander.bucket, options).catch(err => {
uploadPackageToS3(cliOpts.bucket, options).catch(err => {
console.error('Failed to upload S3 package', err);
process.exit(1);
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment