2024-04-07 22:16:33 -04:00
|
|
|
{
|
|
|
|
pkgs,
|
|
|
|
lib,
|
|
|
|
config,
|
|
|
|
...
|
|
|
|
}: {
|
2024-04-17 22:39:00 -04:00
|
|
|
options = {alyraffauf.apps.wlogout.enable = lib.mkEnableOption "Enables wlogout.";};
|
2024-03-29 23:27:08 -04:00
|
|
|
|
2024-04-17 22:39:00 -04:00
|
|
|
config = lib.mkIf config.alyraffauf.apps.wlogout.enable {
|
2024-03-29 23:27:08 -04:00
|
|
|
programs.wlogout = {
|
|
|
|
enable = true;
|
|
|
|
layout = [
|
|
|
|
{
|
|
|
|
label = "logout";
|
2024-05-05 19:39:36 -04:00
|
|
|
action = ''${lib.getExe' pkgs.systemd "loginctl"} terminate-user ${config.home.username}'';
|
2024-03-29 23:27:08 -04:00
|
|
|
text = "Logout";
|
|
|
|
keybind = "e";
|
|
|
|
}
|
|
|
|
{
|
|
|
|
label = "shutdown";
|
2024-05-05 19:39:36 -04:00
|
|
|
action = ''${lib.getExe' pkgs.systemd "systemctl"} poweroff'';
|
2024-03-29 23:27:08 -04:00
|
|
|
text = "Shutdown";
|
|
|
|
keybind = "s";
|
|
|
|
}
|
|
|
|
{
|
|
|
|
label = "reboot";
|
2024-05-05 19:39:36 -04:00
|
|
|
action = ''${lib.getExe' pkgs.systemd "systemctl"} reboot'';
|
2024-03-29 23:27:08 -04:00
|
|
|
text = "Reboot";
|
|
|
|
keybind = "r";
|
|
|
|
}
|
|
|
|
];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|