Skip to content

Commit

Permalink
features input example @todo choose features
Browse files Browse the repository at this point in the history
  • Loading branch information
akella committed Dec 6, 2015
1 parent cd0b596 commit e1e4286
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 1 deletion.
1 change: 0 additions & 1 deletion generators/app/utils/generate.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ var generate = {

appfiles: function () {
helpers.copy.call(this, '_package.json', 'package.json', this.prompts);
console.log(this.prompts);
// helpers.copy.call(this, '_bower.json', 'bower.json', this.prompts);
},

Expand Down
34 changes: 34 additions & 0 deletions generators/app/utils/prompts.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,40 @@ module.exports = {
name: 'iconfont',
message: 'Create iconfont from SVG?',
default: true
},
{
type: 'checkbox',
name: 'features',
message: 'Choose additional features',
choices: [{
name: 'jQuery',
value: 'useJquery',
checked: true
}, {
name: 'Image optimisation',
value: 'useOptim',
checked: false
}, {
name: 'Automatic sprites',
value: 'useSprites',
checked: false
}, {
name: 'Icomoon',
value: 'useIcomoon',
checked: false
}, {
name: 'Bootstrap',
value: 'useBootstrap',
checked: false
}, {
name: 'Modernizr',
value: 'useModernizr',
checked: false
}, {
name: 'Browserify',
value: 'useBrowserify',
checked: false
}]
}],

update: [{
Expand Down
1 change: 1 addition & 0 deletions generators/app/utils/setPrompts.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ module.exports = function (answers) {
this.prompts.spritesmith = answers.spritesmith;
this.prompts.jade = answers.jade;
this.prompts.iconfont = answers.iconfont;
this.prompts.bootstrap = answers.bootstrap;
// this.prompts.cssPrefix = answers.cssPreprocessor === 'scss' ? '_' : '';
this.prompts.features = {};

Expand Down

0 comments on commit e1e4286

Please sign in to comment.