2008-07-18 11:34:06 -04:00
|
|
|
SETTINGS = {
|
2008-09-06 12:01:44 -04:00
|
|
|
:rsync_server => 'timeago.yarp.com:/var/www/timeago/',
|
|
|
|
:rsync_options => '-e ssh -avz --delete --exclude=.git'
|
2008-07-18 11:34:06 -04:00
|
|
|
}
|
|
|
|
|
2008-07-18 20:37:24 -04:00
|
|
|
task :default => :test
|
|
|
|
|
|
|
|
desc 'Publish to server (edit Rakefile to config)'
|
2008-07-18 11:34:06 -04:00
|
|
|
task :publish do
|
2008-09-06 12:01:44 -04:00
|
|
|
cmd = "rsync #{SETTINGS[:rsync_options]} ./ #{SETTINGS[:rsync_server]}"
|
2008-07-18 11:34:06 -04:00
|
|
|
puts "\nSyncing with server: #{cmd}\n\n"
|
|
|
|
system(cmd)
|
|
|
|
end
|
2008-07-18 20:37:24 -04:00
|
|
|
|
|
|
|
desc 'Open your default browser with the test page'
|
|
|
|
task :test do
|
|
|
|
system("open test.html")
|
|
|
|
end
|