Skip to content

Commit

Permalink
add error message if bot keep- and out-file-extension is used
Browse files Browse the repository at this point in the history
  • Loading branch information
eps1lon committed Feb 28, 2019
1 parent 003d658 commit e12d5e5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/babel-cli/src/babel/options.js
Expand Up @@ -215,6 +215,12 @@ export default function parseArgv(args: Array<string>) {
);
}

if (commander.keepFileExtension && commander.outFileExtension) {
errors.push(
"--out-file-extension cannot be used with --keep-file-extension",
);
}

if (errors.length) {
console.error("babel:");
errors.forEach(function(e) {
Expand Down

0 comments on commit e12d5e5

Please sign in to comment.