Light refactor, enable parallelism for nix building, builders use substitute and make sure darwin has the same benefits as linux

This commit is contained in:
Martin Larsson 2025-07-15 15:52:06 +02:00
parent 3683e93dbc
commit 1cfdfda52d
3 changed files with 28 additions and 17 deletions

27
nix/system/common/nix.nix Normal file
View file

@ -0,0 +1,27 @@
{ pkgs, ... }:
{
environment.systemPackages = with pkgs; [
vim
];
nix = {
settings = {
experimental-features = "nix-command flakes";
auto-optimise-store = true;
max-jobs = "auto";
cores = 0;
builders-use-substitutes = true;
};
extraOptions = ''
keep-going = true
'';
gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 7d";
};
};
}

View file

@ -37,17 +37,6 @@
};
};
nix = {
settings = {
auto-optimise-store = true;
};
gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 7d";
};
};
services = {
pipewire = {
enable = true;