From 9b3515d12169371d6cbcae5c42a524451ce39bc0 Mon Sep 17 00:00:00 2001 From: Bruno Fontes Date: Fri, 26 Mar 2021 20:41:19 -0300 Subject: [PATCH] fix(Backup): folder name with space can be backed up Backup function were not working with folders that had space on it. Fixed now including double quotes with the parameter inside the function. --- Backup/.Backup_HD.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Backup/.Backup_HD.sh b/Backup/.Backup_HD.sh index e48b8b2..6835674 100755 --- a/Backup/.Backup_HD.sh +++ b/Backup/.Backup_HD.sh @@ -4,7 +4,7 @@ function backup () { #--stats = show stats at end #--progress = show each file being processed - nice -n 19 borg create --compression auto,zstd,9 --exclude-from=./exclude $* + nice -n 19 borg create --compression auto,zstd,9 --exclude-from=./exclude $1 "$2" } function backupNoCompression () { @@ -13,7 +13,7 @@ function backupNoCompression () { #--stats = show stats at end #--progress = show each file being processed - nice -n 19 borg create --compression none --exclude-from=./exclude $* + nice -n 19 borg create --compression none --exclude-from=./exclude $1 "$2" } function checkBackup() { @@ -110,7 +110,7 @@ backupNoCompression "$HDPath/Videos::$YEARMONTH" "/run/media/bruno/Multimedia/Vi checkBackup "$HDPath/Videos/" echo -e "\e[97m`date +%r` - Copying Virtual Machines folder (7/7)...\e[39m" -backup "$HDPath/VirtualMachines::$YEARMONTH" "/run/media/bruno/Multimedia/Virtual\ Machines" || echo "" +backup "$HDPath/VirtualMachines::$YEARMONTH-2" "/run/media/bruno/Multimedia/Virtual Machines" || echo "" checkBackup "$HDPath/VirtualMachines/" # Show result