-
Notifications
You must be signed in to change notification settings - Fork 3
/
Cakefile
30 lines (23 loc) · 1.04 KB
/
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
{exec} = require 'child_process'
task 'build', 'Build project from src/*.coffee to lib/*.js', ->
exec 'coffee --compile --output lib/ src/', (err, stdout, stderr) ->
throw err if err
console.log 'Coffee compiled to JS...'
exec 'rm -f lib/app.js', (err, stdout, stderr) ->
throw err if err
console.log 'app.js removed from lib...'
exec 'rm -f lib/test.js', (err, stdout, stderr) ->
throw err if err
console.log 'test.js removed from lib...'
exec 'coffee --compile --output ./ src/app.coffee', (err, stdout, stderr) ->
throw err if err
console.log 'app.js placed in lib...'
exec 'coffee --compile --output test/ src/test.coffee', (err, stdout, stderr) ->
throw err if err
console.log 'test.js placed in lib...'
exec 'cson2json src/config.cson > lib/config.json', (err, stdout, stderr) ->
throw err if err
console.log 'config compiled to json...'
exec 'cson2json src/feeds.cson > lib/feeds.json', (err, stdout, stderr) ->
throw err if err
console.log 'feeds compiled to json...'