This repository has been archived by the owner on Oct 2, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 18
/
Gruntfile.coffee
81 lines (69 loc) · 2.05 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
module.exports = (grunt) ->
grunt.initConfig
pkg: grunt.file.readJSON 'package.json'
jst:
app:
options:
processName: (filename) ->
filename.replace('_templates/', '').replace('._', '')
namespace: "Application.Templates"
files:
"_includes/js/templates.js": [ "_templates/*._", "_templates/fields/*._"]
watch:
cs:
files: ["_cs/*"]
tasks: [ 'coffeelint', 'concat', 'coffee']
options:
interrupt: true
forceWatchMethod: 'old'
jst:
files: ["_templates/*"]
tasks: 'jst'
options:
interrupt: true
forceWatchMethod: 'old'
coffeelint:
app: "_cs/**.coffee"
concat:
coffee:
src: ["_cs/*.coffee", "_cs/*/*.coffee"]
dest: "_app.coffee"
coffee:
app:
files:
"_includes/js/app.js": "_app.coffee"
uglify:
app:
files:
"_includes/js/app.js": "_includes/js/app.js"
templates:
files:
"_includes/js/templates.js": "_includes/js/templates.js"
cssmin:
compress:
files:
"_includes/css/app.css": "_includes/css/app.css"
clean:
cs: "_app.coffee"
dsstore: "**/.DS_Store"
csslint:
css:
src: "_includes/css/app.css"
rules:
"ids": false
coffeelintOptions:
max_line_length:
level: "ignore"
grunt.loadNpmTasks 'grunt-contrib-concat'
grunt.loadNpmTasks 'grunt-contrib-coffee'
grunt.loadNpmTasks 'grunt-contrib-uglify'
grunt.loadNpmTasks 'grunt-contrib-watch'
grunt.loadNpmTasks 'grunt-contrib-cssmin'
grunt.loadNpmTasks 'grunt-contrib-clean'
grunt.loadNpmTasks 'grunt-coffeelint'
grunt.loadNpmTasks 'grunt-jekyll'
grunt.loadNpmTasks 'grunt-contrib-imagemin'
grunt.loadNpmTasks 'grunt-css'
grunt.loadNpmTasks 'grunt-contrib-jst'
grunt.registerTask 'cs', ["coffeelint", "concat", "coffee"]
grunt.registerTask 'default', ["cs", "jst", "uglify", "cssmin", "clean"]