temporary fix for wofi on laptop
This commit is contained in:
parent
38ad0afc2c
commit
c68860b185
1 changed files with 38 additions and 2 deletions
|
|
@ -201,12 +201,48 @@ in
|
||||||
};
|
};
|
||||||
"$mod" = "SUPER";
|
"$mod" = "SUPER";
|
||||||
bind =
|
bind =
|
||||||
|
let
|
||||||
|
wofi-power = (
|
||||||
|
pkgs.writeShellScriptBin "wofi-power" ''
|
||||||
|
lock="Lock"
|
||||||
|
poweroff="Poweroff"
|
||||||
|
reboot="Reboot"
|
||||||
|
sleep="Suspend"
|
||||||
|
logout="Log out"
|
||||||
|
selected_option=$(echo -e "$lock\n$sleep\n$reboot\n$logout\n$poweroff" | ${pkgs.wofi}/bin/wofi --dmenu -i -p "Powermenu")
|
||||||
|
|
||||||
|
if [ "$selected_option" == "$lock" ]
|
||||||
|
then
|
||||||
|
echo "lock"
|
||||||
|
swaylock
|
||||||
|
elif [ "$selected_option" == "$poweroff" ]
|
||||||
|
then
|
||||||
|
echo "poweroff"
|
||||||
|
poweroff
|
||||||
|
elif [ "$selected_option" == "$reboot" ]
|
||||||
|
then
|
||||||
|
echo "reboot"
|
||||||
|
reboot
|
||||||
|
elif [ "$selected_option" == "$sleep" ]
|
||||||
|
then
|
||||||
|
echo "sleep"
|
||||||
|
suspend
|
||||||
|
elif [ "$selected_option" == "$logout" ]
|
||||||
|
then
|
||||||
|
echo "logout"
|
||||||
|
hyprctl dispatch exit
|
||||||
|
else
|
||||||
|
echo "No match"
|
||||||
|
fi
|
||||||
|
''
|
||||||
|
);
|
||||||
|
in
|
||||||
[
|
[
|
||||||
"$mod,Return,exec,${cfg.terminal}/bin/${cfg.terminal.pname}"
|
"$mod,Return,exec,${cfg.terminal}/bin/${cfg.terminal.pname}"
|
||||||
"$mod,tab,cyclenext"
|
"$mod,tab,cyclenext"
|
||||||
"SUPERSHIFT,Q,killactive"
|
"SUPERSHIFT,Q,killactive"
|
||||||
"$mod,SPACE,exec,wofi-launch"
|
"$mod,SPACE,exec,${pkgs.wofi}/bin/wofi --show drun"
|
||||||
"$mod,P,exec,wofi-power"
|
"$mod,P,exec,${wofi-power}/wofi-power"
|
||||||
"SUPERSHIFT,m,exit"
|
"SUPERSHIFT,m,exit"
|
||||||
"$mod,H,movefocus,l"
|
"$mod,H,movefocus,l"
|
||||||
"$mod,J,movefocus,u"
|
"$mod,J,movefocus,u"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue