Another copy of my dotfiles. Because I don't completely trust GitHub.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

60 lines
1.1 KiB

4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
  1. #!/bin/sh
  2. killprogs() {
  3. pkill -x udisks-glue
  4. pkill -x panel
  5. pkill -x redshift
  6. }
  7. logout() {
  8. pkill dwm
  9. }
  10. DMENU='dmenu -z 1900 -x 10 -y 10 -i'
  11. items="dwm
  12. dwmblocks
  13. mconnect
  14. dunst
  15. clipmenud
  16. quark
  17. devmon"
  18. # Open menu
  19. selection=$(printf '%s' "$items" | $DMENU)
  20. case $selection in
  21. dwm)
  22. touch /home/yigit/.cache/dwm-restart
  23. logout
  24. ;;
  25. dwmblocks)
  26. kill -9 $(pidof dwmblocks)
  27. dwmblocks > /tmp/dwmblocks.out 2> /tmp/dwmblocks.err &
  28. ;;
  29. mconnect)
  30. kill -9 $(pidof mconnect)
  31. (cd ~/Downloads/mconnect; mconnect -d > /tmp/mconnect 2> /tmp/mconnect.err &)
  32. ;;
  33. clipmenud)
  34. pkill -f clipmenud
  35. clipmenud > /tmp/clipmenud.out 2> /tmp/clipmenud.err &
  36. ;;
  37. dunst)
  38. kill -9 $(pidof dunst)
  39. dunst &
  40. ;;
  41. devmon)
  42. pkill -f devmon
  43. ~/.scripts/devmon --exec-on-drive "/sbin/notify-send '禍 drive mounted' '%l (%f) at %d '" \
  44. --exec-on-remove "/sbin/notify-send '禍 drive removed' '%l (%f) from %d '" \
  45. --exec-on-unmount "/sbin/notify-send '禍 drive unmounted' '%l (%f) from %d '" \
  46. --no-unmount --no-gui &
  47. ;;
  48. quark)
  49. sudo systemctl restart quark
  50. ;;
  51. esac
  52. exit