configuration.nix 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. { config, pkgs, lib, ... }:
  2. let
  3. hosts = import ../../config/hosts.nix;
  4. in
  5. {
  6. imports = [
  7. ./hardware.nix
  8. ../../nixos/hardware/networking
  9. ../../nixos/hardware/gpu/nvidia.nix
  10. ../../nixos/hardware/sound
  11. ../../nixos/hardware/bluetooth
  12. ../../nixos/hardware/biometric/elan-fingerprint.nix
  13. ../../nixos/flavors/desktop/hyprland
  14. ../../nixos/flavors/desktop/hyprland/greeter-default.nix
  15. ../../nixos/flavors/application/workstation
  16. ../../nixos/flavors/application/development
  17. ../../nixos/flavors/application/gaming
  18. ../../nixos/flavors/application/school
  19. ../../nixos/features/system/users.nix
  20. ];
  21. boot.kernelParams = [
  22. "resume=UUID=79e1dbf5-5469-466b-bf3f-7de192644f09"
  23. ];
  24. nixpkgs.config.allowUnfree = true;
  25. hardware.enableAllFirmware = true;
  26. nix.settings.experimental-features = [ "nix-command" "flakes" ];
  27. networking.hostName = hosts.ideapad.hostname;
  28. hardware.nvidia = {
  29. powerManagement = {
  30. enable = true;
  31. finegrained = true;
  32. };
  33. prime = {
  34. offload = {
  35. enable = true;
  36. enableOffloadCmd = true;
  37. };
  38. intelBusId = "PCI:0:2:0";
  39. nvidiaBusId = "PCI:2:0:0";
  40. };
  41. };
  42. boot.loader.systemd-boot.enable = true;
  43. boot.loader.efi.canTouchEfiVariables = true;
  44. system.stateVersion = "26.05";
  45. }