forked from jagenjo/litegraph.js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gruntfile.js
47 lines (44 loc) · 1.38 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
40
41
42
43
44
45
46
47
module.exports = function (grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
projectFiles: ['src/litegraph.js',
'src/nodes/base.js',
'src/nodes/events.js',
'src/nodes/interface.js',
'src/nodes/input.js',
'src/nodes/math.js',
'src/nodes/logic.js',
'src/nodes/image.js',
'src/nodes/gltextures.js',
'src/nodes/glfx.js',
'src/nodes/midi.js',
'src/nodes/audio.js',
'src/nodes/network.js'
],
concat: {
build: {
src: '<%= projectFiles %>',
dest: 'build/litegraph.js'
}
},
closureCompiler: {
options: {
compilerFile: 'node_modules/google-closure-compiler/compiler.jar',
compilerOpts: {
formatting: 'pretty_print',
warning_level: 'default'
},
d32: false, // will use 'java -client -d32 -jar compiler.jar'
TieredCompilation: false// will use 'java -server -XX:+TieredCompilation -jar compiler.jar',
// ,output_wrapper: '"var LiteGraph = (function(){%output% return LiteGraph;}).call(this);"' //* Make container for all
},
targetName: {
src: '<%= projectFiles %>',
dest: 'build/litegraph.min.js'
}
}
})
grunt.loadNpmTasks('grunt-contrib-concat')
grunt.loadNpmTasks('grunt-closure-tools')
grunt.registerTask('build', ['concat:build', 'closureCompiler'])
}