1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2025-12-08 10:01:05 +01:00
home-manager/nixos
David 1a99a515a1 nixos/common: guard nix.package access when nix.enable is false
When nix-darwin has `nix.enable = false` (e.g., for Determinate Nix
users), accessing `config.nix.package` throws an error:

    error: nix.package: accessed when `nix.enable` is off

This regression was introduced in commit a521eab when adding the
`home.uid` option. The code restructuring changed `inherit (config.nix)
package` to be evaluated unconditionally, whereas PR #6383 had
previously ensured this worked correctly.

The fix wraps the package assignment in `mkIf config.nix.enable` to
only access `config.nix.package` when nix management is enabled in the
host OS configuration.

Fixes: #8303
2025-12-05 10:37:47 -06:00
..
common.nix nixos/common: guard nix.package access when nix.enable is false 2025-12-05 10:37:47 -06:00
default.nix home-manager: add support for custom backup command (#6424) (#7153) 2025-10-30 12:26:13 -05:00