From 7c914b7a601380f092f577a64ed660c943cd70f0 Mon Sep 17 00:00:00 2001 From: Otho Date: Mon, 16 Jan 2023 22:20:16 -0500 Subject: [PATCH] Improved command formatting. --- backup.sh | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/backup.sh b/backup.sh index 251fe91..975ab2f 100755 --- a/backup.sh +++ b/backup.sh @@ -203,10 +203,8 @@ send_latest() origin_snapshot=`get_latest_snapshot $dataset` send_cmd="zfs send $ZFS_SEND_OPTS $dataset@$origin_snapshot" pv_cmd="pv -qL ${speed:-$DEF_SPEED}" - recv_cmd=" - ssh $SSH_SEND_OPTS -o port=$ssh_port $user@$addr \ - zfs recv $ZFS_RECV_OPTS $zroot$remote_dataset - " + recv_cmd="ssh $SSH_SEND_OPTS -o port=$ssh_port $user@$addr \ + zfs recv $ZFS_RECV_OPTS $zroot$remote_dataset" run_send_recv done done < sendnodes.tmp @@ -227,15 +225,11 @@ send_increment() dataset=`echo $dataset|cut -d: -f1` origin_snapshot=`get_latest_snapshot` remote_snapshot=`get_latest_remote_snapshot` - send_cmd=" - zfs send $ZFS_SEND_OPTS -i $dataset@$remote_snapshot \ - $dataset@$origin_snapshot - " + send_cmd="zfs send $ZFS_SEND_OPTS -i $dataset@$remote_snapshot \ + $dataset@$origin_snapshot" pv_cmd="pv -qL ${speed:-$DEF_SPEED}" - recv_cmd=" - ssh $SSH_SEND_OPTS -o port=$ssh_port $user@$addr \ - zfs recv $ZFS_RECV_OPTS $zroot$remote_dataset - " + recv_cmd="ssh $SSH_SEND_OPTS -o port=$ssh_port $user@$addr \ + zfs recv $ZFS_RECV_OPTS $zroot$remote_dataset" run_send_recv done done < sendnodes.tmp