summaryrefslogtreecommitdiff
path: root/nixos/nix.nix
blob: f8ee3512c54fe1f4755006e021483aa761b80e5c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
{ ... }:

{
  personal.nix = {
    enable = true;
    autoUpgrade = true;
    flake = "git+file:///etc/nixos";
    gc.enable = true;
  };

  system.autoUpgrade.flags =
    let update-input = input: [ "--update-input" input ];
    in update-input "latitude-7490/nixpkgs" ++ update-input "latitude-7490/home-manager" ++ update-input "latitude-7490/nixos-hardware" ++ update-input "latitude-7490/my-nixpkgs";

  # make auto-upgrade service lightweight
  systemd.services.nixos-upgrade.unitConfig = { CPUWeight = 1; };
}