niksos/options/desktop/suspend.nix

18 lines
471 B
Nix
Raw Normal View History

2024-02-15 17:04:34 +01:00
{
inputs,
pkgs,
...
}: {
powerManagement = {
enable = true;
powerDownCommands = ''
${pkgs.mpc-cli}/bin/mpc pause
${pkgs.coreutils-full}/bin/sleep 1
'';
powerUpCommands = ''
${inputs.hyprland.packages.${pkgs.system}.hyprland}/bin/hyprctl dispatch dpms off HDMI-A-1
${inputs.hyprland.packages.${pkgs.system}.hyprland}/bin/hyprctl dispatch dpms on HDMI-A-1
'';
};
}