From dc75c0afea591bc9ca87faf36ab59b5927c47bd9 Mon Sep 17 00:00:00 2001 From: Asif Bacchus Date: Thu, 26 Mar 2020 04:02:05 -0600 Subject: [PATCH] exit gracefully, list exit codes --- borghelper.sh | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/borghelper.sh b/borghelper.sh index da1e516..d00bd5c 100755 --- a/borghelper.sh +++ b/borghelper.sh @@ -218,3 +218,18 @@ if [ ! -d "${borgBaseDir}/tmp" ]; then fi fi export TMPDIR="${borgBaseDir}/tmp" + + + +### exit gracefully +cleanup +exit 0 + + +### exit codes +# 0: no errors, script completed successfully +# 1: parameter error (missing, non-existant or invalid input) +# 2: parameter missing/invalid in .borgvars file +# 3: could not create/remove borg tmp directory + +#EOF \ No newline at end of file