Skip to content

Instantly share code, notes, and snippets.

@shangaslammi
Created October 20, 2012 16:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shangaslammi/3924016 to your computer and use it in GitHub Desktop.
Save shangaslammi/3924016 to your computer and use it in GitHub Desktop.
Common grunt-file template
module.exports = (grunt) ->
grunt.initConfig
coffee:
compile:
files:
"public/js/modules/*.js": "src/coffee/**/*.coffee"
options:
flatten: false
bare: false
jade:
compile:
files:
"public/index.html": "src/jade/index.jade"
stylus:
compile:
files:
"public/css/styles.css": "src/stylus/*.styl"
options:
compress: true
server:
port: 8000
base: "public"
watch:
coffee:
files: ["src/coffee/**/*.coffee"]
tasks: ["coffee reload"]
stylus:
files: ["src/stylus/*.styl"]
tasks: ["stylus reload"]
jade:
files: ["src/jade/*.jade"]
tasks: ["jade reload"]
reload:
port: 6001
proxy:
host: 'localhost'
port: 8000
grunt.loadNpmTasks "grunt-reload"
grunt.loadNpmTasks "grunt-contrib-coffee"
grunt.loadNpmTasks "grunt-contrib-jade"
grunt.loadNpmTasks "grunt-contrib-stylus"
grunt.registerTask "default", "coffee jade stylus server watch"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment