commit 389be2e24052d6693c816db4d28e886a7dd14435 parent ec56b18a42d973adedb70cc910f3eb3c44b4f5f2 Author: Alex Balgavy <a.balgavy@gmail.com> Date: Sat, 31 Oct 2020 00:18:04 +0100 publish: use full rsync option names Former-commit-id: 22acef6937da723ff983a8834acc4865e80b0c99 Diffstat:
M | scripts/publish | | | 16 | ++++++++++++++-- |
1 file changed, 14 insertions(+), 2 deletions(-)
diff --git a/scripts/publish b/scripts/publish @@ -1,5 +1,5 @@ #!/bin/sh -[ -d public ] || { echo "No public/ folder present" && exit 1; } +[ -d ./public ] || { echo "No public/ folder present in current directory" && exit 1; } destdir=/var/www/"$(basename "$(pwd)")" printf "Upload public/ to vps:%s? [Y/n] " "$destdir" @@ -13,4 +13,16 @@ case "$conf" in ;; esac -rsync -mrvzhLuP --del public/ vps:"$destdir" +# Use long names for clarity +rsync \ + --partial \ + --update \ + --recursive \ + --copy-links \ + --compress \ + --prune-empty-dirs \ + --delete-after \ + --verbose \ + --human-readable \ + --progress \ + public/ vps:"$destdir"