refactoring: split helper functions into smaller scripts (#2420)

This commit is contained in:
Georg Lauterbach 2022-02-21 11:56:57 +01:00 committed by GitHub
parent 2927cc47c7
commit b61dfe1e24
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
41 changed files with 389 additions and 396 deletions

View file

@ -1,13 +1,13 @@
#! /bin/bash
# shellcheck source=../scripts/helper-functions.sh
. /usr/local/bin/helper-functions.sh
# shellcheck source=../scripts/helpers/index.sh
source /usr/local/bin/helpers/index.sh
HOSTNAME=${1}
RECIPIENT=${2}
SENDER=${3}
[[ -x /usr/sbin/pflogsumm ]] || errex "Critical: /usr/sbin/pflogsumm not found"
[[ -x /usr/sbin/pflogsumm ]] || _errex "Critical: /usr/sbin/pflogsumm not found"
# The case that the mail.log.1 file isn't readable shouldn't
# actually be possible with logrotate not rotating empty files..