diff --git a/home/linux/gui/hyprland/conf/keybindings.conf b/home/linux/gui/hyprland/conf/keybindings.conf index 705b3909..f7074f1b 100644 --- a/home/linux/gui/hyprland/conf/keybindings.conf +++ b/home/linux/gui/hyprland/conf/keybindings.conf @@ -40,7 +40,6 @@ bind = , XF86AudioPlay, exec, playerctl play-pause bind = , XF86AudioNext, exec, playerctl next bind = , XF86AudioPrev, exec, playerctl previous bind = , XF86Search, exec, anyrun -bind = , XF86PowerOff, exec, shutdown -h now # WORKSPACES # ============================================================================ diff --git a/hosts/12kingdoms-shoukei/apple-silicon.nix b/hosts/12kingdoms-shoukei/apple-silicon.nix index 0aec11d6..a7364e1c 100644 --- a/hosts/12kingdoms-shoukei/apple-silicon.nix +++ b/hosts/12kingdoms-shoukei/apple-silicon.nix @@ -24,6 +24,29 @@ # since mesa 25.1(already in nixpkgs), support for asahi is enabled by default. }; + # Lid & PowerKey settings + # + # Suspend: Store system state to RAM - fast, requires minimal power to maintain RAM. + # Hibernate: Store system state & RAM to Disk, and then poweroff the system. + # + # NOTE: Hibernate is not supported by Asahi Linux. + services.logind = { + lidSwitch = "suspend"; + lidSwitchExternalPower = "lock"; + # 'Docked' means: more than one display is connected or the system is inserted in a docking station + lidSwitchDocked = "ignore"; + + powerKey = "suspend"; + powerKeyLongPress = "poweroff"; + }; + systemd.targets.sleep.enable = true; + systemd.sleep.extraConfig = '' + AllowSuspend=yes + AllowHibernate=no + AllowSuspendThenHibernate=no + HibernateDelaySec=5min + ''; + # After adding this snippet, you need to restart the system for the touchbar to work. hardware.apple.touchBar = { enable = true; diff --git a/hosts/12kingdoms-shoukei/hypr-hardware.conf b/hosts/12kingdoms-shoukei/hypr-hardware.conf index 1d870c34..bfa6ac58 100644 --- a/hosts/12kingdoms-shoukei/hypr-hardware.conf +++ b/hosts/12kingdoms-shoukei/hypr-hardware.conf @@ -6,4 +6,3 @@ # 1.33: scale to 1.33 times # bitdepth,10: enable 10 bit support monitor=eDP-1, highres@highrr, 0x0, 1.33, bitdepth,10 -