Skip to content

Commit

Permalink
Fail if site generation fails
Browse files Browse the repository at this point in the history
  • Loading branch information
balloob committed Dec 7, 2016
1 parent 0207fd4 commit caed5e9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,10 @@ desc "Generate jekyll site"
task :generate do
raise "### You haven't set anything up yet. First run `rake install` to set up an Octopress theme." unless File.directory?(source_dir)
puts "## Generating Site with Jekyll"
system "compass compile --css-dir #{source_dir}/stylesheets"
system "jekyll build"
success = system "compass compile --css-dir #{source_dir}/stylesheets"
abort("Generating CSS failed") unless success
success = system "jekyll build"
abort("Generating site failed") unless success
end

desc "Watch the site and regenerate when it changes"
Expand Down

0 comments on commit caed5e9

Please sign in to comment.