summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-x.i3lock/lock.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/.i3lock/lock.sh b/.i3lock/lock.sh
index 3ef2a05..9379008 100755
--- a/.i3lock/lock.sh
+++ b/.i3lock/lock.sh
@@ -1,5 +1,9 @@
#!/bin/bash
+if pgrep i3lock 1>&2; then
+ exit
+fi
+
res () {
pkill $@
nohup $@ 2>&1 &