2018-11-23 15:44:58 +00:00
|
|
|
/* eslint-env node, es6 */
|
2016-02-29 19:48:14 +00:00
|
|
|
module.exports = function ( grunt ) {
|
2018-03-19 16:07:25 +00:00
|
|
|
var conf = grunt.file.readJSON( 'extension.json' );
|
|
|
|
|
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-03-19 16:07:25 +00:00
|
|
|
banana: conf.MessagesDirs,
|
2018-02-07 21:08:04 +00:00
|
|
|
eslint: {
|
2019-04-03 22:44:45 +00:00
|
|
|
options: {
|
2019-05-06 20:56:34 +00:00
|
|
|
extensions: [ '.js', '.json' ],
|
2019-04-03 22:44:45 +00:00
|
|
|
cache: true
|
|
|
|
},
|
2016-02-29 19:48:14 +00:00
|
|
|
all: [
|
2019-05-06 20:56:34 +00:00
|
|
|
'**/*.js{,on}',
|
2017-08-19 06:52:42 +00:00
|
|
|
'!node_modules/**',
|
|
|
|
'!vendor/**'
|
2017-04-16 17:53:12 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
stylelint: {
|
|
|
|
all: [
|
|
|
|
'**/*.css',
|
2017-08-19 06:52:42 +00:00
|
|
|
'!node_modules/**',
|
|
|
|
'!vendor/**'
|
2016-02-29 19:48:14 +00:00
|
|
|
]
|
|
|
|
}
|
|
|
|
} );
|
|
|
|
|
2019-05-06 20:56:34 +00:00
|
|
|
grunt.registerTask( 'test', [ 'eslint', 'stylelint', 'banana' ] );
|
2016-02-29 19:48:14 +00:00
|
|
|
grunt.registerTask( 'default', 'test' );
|
|
|
|
};
|