OSDN Git Service

fix instantshutdown overlapping
authorpaperbenni <paperbenni@gmail.com>
Thu, 23 Apr 2020 09:15:45 +0000 (11:15 +0200)
committerpaperbenni <paperbenni@gmail.com>
Thu, 23 Apr 2020 09:15:45 +0000 (11:15 +0200)
programs/instantshutdown

index 1706c6b..f02f301 100755 (executable)
@@ -4,6 +4,12 @@
 ## shut down pc and break instantwm restart loop ##
 ###################################################
 
+# multiple instances would overlap
+if pgrep instantmenu; then
+    echo "instantmenu already running"
+    exit
+fi
+
 answer=$(echo "yes
 no
 logout