]> arthur.barton.de Git - backup-script.git/blobdiff - bin/backup-script
Don't add "--rsh=..." to rsync command line in "local" mode
[backup-script.git] / bin / backup-script
index a8e27002c1bf8ef30668232c10e048cd16f7f4b1..85b62a8d8c8085ce4886167c362a1ae13f7f894e 100755 (executable)
@@ -385,7 +385,8 @@ for f in $sys; do
        # prepare (remote) command ...
        cmd="rsync --archive"
        [ "$compress" -ne 0 ] && cmd="$cmd --compress"
-       cmd="$cmd --rsh=\"$ssh_cmd\" --delete --delete-excluded --sparse"
+       [ "$local" -eq 0 ] && cmd="$cmd --rsh=\"$ssh_cmd\""
+       cmd="$cmd --delete --delete-excluded --sparse"
        [ "$VERBOSE" -gt 0 ] && cmd="$cmd --progress"
        if [ "$source_root" = "$default_source_root" ]; then
                cmd="$cmd --exclude=/dev --exclude=/proc --exclude=/sys"