commit 91fee32a04d60865a43d8fb468daa8270a749e77
parent 09af6a6451a655b7cbf9fb837b6f3805eecae49d
Author: JayVii <jayvii[AT]posteo[DOT]de>
Date: Sat, 18 Sep 2021 16:39:56 +0200
Fix Signal Handler
Diffstat:
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/im-notifier b/im-notifier
@@ -51,9 +51,10 @@ function im_unnotify {
}
function im_signal_listen {
dbus-monitor "type='signal',sender='org.freedesktop.Notifications',interface='org.freedesktop.Notifications',member='ActionInvoked'" | \
- grep -E "$1" | \
while read -r line; do
- $SHELL -c "$2"
+ if [[ $(printf "$line" | grep "$1") != "" ]]; then
+ $SHELL -c "$2"
+ fi
done
}