Skip to content

Instantly share code, notes, and snippets.

@gaving
Created November 9, 2014 09:30
Show Gist options
  • Save gaving/27742489b2d5440e5140 to your computer and use it in GitHub Desktop.
Save gaving/27742489b2d5440e5140 to your computer and use it in GitHub Desktop.
require 'coffee-script/register'
gulp = require 'gulp'
coffee = require 'gulp-coffee'
gutil = require 'gulp-util'
jasmine = require 'gulp-jasmine'
watch = require 'gulp-watch'
gulp.task 'build', ->
gulp.src('./src/*.coffee')
.pipe(coffee(bare: true).on('error', gutil.log))
.pipe(gulp.dest('./dist/'))
gulp.task 'jasmine', ->
gulp.src('./spec/*.coffee').pipe(jasmine(verbose: true))
gulp.task 'watch', ->
gulp.src('./src/*.coffee').pipe(watch (files) ->
files.pipe(coffee(bare: true).on('error', gutil.log))
.pipe(gulp.dest('./dist/'))
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment