Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Allow users to compile stylesheets when Guard is started #11

Merged
merged 1 commit into from

4 participants

@mhayes

Not sure if this was already possible, but this pull request allows users to specify the following in their Guardfile:

guard 'compass', :compile_on_start => true do
  watch(%r{scss/(.*).scss})
end

This appears to be useful if multiple people are working on a Compass project and don't check in compiled stylesheets to the repository. From what I could tell compass won't immediately create new *.css files until one of the sass files has changed.

Hope you find this useful, thanks for the great plugin!

@mhayes mhayes Update lib/guard/compass.rb
allow users to compile stylesheets when guard is started
a9333c9
@jamestomasino

This would be extremely helpful.

@lewisf

+1 to this change.

@oliamb oliamb closed this
@oliamb oliamb reopened this
@oliamb oliamb merged commit bfc95d5 into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Aug 7, 2012
  1. @mhayes

    Update lib/guard/compass.rb

    mhayes authored
    allow users to compile stylesheets when guard is started
This page is out of date. Refresh to see the latest.
Showing with 6 additions and 1 deletion.
  1. +6 −1 lib/guard/compass.rb
View
7 lib/guard/compass.rb
@@ -64,7 +64,12 @@ def valid_sass_path?
# Compile all the sass|scss stylesheets
def start
create_updater
- reporter.announce "Guard::Compass is waiting to compile your stylesheets."
+ if (options[:compile_on_start])
+ reporter.announce "Guard::Compass is going to compile your stylesheets."
+ perform
+ else
+ reporter.announce "Guard::Compass is waiting to compile your stylesheets."
+ end
true
end
Something went wrong with that request. Please try again.