From 10c253a2d86c9d5e872da9fd6e41fe54fb93cd05 Mon Sep 17 00:00:00 2001 From: James George Date: Wed, 30 Jan 2019 19:27:37 +0530 Subject: [PATCH] chore: validates multiple arguments for vue create command (#3195) --- packages/@vue/cli/bin/vue.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/@vue/cli/bin/vue.js b/packages/@vue/cli/bin/vue.js index 4ae3f919ad..1dbd12b00a 100755 --- a/packages/@vue/cli/bin/vue.js +++ b/packages/@vue/cli/bin/vue.js @@ -65,6 +65,10 @@ program .option('-b, --bare', 'Scaffold project without beginner instructions') .action((name, cmd) => { const options = cleanArgs(cmd) + + if (minimist(process.argv.slice(3))._.length > 1) { + console.log(chalk.yellow('\n Info: You provided more than one argument. The first one will be used as the app\'s name, the rest are ignored.')) + } // --git makes commander to default git to true if (process.argv.includes('-g') || process.argv.includes('--git')) { options.forceGit = true