2018-02-07 21:08:04 +00:00
|
|
|
/* eslint-env node */
|
2016-02-29 19:48:14 +00:00
|
|
|
module.exports = function ( grunt ) {
|
|
|
|
grunt.loadNpmTasks( 'grunt-jsonlint' );
|
2016-12-23 20:04:34 +00:00
|
|
|
grunt.loadNpmTasks( 'grunt-banana-checker' );
|
2018-02-07 21:08:04 +00:00
|
|
|
grunt.loadNpmTasks( 'grunt-eslint' );
|
2017-04-16 17:53:12 +00:00
|
|
|
grunt.loadNpmTasks( 'grunt-stylelint' );
|
2016-02-29 19:48:14 +00:00
|
|
|
|
|
|
|
grunt.initConfig( {
|
2018-02-07 21:08:04 +00:00
|
|
|
jsonlint: {
|
2016-02-29 19:48:14 +00:00
|
|
|
all: [
|
2018-02-07 21:08:04 +00:00
|
|
|
'**/*.json',
|
2017-08-19 06:52:42 +00:00
|
|
|
'!node_modules/**',
|
|
|
|
'!vendor/**'
|
2016-02-29 19:48:14 +00:00
|
|
|
]
|
|
|
|
},
|
2016-12-23 20:04:34 +00:00
|
|
|
banana: {
|
|
|
|
all: 'i18n/'
|
|
|
|
},
|
2018-02-07 21:08:04 +00:00
|
|
|
eslint: {
|
2016-02-29 19:48:14 +00:00
|
|
|
all: [
|
2018-02-07 21:08:04 +00:00
|
|
|
'**/*.js',
|
2017-08-19 06:52:42 +00:00
|
|
|
'!node_modules/**',
|
2018-03-30 06:55:03 +00:00
|
|
|
'!modules/mode-abusefilter.js',
|
2017-08-19 06:52:42 +00:00
|
|
|
'!vendor/**'
|
2017-04-16 17:53:12 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
stylelint: {
|
|
|
|
all: [
|
|
|
|
'**/*.css',
|
2017-08-19 06:52:42 +00:00
|
|
|
'!node_modules/**',
|
2018-03-30 06:55:03 +00:00
|
|
|
'!modules/mode-abusefilter.js',
|
2017-08-19 06:52:42 +00:00
|
|
|
'!vendor/**'
|
2016-02-29 19:48:14 +00:00
|
|
|
]
|
|
|
|
}
|
|
|
|
} );
|
|
|
|
|
2018-02-07 21:08:04 +00:00
|
|
|
grunt.registerTask( 'test', [ 'jsonlint', 'banana', 'eslint', 'stylelint' ] );
|
2016-02-29 19:48:14 +00:00
|
|
|
grunt.registerTask( 'default', 'test' );
|
|
|
|
};
|