summaryrefslogtreecommitdiff
path: root/waylockd
diff options
context:
space:
mode:
Diffstat (limited to 'waylockd')
-rwxr-xr-xwaylockd3
1 files changed, 2 insertions, 1 deletions
diff --git a/waylockd b/waylockd
index b371abd..5acedc3 100755
--- a/waylockd
+++ b/waylockd
@@ -1,6 +1,7 @@
#!/bin/sh
-[ "$(pgrep -U$(whoami) -x waylockd | wc -l)" -gt "2" ] && echo "true"
+WLCNT="$(pgrep -U$(whoami) -x waylockd | wc -l)"
+[ "${WLCNT:-0}" -gt "2" ] && printf "Already running!\n" && exit
while true; do
cat ~/.config/waylock/config | xargs waylock && exit