-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGruntfile.js
82 lines (79 loc) · 2.5 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
module.exports = function(grunt) {
var pkg = grunt.file.readJSON('package.json');
grunt.initConfig({
connect: {
support: {
options: {
hostname: '*',
port: 3000,
base: 'support/'
}
}
},
concat: {
options: {
separator: '\n'
},
dist: {
src: [
'src/Tenjoh.js',
'src/component/Array.js',
'src/component/DOM.js',
'src/component/Event.js',
'src/component/XHR.js',
'src/component/Router.js',
'src/component/Cache.js',
'src/component/Storage.js',
'src/component/ResourceManager.js',
'src/component/Compiler.js',
'src/component/UI/UIFactory.js',
'src/component/UI/Partial.js',
'src/component/UI/Fillter.js',
'src/component/UI/Animation.js',
'src/component/UI/LayeredImage.js',
'src/widget/Repeat.js',
'src/widget/LazyImage.js',
'src/widget/Show.js',
'src/widget/Hide.js',
'src/fillter/Element.js',
'src/fillter/DateFormatter.js',
'src/fillter/Before.js',
'src/fillter/NumberFormatter.js',
'src/RootController.js',
'src/Controller.js'
],
dest: 'build/tenjoh.js'
}
},
compass: {
dev: {
options: {
sassDir: 'support/assets/style/',
cssDir: 'support/css/'
}
}
},
watch: {
build: {
files: ['src/**/*.js'],
tasks: ['concat'],
options: {
livereload: true
}
},
support: {
files: ['support/asset/style/**/*.scss'],
tasks: ['compass'],
options: {
livereload: true
}
}
}
});
for (var key in pkg.devDependencies) {
if (/grunt-/.test(key)) {
grunt.loadNpmTasks(key);
}
}
grunt.registerTask('dev', ['connect', 'watch']);
};