-
Notifications
You must be signed in to change notification settings - Fork 1
/
Gruntfile.coffee
57 lines (49 loc) · 1.18 KB
/
Gruntfile.coffee
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
module.exports = (grunt) ->
grunt.initConfig
pkg: grunt.file.readJSON('package.json')
clean:
lib: ['lib']
coffeeredux:
options:
bare: no
sourceMap: no
compile:
files: [
expand: yes
cwd: 'src/'
src: ['**/*.coffee']
dest: 'lib/'
ext: '.js'
]
jshint:
options:
jshintrc: '.jshintrc'
main: 'lib/pegcoffee.js'
watch:
coffee:
files: [
'src/**/*.coffee'
'test/**/*.coffee'
]
tasks: ['test', 'build']
js:
files: 'lib/pegcoffee.js'
tasks: ['lint']
mochacli:
options:
require: ['should']
compilers: ['coffee:coffee-script']
reporter: 'spec'
coffee: ['test/*.coffee']
grunt.loadNpmTasks task for task in [
'grunt-contrib-watch'
'grunt-contrib-clean'
'grunt-coffee-redux'
'grunt-contrib-jshint'
'grunt-markdown'
'grunt-mocha-cli'
]
grunt.registerTask 'test', ['mochacli']
grunt.registerTask 'build', ['clean', 'coffeeredux']
grunt.registerTask 'lint', ['jshint']
grunt.registerTask 'default', ['test', 'build', 'lint']