1 | module.exports = (grunt) ->
|
2 | require('time-grunt') grunt
|
3 |
|
4 | grunt.config.init
|
5 | clean:
|
6 | build: [
|
7 | 'index.js'
|
8 | 'lib'
|
9 | ]
|
10 |
|
11 | coffee:
|
12 | enju:
|
13 | expand: yes
|
14 | flatten: no
|
15 | cwd: 'src'
|
16 | src: ['**/*.coffee']
|
17 | dest: './'
|
18 | ext: '.js'
|
19 |
|
20 | watch:
|
21 | enju:
|
22 | files: ['src/**/*.coffee']
|
23 | tasks: ['coffee:enju']
|
24 | options:
|
25 | spawn: no
|
26 |
|
27 |
|
28 |
|
29 |
|
30 | grunt.registerTask 'dev', ->
|
31 | grunt.task.run [
|
32 | 'clean:build'
|
33 | 'coffee:enju'
|
34 | 'watch'
|
35 | ]
|
36 |
|
37 | grunt.registerTask 'build', ->
|
38 | grunt.task.run [
|
39 | 'clean:build'
|
40 | 'coffee:enju'
|
41 | ]
|
42 |
|
43 | grunt.loadNpmTasks 'grunt-contrib-clean'
|
44 | grunt.loadNpmTasks 'grunt-contrib-coffee'
|
45 | grunt.loadNpmTasks 'grunt-contrib-watch'
|