Skip to content

Instantly share code, notes, and snippets.

@lucasdinonolte
Created November 11, 2012 20:25
Show Gist options
  • Save lucasdinonolte/4056145 to your computer and use it in GitHub Desktop.
Save lucasdinonolte/4056145 to your computer and use it in GitHub Desktop.
Default Cakefile
exec = require('child_process').exec
config =
sassDir : "scss" # SCSS/SASS Folder
cssDir : "css" # CSS Folder
coffeeDir : "src" # CoffeeScript Folder
jsDir : "js" # JavaScript Folder
task "watch", "Watches Assets for changes and compiles them", ->
exec "sass --watch #{config.sassDir}:#{config.cssDir}", (err, stdout, stderr) ->
console.log "Watching SCSS"
exec "coffee -o #{config.jsDir} -cw #{config.coffeeDir}", (err, stdout, stderr) ->
console.log "Watching CoffeeScript"
task "test", "run the tests", ->
exec "mocha --compilers coffee:coffee-script", (err, stdout, stderr) ->
console.log stdout
console.log stderr if stderr
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment