diff options
author | B Mathis <brandon@imathis.com> | 2009-10-20 08:50:16 -0500 |
---|---|---|
committer | B Mathis <brandon@imathis.com> | 2009-10-20 08:50:16 -0500 |
commit | e0a0d093c44481d1fada3ab4bb9a0c5cf1276524 (patch) | |
tree | 95f73f688f0065a212c04cc9e180957a420fa22e /Rakefile | |
parent | a72b96142a3a9c55ef661863484a26bc02103169 (diff) | |
download | my_new_personal_website-e0a0d093c44481d1fada3ab4bb9a0c5cf1276524.tar.xz my_new_personal_website-e0a0d093c44481d1fada3ab4bb9a0c5cf1276524.zip |
paramaterized feed, rsync deployment, and unified layouts
Diffstat (limited to 'Rakefile')
-rw-r--r-- | Rakefile | 16 |
1 files changed, 12 insertions, 4 deletions
@@ -1,5 +1,16 @@ require 'active_support' +# preview project on this port - http://localhost:4000 +port = "4000" + +# compiled site directory +site = "site" + +# for rsync deployment +ssh_user = "user@host.com" +document_root = "~/document_root/" + + def ok_failed(condition) if (condition) puts "OK" @@ -8,9 +19,6 @@ def ok_failed(condition) end end -port = "4000" -site = "site" - desc "list tasks" task :default do puts "Tasks: #{(Rake::Task.tasks - [Rake::Task[:default]]).to_sentence}" @@ -35,7 +43,7 @@ end desc "generate and deploy website" task :deploy => :generate do print "Deploying website..." - ok_failed system("rsync -avz --delete #{site}/ user@host.com:~/document_root/") + ok_failed system("rsync -avz --delete #{site}/ #{ssh_user}:#{document_root}") end desc "start up an instance of serve on the output files" |