-
Notifications
You must be signed in to change notification settings - Fork 10
/
Gruntfile.coffee
93 lines (77 loc) · 1.91 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
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
83
84
85
86
87
88
89
90
91
92
93
module.exports = (grunt) ->
# Project configuration.
grunt.initConfig
pkg: grunt.file.readJSON('package.json')
watch:
module:
files: ["_src/**/*.coffee"]
tasks: [ "coffee:base" ]
coffee:
base:
expand: true
cwd: '_src',
src: ["**/*.coffee"]
dest: ''
ext: '.js'
clean:
base:
src: [ "lib", "test" ]
includereplace:
pckg:
options:
globals:
version: "0.0.4"
prefix: "@@"
suffix: ''
files:
"index.js": ["index.js"]
mochacli:
options:
require: [ "should" ]
reporter: "spec"
bail: false
timeout: 3000
slow: 3
main:
src: [ "test/main.js" ]
options:
env:
severity_awss3form: "info"
travis:
src: [ "test/travis.js" ]
options:
env:
severity_awss3form: "info"
docker:
serverdocs:
expand: true
src: ["_src/**/*.coffee", "README.md"]
dest: "_docs/"
options:
onlyUpdated: false
colourScheme: "autumn"
ignoreHidden: false
sidebarState: true
exclude: false
lineNums: true
js: []
css: []
extras: []
# Load npm modules
grunt.loadNpmTasks "grunt-contrib-watch"
grunt.loadNpmTasks "grunt-contrib-coffee"
grunt.loadNpmTasks "grunt-contrib-clean"
grunt.loadNpmTasks "grunt-mocha-cli"
grunt.loadNpmTasks "grunt-include-replace"
grunt.loadNpmTasks "grunt-docker"
# just a hack until this issue has been fixed: https://github.com/yeoman/grunt-regarde/issues/3
grunt.option('force', not grunt.option('force'))
# ALIAS TASKS
grunt.registerTask "default", "build"
grunt.registerTask "docs", "docker"
grunt.registerTask "clear", [ "clean:base" ]
grunt.registerTask "test", [ "build", "mochacli:main" ]
grunt.registerTask "test-travis", [ "mochacli:travis" ]
# build the project
grunt.registerTask "build", [ "clear", "coffee:base", "includereplace" ]
grunt.registerTask "build-dev", [ "build", "docs", "test" ]