2018-09-16 21:15:21 +00:00
|
|
|
/* eslint-env node */
|
2015-06-17 19:05:04 +00:00
|
|
|
module.exports = function ( grunt ) {
|
|
|
|
grunt.loadNpmTasks( 'grunt-jsonlint' );
|
2015-10-11 20:03:10 +00:00
|
|
|
grunt.loadNpmTasks( 'grunt-banana-checker' );
|
2018-09-16 21:15:21 +00:00
|
|
|
grunt.loadNpmTasks( 'grunt-eslint' );
|
|
|
|
grunt.loadNpmTasks( 'grunt-stylelint' );
|
2015-06-17 19:05:04 +00:00
|
|
|
grunt.initConfig( {
|
2018-09-16 21:15:21 +00:00
|
|
|
jsonlint: {
|
2015-10-11 20:03:10 +00:00
|
|
|
all: [
|
2018-09-16 21:15:21 +00:00
|
|
|
'**/*.json',
|
|
|
|
'!node_modules/**',
|
|
|
|
'!vendor/**'
|
2015-10-11 20:03:10 +00:00
|
|
|
]
|
|
|
|
},
|
2015-06-17 19:05:04 +00:00
|
|
|
banana: {
|
|
|
|
all: 'i18n/'
|
|
|
|
},
|
2018-09-16 21:15:21 +00:00
|
|
|
eslint: {
|
2019-08-01 07:04:22 +00:00
|
|
|
options: {
|
|
|
|
cache: true,
|
|
|
|
reportUnusedDisableDirectives: true
|
|
|
|
},
|
2015-06-17 19:05:04 +00:00
|
|
|
all: [
|
2018-09-16 21:15:21 +00:00
|
|
|
'**/*.js',
|
|
|
|
'!node_modules/**',
|
|
|
|
'!vendor/**'
|
|
|
|
]
|
|
|
|
},
|
|
|
|
stylelint: {
|
|
|
|
all: [
|
|
|
|
'**/*.css',
|
2015-10-11 20:03:10 +00:00
|
|
|
'!node_modules/**',
|
|
|
|
'!vendor/**'
|
2015-06-17 19:05:04 +00:00
|
|
|
]
|
|
|
|
}
|
|
|
|
} );
|
2018-09-16 21:15:21 +00:00
|
|
|
grunt.registerTask( 'test', [ 'jsonlint', 'banana', 'eslint', 'stylelint' ] );
|
2015-06-17 19:05:04 +00:00
|
|
|
grunt.registerTask( 'default', 'test' );
|
|
|
|
};
|