fix(darwin): migrate to new nix-darwin options & root activation 🔧
- set `nix.enable = true`; remove deprecated `services.nix-daemon.enable` 🔥
- replace unsafe `nix.settings.auto-optimise-store` with `nix.optimise.automatic`
- rename Touch ID option to `security.pam.services.sudo_local.touchIdAuth`
- add `system.primaryUser = "danny"` so user-scoped macOS defaults apply under root activation
- keep GC schedule; retain `nixpkgs.hostPlatform = "aarch64-darwin"`
- (minor) expand `environment.systemPackages` with `git`, `gnupg`, `coreutils`
This adapts the config to recent nix-darwin changes and fixes evaluation failures during `darwin-rebuild`.
This commit is contained in:
parent
3a6fbd2f89
commit
948798af4a
1 changed files with 5 additions and 3 deletions
|
|
@ -3,21 +3,23 @@
|
||||||
{
|
{
|
||||||
# Apple Silicon + nix-darwin basics
|
# Apple Silicon + nix-darwin basics
|
||||||
nixpkgs.hostPlatform = "aarch64-darwin";
|
nixpkgs.hostPlatform = "aarch64-darwin";
|
||||||
services.nix-daemon.enable = true;
|
nix.enable = true;
|
||||||
|
|
||||||
nix = {
|
nix = {
|
||||||
settings = {
|
settings = {
|
||||||
experimental-features = [ "nix-command" "flakes" ];
|
experimental-features = [ "nix-command" "flakes" ];
|
||||||
auto-optimise-store = true;
|
|
||||||
};
|
};
|
||||||
gc = {
|
gc = {
|
||||||
automatic = true;
|
automatic = true;
|
||||||
interval = { Weekday = 0; Hour = 3; Minute = 0; };
|
interval = { Weekday = 0; Hour = 3; Minute = 0; };
|
||||||
};
|
};
|
||||||
|
optimise.automatic = true; # replaces auto-optimise-store
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
|
||||||
|
system.primaryUser = "danny";
|
||||||
|
|
||||||
# Shells & dev ergonomics
|
# Shells & dev ergonomics
|
||||||
programs.fish.enable = true;
|
programs.fish.enable = true;
|
||||||
environment.shells = [ pkgs.fish ];
|
environment.shells = [ pkgs.fish ];
|
||||||
|
|
@ -35,7 +37,7 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
# macOS niceties
|
# macOS niceties
|
||||||
security.pam.enableSudoTouchIdAuth = true;
|
security.pam.services.sudo_local.touchIdAuth = true;
|
||||||
|
|
||||||
system.defaults = {
|
system.defaults = {
|
||||||
# Keyboard
|
# Keyboard
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue