diff --git a/hardware-configuration.nix b/hardware-configuration.nix index ed20a1e..5f7a195 100644 --- a/hardware-configuration.nix +++ b/hardware-configuration.nix @@ -32,12 +32,14 @@ # for now systemd.services."display-manager".preStart = '' chmod a+w $(realpath /sys/class/backlight/nvidia_backlight/brightness) || true + /etc/powerdown/powerswitch ''; # any better ideas to do this?... please? the scripts are pretty heavily modified. # from https://github.com/march-linux/powerdown services.udev.extraRules = '' SUBSYSTEM=="power_supply", ATTR{online}=="0", RUN+="/etc/powerdown/powerdown" SUBSYSTEM=="power_supply", ATTR{online}=="1", RUN+="/etc/powerdown/powerup" + SUBSYSTEM=="firmware", ACTION=="add", ATTR{loading}="-1" ''; boot.initrd.availableKernelModules = [ "xhci_hcd" "ehci_pci" "ahci" "usbhid" "usb_storage" "btrfs" "dm_crypt" ];