Skip to content

Commit

Permalink
fix: The --hurry option
Browse files Browse the repository at this point in the history
  • Loading branch information
brandonocasey committed Sep 13, 2018
1 parent a75f375 commit e407277
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
6 changes: 3 additions & 3 deletions generators/app/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@ module.exports = {
LICENSE_DEFAULT,

PROMPT_DEFAULTS: {
docs: false,
css: false,
docs: true,
css: true,
prepush: false,
precommit: true,
lang: false,
lang: true,
license: LICENSE_DEFAULT,
pluginType: 'advanced',
name: path.basename(process.cwd()).replace(/^videojs-/, '')
Expand Down
5 changes: 5 additions & 0 deletions generators/app/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,10 @@ module.exports = class extends Generator {
// purposes of the prompt (otherwise it will be rejected by validation).
defaults.name = naming.getBasicName(defaults.name);

// we need to default the description to an empty string for
// --hurry
defaults.description = '';

// The package.json stores a value from `LICENSE_NAMES`, so in that
// case, we need to find the key instead of the value.
if (pkg && pkg.license && pkg.license === defaults.license) {
Expand Down Expand Up @@ -242,6 +246,7 @@ module.exports = class extends Generator {
*/
prompting() {
if (this.options.skipPrompt) {
_.assign(this._preconfigs, this._getPromptDefaults());
return;
}

Expand Down

0 comments on commit e407277

Please sign in to comment.