Run the `compass compile` command by NodeJS
发布于 2年前 作者 jsw0528 841 次浏览

Installation

$ gem install compass
$ npm install node-cc

Usage

var app = require('express')()

app.configure('development', function() {
  // [required] The source directory where you keep your sass stylesheets.
  app.set('--sass-dir', __dirname + '/app/assets/stylesheets')

  // [optional] The target directory where you keep your css stylesheets.
  app.set('--css-dir', __dirname + '/public/stylesheets')

  // [optional] The directory where you keep your images.
  app.set('--images-dir', __dirname + '/public/images')

  // [optional] Require the given ruby LIBRARY before running commands.
  app.set('--require', __dirname + '/lib/ooxx.rb')

  app.use(require('node-cc'))
})

License

Licensed under the MIT License.

回到顶部