diff options
Diffstat (limited to 'config/hypr/scripts/WofiPower.sh')
| -rwxr-xr-x | config/hypr/scripts/WofiPower.sh | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/config/hypr/scripts/WofiPower.sh b/config/hypr/scripts/WofiPower.sh new file mode 100755 index 00000000..74f5f105 --- /dev/null +++ b/config/hypr/scripts/WofiPower.sh @@ -0,0 +1,33 @@ +#!/usr/bin/env bash + +# WOFI STYLES +CONFIG="$HOME/.config/wofi/WofiBig/config" +STYLE="$HOME/.config/wofi/style.css" +COLORS="$HOME/.config/wofi/colors" + +# Wofi window config (in %) +WOFI_WIDTH=28 +WOFI_HEIGHT=8 + +wofi_command="wofi --show dmenu \ + --prompt choose... \ + --conf $CONFIG --style $STYLE --color $COLORS \ + --width=$WOFI_WIDTH% --height=$WOFI_HEIGHT% \ + --cache-file=/dev/null \ + --hide-scroll --no-actions \ + --matching=fuzzy" + +entries=$(echo -e " Poweroff\n Reboot\n Suspend\n Lock\n Logout" | $wofi_command -i --dmenu | awk '{print tolower($2)}') + +case $entries in + poweroff|reboot|suspend) + systemctl $entries + ;; + lock) + $HOME/.config/hypr/scripts/LockScreen.sh + ;; + logout) + hyprctl dispatch exit 0 + ;; +esac +
\ No newline at end of file |
