Repository navigation
Expand file tree
/
Copy pathGruntfile.js
More file actions
60 lines (53 loc) · 1.47 KB
/
Copy pathGruntfile.js
File metadata and controls
60 lines (53 loc) · 1.47 KB
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
module.exports = function (grunt) {
//project configurations
grunt.initConfig({
uglify: {
options: {
banner: "/*! <%= grunt.template.today() %> */\n"
},
build: {
src: ["dist/built.js"],
dest: "dist/threesixty_initialize.js"
}
},
watch: {
scripts: {
files: ["js/*"],
// tasks: ["concat","uglify"]
tasks: ["concat"]
}
},
concat: {
options: {
separator: ';',
},
dist: {
src: ['js/three.js',
'js/OrbitControls.js',
'js/Detector.js',
'js/Init.js',
'js/dat.gui.min.js',
'js/MTLLoader.js',
'js/OBJLoader.js',
'js/EffectComposer.js',
'js/RenderPass.js',
'js/ShaderPass.js',
'js/SAOShader.js',
'js/CopyShader.js',
'js/SSAOShader.js',
'js/SSAOPass.js',
'js/SSAARenderPass.js',
'js/TAARenderPass.js'],
dest: 'dist/built.js',
},
},
});
//load uglify plugin
grunt.loadNpmTasks('grunt-contrib-uglify');
//create default task
grunt.registerTask("default", ["concat","uglify"]);
//watch files
grunt.loadNpmTasks('grunt-contrib-watch');
// concat the files
grunt.loadNpmTasks('grunt-contrib-concat');
};