diff options
Diffstat (limited to 'modules/laptop.nix')
-rw-r--r-- | modules/laptop.nix | 77 |
1 files changed, 0 insertions, 77 deletions
diff --git a/modules/laptop.nix b/modules/laptop.nix deleted file mode 100644 index c50c28e..0000000 --- a/modules/laptop.nix +++ /dev/null @@ -1,77 +0,0 @@ -{ config, pkgs, lib, ... }: - -{ boot.kernelModules = [ "coretemp" ]; - boot.extraModulePackages = with config.boot.kernelPackages; [ - x86_energy_perf_policy - ]; - - hardware = { - bluetooth.enable = true; - }; - - environment.systemPackages = with pkgs; [ - powerstat - powertop - - arandr - autorandr - disper - ]; - - # powerManagement.resumeCommands = '' - # AUTORANDR="autorandr -c" - - # detect_display() - # { - # for X in /tmp/.X11-unix/X*; do - # D="''${X##/tmp/.X11-unix/X}" - # user=$(who | awk -vD="$D" '$5 ~ "\\(:"D"\\)$" {print $1}') - # if [ x"$user" != x"" ]; then - # export DISPLAY=":$D" - # /bin/su -c "''${AUTORANDR}" "$user" - # fi - # done - # } - - # case "$1" in - # thaw|resume) - # detect_display - # ;; - # esac - # ''; - - programs.light.enable = true; - - services.logind.extraConfig = '' - IdleAction=suspend - IdleActionSec=600 - ''; - - services.physlock.enable = false; - - services.tlp = { - enable = true; - extraConfig = '' - CPU_SCALING_GOVERNOR_ON_BAT=powersave - ''; - }; - - services.udev.extraRules = '' - # ACTION=="change", SUBSYSTEM=="drm", ENV{DISPLAY}=":0", ENV{XAUTHORITY}="/home/alan/.Xauthority", RUN+="${pkgs.autorandr}/bin/autorandr -c" - ''; - - services.xserver = { - libinput = { - enable = lib.mkDefault true; - naturalScrolling = true; - disableWhileTyping = true; - }; - }; - - systemd.services.nixos-upgrade.unitConfig.ConditionACPower = true; - systemd.services.nix-gc.unitConfig.ConditionACPower = true; - - imports = [ - ./user-interface.nix - ]; -} |