forked from bscott/tessera
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Gruntfile.js
129 lines (124 loc) · 4.21 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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
module.exports = function(grunt) {
var path = require('path');
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
handlebars: {
all: {
options: {
partialsUseNamespace: true,
namespace: function(filename) {
return 'ds.' + path.dirname(filename).split('/').join('.')
},
processName: function(filename) {
var pieces = filename.split('/')
return pieces[pieces.length - 1].split('.')[0]
}
},
files: {
'tessera/static/templates.js' : [ 'templates/**/*.hbs']
}
}
},
concat: {
bundle_css: {
src: [
'tessera/static/css/bootstrap.css',
'tessera/static/css/bootstrap-callouts.css',
'tessera/static/css/bootstrap-editable.css',
'tessera/static/css/bootstrap-datetimepicker.css',
'tessera/static/css/bootstrapValidator.min.css',
'tessera/static/css/font-awesome.css',
'tessera/static/css/nv.d3.css',
'tessera/static/css/select2.css',
'tessera/static/css/select2-bootstrap.css',
'tessera/static/css/dataTables.bootstrap.css'
],
dest: 'tessera/static/css/bundle.css'
},
bundle: {
options: {
separator: ';'
},
src: [
'tessera/static/js/jquery-1.11.0.min.js',
'tessera/static/js/jquery.dataTables.js',
'tessera/static/js/moment.min.js',
'tessera/static/js/moment-timezone-with-data.min.js',
'tessera/static/js/marked.min.js',
'tessera/static/js/mousetrap.min.js',
'tessera/static/js/highlight.pack.js',
'tessera/static/js/bean.min.js',
'tessera/static/js/URI.min.js',
'tessera/static/js/handlebars.min.js',
'tessera/static/js/bootstrap.min.js',
'tessera/static/js/bootbox.min.js',
'tessera/static/js/d3.min.js',
'tessera/static/js/nv.d3.min.js',
'tessera/static/js/tagmanager.js',
'tessera/static/js/select2.min.js',
'tessera/static/js/bootstrap-editable.min.js',
'tessera/static/js/bootstrap-growl.min.js',
'tessera/static/js/bootstrap-datetimepicker.min.js',
'tessera/static/js/bootstrapValidator.min.js',
'tessera/static/js/limivorous.js',
'tessera/static/js/color-0.5.0.js',
'tessera/static/js/flot/jquery.flot.js',
'tessera/static/js/flot/jquery.flot.time.js',
'tessera/static/js/flot/jquery.flot.multihighlight.js',
'tessera/static/js/flot/jquery.flot.tooltip.js',
'tessera/static/js/flot/jquery.flot.stack.js',
'tessera/static/js/flot/jquery.flot.crosshair.js',
'tessera/static/js/flot/jquery.flot.axislabels.js',
'tessera/static/js/simple_statistics.js',
'tessera/static/js/equalize.min.js'
],
dest: 'tessera/static/bundle.js'
},
app: {
options: {
separator: ';'
},
src: [
'js/core.js',
'js/log.js',
'js/event.js',
'js/registry.js',
'js/action.js',
'js/transform.js',
'js/app.js',
'js/app/manager.js',
'js/app/helpers.js',
'tessera/static/templates.js',
'js/charts.js',
'js/charts/graphite.js',
'js/charts/nvd3.js',
'js/charts/flot.js',
'js/app/actions.js',
'js/property.js',
'js/factory.js',
'js/app/properties.js',
'js/mixins/**/*.js',
'js/models/**/*.js',
'js/extensions/**/*.js',
'js/app/handlers/*.js'
],
dest: 'tessera/static/app.js'
}
},
watch: {
files: [
'js/**/*.js',
'templates/**/*.hbs',
'tessera/static/js/**/*.js',
'tessera/static/css/**/*.css',
'tessera/static/tessera.css',
'tessera/static/tessera-typography.css'
],
tasks: ['handlebars', 'concat']
}
});
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-handlebars');
grunt.registerTask('default', ['handlebars', 'concat']);
}