Created
February 26, 2014 20:01
-
-
Save miyagawa/9237290 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
diff --git a/Rakefile b/Rakefile | |
index adc9079..60348dd 100644 | |
--- a/Rakefile | |
+++ b/Rakefile | |
@@ -1,9 +1,13 @@ | |
ENV['TZ'] = "America/Los_Angeles" | |
require 'erb' | |
+require 'fileutils' | |
desc "build static files" | |
task :build do |t| | |
system "bundle exec jekyll build" | |
+ time = Time.now.to_i | |
+ system "find _site -name \\*.html | xargs perl -i -nlpe 's/screen\\.css/screen-#{time}.css/'" | |
+ FileUtils.cp("_site/css/screen.css", "_site/css/screen-#{time}.css") | |
end | |
desc "push site content to the production environment" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment