-
Notifications
You must be signed in to change notification settings - Fork 0
/
Gruntfile.coffee
115 lines (102 loc) · 2.46 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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
coffee_lint_option =
no_tabs:
level: "error"
indentation:
level: "warn"
arrow_spacing:
level: "error"
cyclomatic_complexity:
level: "ignore"
empty_constructor_needs_parens:
level: "error"
max_line_length:
level: "ignore"
line_endings:
value: "unix"
newlines_after_classes:
level: "error"
no_empty_param_list:
level: "error"
no_implicit_parens:
level: "error"
non_empty_constructor_needs_parens:
level: "error"
space_operators:
level: "warn"
no_unnecessary_fat_arrows:
level: "error"
coffee_files = ["src/app.coffee","src/Model/*.coffee","src/Util/*.coffee","src/View/*.coffee","src/Controller/*.coffee","src/Controller/*/*.coffee","src/MainController.coffee"]
module.exports = (grunt) ->
grunt.initConfig(
pkg: grunt.file.readJSON("package.json")
watch:
src:
files: ["src/*.coffee","src/*/*.coffee","src/*/*/*.coffee"]
tasks: ["coffeelint:src","coffee:src"]
options:
livereload : true
resource:
files: 'resource/style/**/*.scss'
tasks: ['scsslint','compass']
options:
livereload : true
coffee:
options:
join: true
bare: true
src:
options:
sourceMap: true
files:
"dev/app.js" : coffee_files
coffeelint:
src:
files:
src: coffee_files
options:
coffee_lint_option
scsslint:
allFiles: ['resource/style/*.scss']
options:
config: 'config/scss-lint.yml'
compass:
dist:
options:
sassDir: "resource/style"
imageDir: "resource"
cssDir: "dev"
generatedImagesDir: "dev"
relativeAssets: true
yuidoc:
dist:
name: "music sheet"
description: "sheetgen"
version: "0.0.1"
options:
paths: 'src'
outdir: 'docs/'
syntaxtype: "coffee"
extension: ".coffee"
selleck: "true"
attributesEmit: "true"
grunt.loadNpmTasks(task) for task in [
"grunt-coffeelint"
"grunt-contrib-coffee"
"grunt-exec"
"grunt-contrib-watch"
"grunt-contrib-connect"
"grunt-open"
"grunt-contrib-yuidoc"
"grunt-contrib-compass"
"grunt-scss-lint"
]
grunt.registerTask("develop","develop task"
[
"coffeelint:src"
"coffee:src"
"scsslint"
"compass"
"yuidoc"
]
)
)