forked from ksylvest/jquery-gridly
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Cakefile
32 lines (24 loc) · 962 Bytes
/
Cakefile
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
PROJECT = "jquery.gridly"
{spawn, exec} = require "child_process"
command = (name, args...) ->
proc = spawn name, args
proc.stderr.on "data", (buffer) ->
console.log buffer.toString()
proc.stdout.on "data", (buffer) ->
console.log buffer.toString()
proc.on "exit", (status) -> process.exit(1) if status != 0
task "watch", "SASS and CoffeeScript", (options) ->
command "sass", "--sourcemap=none", "--watch", "stylesheets:stylesheets"
command "sass", "--sourcemap=none", "--watch", "spec:spec"
command "coffee", "-wc", "javascripts"
command "coffee", "-wc", "spec"
task "compile", "HAML", (opions) ->
command "haml", "index.haml", "index.html"
task "package", "Package CSS and JS", (options) ->
command "zip", "packages/#{PROJECT}.zip",
"javascripts/#{PROJECT}.js",
"stylesheets/#{PROJECT}.css",
command "tar", "-cf",
"packages/#{PROJECT}.tar",
"javascripts/#{PROJECT}.js",
"stylesheets/#{PROJECT}.css",