Nix configurations for my personal machines (Linux & macOS)
1{
2 delib,
3 inputs,
4 ...
5}: let
6 shared.nix.settings = {
7 auto-optimise-store = true;
8 experimental-features = ["nix-command" "flakes"];
9 trusted-users = ["root" "@wheel"];
10 };
11in
12 delib.module {
13 name = "nix";
14
15 # TODO: double check home-manager options
16 home.always = shared;
17 nixos.always =
18 shared
19 // {
20 nix = {
21 gc = {
22 automatic = true;
23 options = "--delete-older-than 10d";
24 dates = "weekly";
25 };
26
27 nixPath = ["nixpkgs=${inputs.nixpkgs}"];
28
29 registry.nixpkgs.to = {
30 type = "path";
31 path = inputs.nixpkgs;
32 narHash = inputs.nixpkgs.narHash;
33 };
34 };
35
36 nixpkgs.config.allowUnfree = true;
37 system.tools.nixos-option.enable = false;
38 };
39 }