From 5f298276149342f9e2ddf3315355630d205a0456 Mon Sep 17 00:00:00 2001 From: Ian Kelling Date: Thu, 11 May 2023 11:00:24 -0400 Subject: [PATCH 1/1] fix: systemd has less environment vars --- sysd-mail-once | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sysd-mail-once b/sysd-mail-once index 3542200..32aa02d 100755 --- a/sysd-mail-once +++ b/sysd-mail-once @@ -18,7 +18,8 @@ set -eE -o pipefail trap 'echo "$0:$LINENO:error: \"$BASH_COMMAND\" returned $?" >&2' ERR errors=3 -cbase=$HOME/sysd-mail-once-state +tmp=(~) +cbase="${tmp[0]}/sysd-mail-once-state" to=root dryrun=false while [[ $1 == -* ]]; do @@ -142,7 +143,7 @@ if (( code )); then echo "sysd-mail-once: emailing on $errors errors. exit code: $code" mi exim -odf -t <= $errors errors." mi exim -odf -t <