Skip to content

Instantly share code, notes, and snippets.

@cxyokk
Created April 16, 2014 10:18
Show Gist options
  • Save cxyokk/10847728 to your computer and use it in GitHub Desktop.
Save cxyokk/10847728 to your computer and use it in GitHub Desktop.
gulp compass
gulp = require 'gulp'
gutil = require 'gulp-util'
cp = require 'child_process'
q = require 'q'
gulp.task 'compass', ->
compassCmd = 'bundle exec compass compile --config compass.rb'
deferred = q.defer()
cp.exec compassCmd, (err, stdout, stderr)->
if err
gutil.log gutil.colors.red(stderr)
else
gutil.log gutil.colors.green(stdout)
deferred.resolve()
return deferred.promise
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment