function for sending signal notifications

This commit is contained in:
olli 2023-01-17 09:02:00 +01:00
parent 67c48188ad
commit 57f2744916

View File

@ -0,0 +1,7 @@
#!/bin/bash
function g_signal-notify {
[ -z "$1" ] && return 0
[ -n "${SIGNAL_GROUP}" ] && g_signal_group="-g \"${SIGNAL_GROUP}\""
cat <<< "$(g_date_print) $@" | tail -n 100 | /usr/local/bin/notify.sh $g_signal_group
}