-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathGruntfile.coffee
38 lines (30 loc) · 977 Bytes
/
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
module.exports = (grunt) ->
# load all grunt tasks
require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks)
# load package config
pkg = grunt.file.readJSON('package.json')
grunt.initConfig
# nodemon
nodemon:
options:
args: ['development']
nodeArgs: ['--debug']
watch: [
'lib',
'test'
]
legacyWatch: true
# nodemon.test
test:
script: 'test/index.js'
options:
callback: (nodemon) ->
nodemon.on 'log', (evt) ->
console.log evt.colour
nodemon.on 'restart', () ->
console.log 'restart test.'
# register task
grunt.registerTask 'default', () ->
grunt.task.run [
'nodemon'
]