mostly profanity and fixes
[distro-setup] / btrbk-run
index b5682ba5ef0830976e0ab895436f6b8fc1a6d278..c4d84616a9c3427391e9a095e65ccd14d369bcac 100644 (file)
--- a/btrbk-run
+++ b/btrbk-run
@@ -473,7 +473,7 @@ exec &> >(pee cat 'ts "%F %T"|dd of='$log_path' status=none')
 
 
 if $verbose; then
-  printf " options: conf_only=%s\ndry_run=%s\nrate_limit=%s\nverbose=%s\ncmd_arg=%s" "$conf_only" "$dry_run" "$rate_limit" "$verbose" "$cmd_arg"
+  printf " options: conf_only=%s\ndry_run=%s\nrate_limit=%s\nverbose=%s\ncmd_arg=%s\n" "$conf_only" "$dry_run" "$rate_limit" "$verbose" "$cmd_arg"
 fi
 
 if [[ -v targets ]]; then
@@ -842,11 +842,11 @@ if [[ $ret == 0 ]]; then
     if [[ $h == kd && $HOSTNAME == x3 && $HOSTNAME == "$MAIL_HOST" ]]; then
       m ssh root@$tg 'btrbk-spread-wrap &>/dev/null </dev/null &'
     fi
-    rsync -a -f"- */" -f"+ *" /var/log/btrbk/ root@$tg:/var/log/btrbk/$tg
+    rsync --mkpath -a -f"- */" -f"+ *" /var/log/btrbk/ root@$tg:/var/log/btrbk/$tg
     ssh root@$tg /usr/local/bin/mail-backup-clean
   done
   if [[ $source ]]; then
-    rsync -a -f"- */" -f"+ *" $source:/var/log/btrbk/ /var/log/btrbk/$source
+    rsync --mkpath -a -f"- */" -f"+ *" $source:/var/log/btrbk/ /var/log/btrbk/$source
   fi
 fi