X-Git-Url: https://git.ralfj.de/web.git/blobdiff_plain/eaef5e06fdcbb3344efff7abeb62696c41ec907c..59bf25a0c1732f6a1bea9e5777bf9e7d03b8bbb5:/personal/upload.sh diff --git a/personal/upload.sh b/personal/upload.sh index 2d9205e..76dac8b 100755 --- a/personal/upload.sh +++ b/personal/upload.sh @@ -5,9 +5,11 @@ jekyll build cd _site git add . -if ! git diff --cached; then - # There are changes - git commit -m "site upload" -fi +git diff --cached +git commit -m "site upload" -rsync ./ www.ralfj.de:/srv/www.ralfj.de/docroot/ -aP --exclude .git +# To include `projects/rust-101/index.html` while excluding the rest of that folder, we have to +# write the exclusion as ".../*", or else rsync would not even descend into that directory. +rsync ./ www.ralfj.de:/srv/www.ralfj.de/docroot/ -aP --delete \ + --include projects/rust-101/index.html \ + --exclude .git --exclude cs --exclude upload --exclude "projects/rust-101/*"