3 ###################################################
4 ## shut down pc and break instantwm restart loop ##
5 ###################################################
7 # multiple instances would overlap
8 if pgrep instantmenu; then
9 echo "instantmenu already running"
18 kill wm" | instantmenu -l 10 -w 400 -c -n -F -p "do you want to shut down?")
20 # if there are apps open, ask for confirmation
22 if wmctrl -l | grep -q '..'; then
23 echo "running applications found"
24 if zenity --question --text="there are apps running, sure you want to $1"; then
32 echo "no running applications found"
39 rm ~/.instantosrunning
45 rm ~/.instantosrunning
51 rm ~/.instantosrunning