summaryrefslogtreecommitdiff
path: root/Rakefile
diff options
context:
space:
mode:
authoruvok cheetah2020-01-05 13:47:09 +0100
committeruvok cheetah2020-01-05 13:47:09 +0100
commitba1e01f19216cf24036e23e0d7cbfed49fef50a5 (patch)
tree8ef479186444ba6e2ffb6702435c8c47d47cd234 /Rakefile
parentba9fd9ca4259e0be7318c058d4d92b42ef4fd166 (diff)
Add deploy commands to Rakefile
Diffstat (limited to 'Rakefile')
-rw-r--r--Rakefile20
1 files changed, 20 insertions, 0 deletions
diff --git a/Rakefile b/Rakefile
index 98ee3e4..6609c0e 100644
--- a/Rakefile
+++ b/Rakefile
@@ -18,3 +18,23 @@ task :clean do
puts 'Cleaning up _site...'.bold
Jekyll::Commands::Clean.process({})
end
+
+namespace :deploy do
+ desc "Deploy via SSH"
+ task :ssh => [:buildsite] do
+ sh "rsync", "-av", "_site/", "w019f723.kasserver.com:/www/htdocs/w019f723/blog.uvokchee.de/"
+ end
+
+ desc "Deploy via FTP"
+ task :ftp => [:buildsite] do
+ Dir.chdir "_site"
+ # quicker, but possibly error-prone
+ # sh "lftp", "-c", "set ftp:ssl-force true ; open w019f723.kasserver.com ; mirror -R --delete --verbose --ignore-time --no-perms --no-umask; bye"
+
+ # always copy everything
+ sh "lftp", "-c", "set ftp:ssl-force true ; open w019f723.kasserver.com ; mirror -R --delete --verbose --no-perms --no-umask ; bye"
+ Dir.chdir ".."
+
+ #sh "cat", "lftp.log"
+ end
+end