-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGruntfile.js
39 lines (29 loc) · 1.04 KB
/
Gruntfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
'use strict';
module.exports = function (grunt) {
require('load-grunt-tasks')(grunt);
grunt.loadTasks('grunt-tasks'); // Load all grunt tasks (modules) in the grunt-tasks directory.
grunt.registerTask('tasks', 'Lists available tasks', ['availabletasks']);
grunt.registerTask('build', 'Build templating tasks', function() {
grunt.task.run([
//'htmlmin',
'htmlConvert',
'webpack' //execute webpack at last
]);
});
grunt.registerTask('development', 'Build templating development tasks', function(){
process.env.NODE_ENV = 'development';
process.env.USE_MINIFIED = true;
if(grunt.option('skipTests')) {
grunt.log.warn('--skipTests option not supported');
}
if(grunt.option('skipLint')) {
grunt.log.warn('--skipLint option not supported');
}
grunt.task.run(['build']);
});
grunt.registerTask('production', 'Build templating production tasks', function(){
process.env.NODE_ENV = 'production';
process.env.USE_MINIFIED = true;
grunt.task.run(['build']);
});
};