Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Guard::Compass automatically rebuilds scss|sass files when a modification occurs taking in account your compass configuration.
branch: master

This branch is 37 commits ahead of oliamb:master

Failed to load latest commit information.
.bundle Remove Gem's development dependencies
lib/guard Bump to 1.1.0
spec add support for additional_import_paths and add_import_path
.gitignore Initial commit
.travis.yml change travis rbx to latest Move Changelog to GitHub releases
Guardfile Update gemspec, Gemfile, Changelog
LICENSE Update Guard dependency to ~> 2.0 Simplify my maintainer link
Rakefile Drop Ruby 1.8
guard-compass.gemspec Remove Gem's development dependencies


Gem Version Build Status Dependency Status Code Climate Coverage Status

Guard::Compass allows to automatically run Compass whenever a stylesheet file is modified.

  • Compatible with Compass >= 0.10.5.
  • Tested against Ruby 1.9.3, 2.0.0, Rubinius & JRuby (1.9 mode only).


Please be sure to have Guard installed before continue.

The simplest way to install Guard::Compass is to use Bundler.

Add Guard::Compass to your Gemfile:

group :development do
  gem 'guard-compass'

and install it by running Bundler:

$ bundle

Add guard definition to your Guardfile by running the following command:

$ guard init compass


Please read Guard usage doc

guard :compass, configuration_file: 'config/compass_config.rb', project_path: 'public',
      compile_on_start: true do

Configure Guard::Compass plug-in

The default configuration generated by 'guard init compass' looks like this

guard :compass


List of available options

project_path: 'public'                          # path to the compass project directory (from guard working directory)
configuration_file: 'config/compass_config.rb'  # path to your compass configuration file (from guard working directory)
compile_on_start: true                          # compile stylesheets when guard starts

By default, the project path is equal to the guard working directory (the folder from where you start Guard). Compass will look into some default location for the config file from there.

The configuration_file is computed by compass. You don't need to define watchers like in other Guard plug-in because they are generated from the Compass configuration files, cool!

For the complete list of options, please refer to the Compass documentation.


Pull requests are very welcome! Please try to follow these simple rules if applicable:

  • Please create a topic branch for every separate change you make.
  • Make sure your patches are well tested. All specs run by Travis CI must pass.
  • Update the README.
  • Please do not change the version number.

For questions please join us in our Google group or on #guard (


Rémy Coutable


Olivier Amblet


Something went wrong with that request. Please try again.