CLI config/dotfiles
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.

40 lines
525 B

  1. #!/usr/bin/env sh
  2. wm_name='powermenu'
  3. if xdo id -a "$wm_name" > /dev/null; then
  4. pkill -f "dzen2 -title-name $wm_name"
  5. exit
  6. fi
  7. color0="#000000"
  8. color5="#FFFFFF"
  9. screen=1
  10. out="Power
  11. lock
  12. reboot
  13. shutdown"
  14. lines=$(echo -e "$out" | wc -l)
  15. echo -e "$out" | dzen2 \
  16. -title-name "$wm_name" \
  17. -bg "$color0" \
  18. -fg "$color5" \
  19. -x "-242" \
  20. -y "20" \
  21. -l $((lines-1)) \
  22. -h 30 \
  23. -w 240 \
  24. -fn "Source Code Pro" \
  25. -e "onstart=uncollapse;button1=menuexec,exit;button3=exit" \
  26. -ta c \
  27. -sa c \
  28. -xs $screen \
  29. -m \
  30. -p &