find latest link-dest
This commit is contained in:
parent
105f8c90da
commit
6680c95e64
@ -115,7 +115,7 @@ Nextcloud/
|
||||
BACKUPSRVPATH_WITH_DATE="$BACKUPSRVPATH_WITH_HOST/backup-$(date +%Y-%m-%d)/$BACKUPDIR"
|
||||
BACKUPSRVPATH_WITH_DATE_INCOMPLETE="$BACKUPSRVPATH_WITH_DATE-incomplete"
|
||||
g_runcmd $sshopts mkdir -p "$BACKUPSRVPATH_WITH_DATE_INCOMPLETE" || continue
|
||||
BACKUPSRVPATH_LINK_DEST="$($sshopts ls -d "$BACKUPSRVPATH_WITH_HOST/backup-*/$BACKUPDIR" 2>/dev/null | egrep -v incomplete$ | tail -n1)"
|
||||
BACKUPSRVPATH_LINK_DEST="$($sshopts ls -dtr1 "$BACKUPSRVPATH_WITH_HOST/backup-*/$BACKUPDIR" 2>/dev/null | tail -n1)"
|
||||
# linkdest
|
||||
[ -n "$BACKUPSRVPATH_LINK_DEST" ] && rsyncoptsrun="$rsyncoptsrun --link-dest=$BACKUPSRVPATH_LINK_DEST"
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user