Skip to content

Commit

Permalink
Auto merge of #5486 - Serabe:patch-1, r=kellyselden
Browse files Browse the repository at this point in the history
[ENHANCEMENT] Add `directory` option to `addon` command

The `addon` command is built upon `new` but there was no option for `--directory`. This PR just adds that option.

I found no place to add a test for the options.
  • Loading branch information
homu committed Feb 19, 2016
2 parents 1acae10 + cbf924a commit 4bba817
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/commands/addon.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ module.exports = NewCommand.extend({
{ name: 'skip-npm', type: Boolean, default: false, aliases: ['sn'] },
{ name: 'skip-bower', type: Boolean, default: false, aliases: ['sb'] },
{ name: 'skip-git', type: Boolean, default: false, aliases: ['sg'] },
{ name: 'directory', type: String , aliases: ['dir'] }
],

anonymousOptions: [
Expand Down
8 changes: 8 additions & 0 deletions tests/acceptance/help-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ ember addon \u001b[33m<addon-name>\u001b[39m \u001b[36m<options...>\u001b[39m' +
\u001b[90maliases: -sb\u001b[39m' + EOL + '\
\u001b[36m--skip-git\u001b[39m \u001b[36m(Boolean)\u001b[39m \u001b[36m(Default: false)\u001b[39m' + EOL + '\
\u001b[90maliases: -sg\u001b[39m' + EOL + '\
\u001b[36m--directory\u001b[39m \u001b[36m(String)\u001b[39m' + EOL + '\
\u001b[90maliases: -dir <value>\u001b[39m' + EOL + '\
' + EOL + '\
ember build \u001b[36m<options...>\u001b[39m' + EOL + '\
Builds your app and places it into the output path (dist/ by default).' + EOL + '\
Expand Down Expand Up @@ -276,6 +278,12 @@ ember version \u001b[36m<options...>\u001b[39m' + EOL + '\
aliases: ['sg'],
key: 'skipGit',
required: false
},
{
name: 'directory',
aliases: ['dir'],
key: 'directory',
required: false
}
],
anonymousOptions: ['<addon-name>']
Expand Down

0 comments on commit 4bba817

Please sign in to comment.