From 4fbcd8769a06ddb9e53b7b647c3e1416b8d9962f Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Wed, 22 Apr 2015 16:21:08 -0400 Subject: wmii: Use systemd-notify instead of hitting the socket manually --- .config/wmii-hg/config.sh | 4 +--- .config/wmii-hg/wmiirc | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.config/wmii-hg/config.sh b/.config/wmii-hg/config.sh index 6846920..4b968b0 100644 --- a/.config/wmii-hg/config.sh +++ b/.config/wmii-hg/config.sh @@ -68,9 +68,7 @@ Event() { ## WMII-meta events Quit) ## No args trap - EXIT - if [ -S "$NOTIFY_SOCKET" ]; then - echo STOPPING=1 | socat STDIO UNIX-SENDTO:"$NOTIFY_SOCKET" - fi + systemd-notify STOPPING=1 || true Event WmiircUnmount Event WmiircQuit;; Warning) ## $@=string diff --git a/.config/wmii-hg/wmiirc b/.config/wmii-hg/wmiirc index 260aaa1..379de79 100755 --- a/.config/wmii-hg/wmiirc +++ b/.config/wmii-hg/wmiirc @@ -13,9 +13,7 @@ wmiir xwrite /event WmiircQuit # close any existing wmiirc's Event WmiircStart # Notify systemd that we're ready -if [ -S "$NOTIFY_SOCKET" ]; then - echo READY=1 | socat STDIO UNIX-SENDTO:"$NOTIFY_SOCKET" -fi +systemd-notify READY=1 || true trap "Event Quit" EXIT -- cgit v1.2.3