forked from teijo/jquery-bracket
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Gruntfile.js
61 lines (59 loc) · 1.47 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
module.exports = function(grunt) {
grunt.initConfig({
licenseString: '/* jQuery Bracket | Copyright (c) Teijo Laine 2011-<%= grunt.template.today("yyyy") %> | Licenced under the MIT licence */',
pkg: grunt.file.readJSON('package.json'),
watch: {
scripts: {
files: ['src/jquery.bracket.sass', 'src/jquery.bracket.ts'],
tasks: ['default']
}
},
shell: {
compass: {
command: 'compass compile'
}
},
cssmin: {
options: {
banner: '<%= licenseString %>'
},
dist: {
files: {
'dist/<%= pkg.name %>.min.css': 'dist/<%= pkg.name %>.css'
}
}
},
uglify: {
options: {
compress: true,
banner: '<%= licenseString %>\n'
},
dist: {
files: {
'dist/<%= pkg.name %>.min.js': ['dist/<%= pkg.name %>.js']
}
}
},
tslint: {
options: {
configuration: grunt.file.readJSON("tslint.json")
},
files: {
src: ['src/*.ts']
}
},
typescript: {
base: {
src: ['src/*.ts'],
dest: 'dist/jquery.bracket.js'
}
}
});
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-shell');
grunt.loadNpmTasks('grunt-typescript');
grunt.loadNpmTasks('grunt-tslint');
grunt.loadNpmTasks('grunt-css');
grunt.registerTask('default', ['tslint', 'shell', 'typescript', 'uglify', 'cssmin']);
};