diff --git a/backup_new.sh b/backup_new.sh index 35b5124..b69ed98 100755 --- a/backup_new.sh +++ b/backup_new.sh @@ -462,6 +462,25 @@ else export BORG_PASSPHRASE="DummyPasswordSoBorgFails" fi +## read additional files +if [ -n "${borgXtraListPath}" ]; then + # check if file actually exists + if [ ! -f "${borgXtraListPath}" ]; then + badDetails dne 'borgXtraListPath' + fi + # read file contents into concatenated list for echo to cmdline + while read -r xtraItem; do + if [ -z "${xtraList}" ]; then + xtraList="${xtraItem}" + else + xtraList="${xtraList} ${xtraItem}" + fi + done <