-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgulpfile.coffee
38 lines (31 loc) · 952 Bytes
/
gulpfile.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
gulp = require "gulp"
compass = require "gulp-compass"
coffee = require "gulp-coffee"
concat = require "gulp-concat"
shell = require "gulp-shell"
gulp.task "compass", ->
gulp.src './sass/**/*.sass'
.pipe compass( css: "./styles", sass: './sass')
.on 'error', (error) ->
console.log error.toString()
@emit 'end'
.pipe gulp.dest("./styles")
gulp.task "coffee", ->
gulp.src './coffee/**/*.coffee'
.pipe coffee()
.on 'error', (error) ->
console.log error.toString()
@emit 'end'
.pipe concat('app.js')
.pipe gulp.dest('scripts')
gulp.task "watch", ->
gulp.watch './sass/**/*.sass', ['compass']
gulp.watch './coffee/**/*.coffee', ['coffee']
gulp.task "build", ["compass", "coffee"]
gulp.task "runserver", ['build'], ->
gulp.src '', read: no
.pipe shell """
python app.py
"""
gulp.task "serve", ["runserver", "watch"]
gulp.task "default", ["serve"]