various fixes, mostly for etiona
[distro-setup] / btrbk-run
index 60f065d62e568732cff437d501a1f108d2792f2f..3a2d2a493495fb2fc422f02b9f5f80b52c632b39 100644 (file)
--- a/btrbk-run
+++ b/btrbk-run
@@ -46,7 +46,7 @@ pre="${0##*/}: "
 m() { if $verbose; then printf "$pre%s\n"  "$*"; fi;  "$@"; }
 e() { printf "$pre%s\n"  "$*"; }
 die() { printf "$pre%s\n" "$*" >&2; echo "exiting with status 1" >&2; exit 1; }
-mexit() { echo "exiting with status $1"; exit $1; }
+mexit() { echo "$pre: exiting with status $1"; exit $1; }
 
 # latest $MAIL_HOST
 if [[ -e /b/bash_unpublished/source-state ]]; then
@@ -59,6 +59,7 @@ mountpoints=()
 
 rsync_mountpoint=/q
 
+ret=0
 # default options
 conf_only=false
 dry_run=false # mostly for testing
@@ -445,7 +446,6 @@ else
   m /a/exe/mount-latest-remote ${targets[@]}
 fi
 
-e btrbk-run COMPLETED with exit status $ret
 mexit $ret
 
 # todo: move variable data we don't care about backing up