Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Updated the`web:generate` Rake task

  • Loading branch information...
commit 9dd4fb7fb927d1284222180bc5b427f92104ac03 1 parent a81b4bb
@karmi authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 Rakefile
View
6 Rakefile
@@ -55,17 +55,17 @@ namespace :web do
task :update => :generate do
current_branch = `git branch --no-color`.split("\n").select { |line| line =~ /^\* / }.to_s.gsub(/\* (.*)/, '\1')
(puts "Unable to determine current branch"; exit(1) ) unless current_branch
- system "git stash save && git checkout web"
+ system "git checkout web"
system "cp examples/tire-dsl.html index.html"
system "git add index.html && git co -m 'Updated Tire website'"
system "git push origin web:gh-pages -f"
- system "git checkout #{current_branch} && git stash pop"
+ system "git checkout #{current_branch}"
end
desc "Generate the Rocco documentation page"
task :generate do
system "rocco examples/tire-dsl.rb"
- html = File.read('examples/tire-dsl.html').gsub!(/tire\-dsl\.rb/, 'tire.rb')
+ html = File.read('examples/tire-dsl.html').gsub!(/>tire\-dsl\.rb</, '>tire.rb<')
File.open('examples/tire-dsl.html', 'w') { |f| f.write html }
system "open examples/tire-dsl.html"
end
Please sign in to comment.
Something went wrong with that request. Please try again.