Created
November 28, 2009 07:38
-
-
Save adamstac/244434 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ssh_user = "user@domain.com" # for rsync deployment | |
remote_root = "~/path/to/remote/" # for rsync deployment | |
desc "Runs preview" | |
task :preview do | |
system "staticmatic preview ." | |
end | |
desc "Builds the site" | |
task :build => 'styles:clear' do | |
puts "*** Building the site ***" | |
system "staticmatic build ." | |
end | |
desc "Clears the styles, generates new styles, builds the site, and finally deploys the site" | |
task :deploy => :build do | |
puts "*** Deploying the site ***" | |
system("rsync -avz --delete site/ #{ssh_user}:#{remote_root}") | |
end | |
namespace :styles do | |
desc "Clears the styles" | |
task :clear do | |
puts "*** Clearing styles ***" | |
system "rm -Rfv site/stylesheets/*" | |
end | |
desc "Generates new styles" | |
task :generate => :clear do | |
puts "*** Generating styles ***" | |
system "compass" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment