@@ -101,6 +101,11 @@ var check = yargs.createCheck()
101101 if ( typeof value !== 'boolean' ) {
102102 return 'gitignore must be a boolean' ;
103103 }
104+ } ,
105+ editorconfig : function ( value ) {
106+ if ( typeof value !== 'boolean' ) {
107+ return 'editorconfig must be a boolean' ;
108+ }
104109 }
105110 } )
106111 . commit ( ) ;
@@ -123,6 +128,7 @@ yargs.getInstance('init')
123128 '* karma.conf.js exists, else create --karma' ,
124129 '* .jshintrc exists, else create --jshint' ,
125130 '* .gitignore exists, else create --gitignore' ,
131+ '* .editorconfig exists, else create --editorconfig' ,
126132 '' ,
127133 'If a package.json is present initialisation will occur in the current directory. Otherwise a sub-directory is' +
128134 'created per the project name' ,
@@ -286,6 +292,10 @@ gulp.task('init:gitignore', function () {
286292 copyTemplateSync ( '.gitignore' ) ;
287293} ) ;
288294
295+ gulp . task ( 'init:editorconfig' , function ( ) {
296+ copyTemplateSync ( '.editorconfig' ) ;
297+ } ) ;
298+
289299function padded ( length ) {
290300 return function ( text ) {
291301 return ( text + ( new Array ( length ) ) . join ( ' ' ) ) . slice ( 0 , length ) ;
0 commit comments