nixos/systemd: Add suspend-then-hibernate units

Pretty useful for laptops. I use them with:

```
services.logind.lidSwitch = "suspend-then-hibernate";
environment.etc."systemd/sleep.conf".text = "HibernateDelaySec=8h";
```
This commit is contained in:
Janne Heß 2019-08-26 11:04:10 +02:00
parent d41b832ac2
commit c8e863e25e

View File

@ -112,11 +112,13 @@ let
# Hibernate / suspend. # Hibernate / suspend.
"hibernate.target" "hibernate.target"
"suspend.target" "suspend.target"
"suspend-then-hibernate.target"
"sleep.target" "sleep.target"
"hybrid-sleep.target" "hybrid-sleep.target"
"systemd-hibernate.service" "systemd-hibernate.service"
"systemd-hybrid-sleep.service" "systemd-hybrid-sleep.service"
"systemd-suspend.service" "systemd-suspend.service"
"systemd-suspend-then-hibernate.service"
# Reboot stuff. # Reboot stuff.
"reboot.target" "reboot.target"