From 20435c4e760f2c98e55582f7af027766fac36795 Mon Sep 17 00:00:00 2001 From: Asif Bacchus Date: Fri, 7 Sep 2018 01:53:17 -0600 Subject: [PATCH] checkExist: added return code 3 for 'file not found'. --- root/scripts/borgbackup.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/root/scripts/borgbackup.sh b/root/scripts/borgbackup.sh index 42e49ba..3ade3b8 100755 --- a/root/scripts/borgbackup.sh +++ b/root/scripts/borgbackup.sh @@ -176,6 +176,9 @@ function checkExist { echo -e "\e[1;31m[`date +%Y-%m-%d` `date +%H:%M:%S`] --ERROR:" \ "${3} was not found--\e[0m" >> $logFile quit 101 + else + # file not found, return proper code + return 3 fi elif [ "$1" = "verify" ]; then if [ -e "$2" ]; then