DRY the sync backup script
This commit is contained in:
parent
bec062d420
commit
59d1f1d22d
1 changed files with 4 additions and 2 deletions
|
|
@ -6,7 +6,9 @@ IFS=$'\n\t'
|
||||||
export BORG_REPO="/media/backup/"
|
export BORG_REPO="/media/backup/"
|
||||||
|
|
||||||
if [ "$1" = "service" ]; then
|
if [ "$1" = "service" ]; then
|
||||||
rclone sync "${BORG_REPO}" gdrive-backup:hot-repo/
|
extra_args=()
|
||||||
else
|
else
|
||||||
rclone sync --progress "${BORG_REPO}" gdrive-backup:hot-repo/
|
extra_args=(--progress)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
rclone sync "${extra_args[@]}" "${BORG_REPO}" gdrive-backup:hot-repo/
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue