Guard Compass Plug-in
Let you configure a Guard that will run compass whenever a stylesheet is updated.
$ (sudo) gem install compass $ compass -f blueprint my_compass_project $ cd my_compass_project $ bundle init
Then, edit the Gemfile for it to looks like:
source "http://rubygems.org" gem 'guard-compass'
You can now download missing gems and initialize the guard
$ bundle install $ guard init $ guard init compass $ guard
Your scss(or sass) stylesheets are now guarded.
Configure Guard::Compass plug-in
The default configuration generated by ‘guard init compass’ looks like this
guard 'compass' do watch('^src/(.*)\.s[ac]ss') end
the compass guard accept two options:
- :workdir: all compass relative path will be computed from there
- :configuration_file: relative or absolute path to your compass configuration file
By default, the working directory is the folder where you run guard in and
the configuration_file is computed by compass
- Implements notifications
- Create a watch rule based on the compass config file
- Detect rails install and generate watcher accordingly