nixos: introduce nixpkgs.pkgsFun
, deprecate nixpkgs.pkgs
#57067
Closed
+48
−49
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
git log
nixos: introduce
nixpkgs.pkgsFun
, deprecatenixpkgs.pkgs
Despite what the description of
nixpkgs.pkgs
option said, theuse of
nixpkgs.pkgs
actually produced 2x evaluation slowdownafter a54a799 because NixOS had
to reevaluate
nixpkgs
to reapply overlays the second time.The use of
nixpkgs.pkgs
also complicates many things, e.g. whyare
overlays
reapplied, butconfiguration
is not? It alsoprevents proper
config
type checking via Typednixpkgs.config
with Gentoo-like use-flags #56227.nixpkgs.pkgsFun
approach is much simpler and doesn't haveany of those problems, half of the code in that module can also be
dropped after
nixpkgs.pkgs
option is completely removed.If such an option is really needed for optimizion purposes of
nixosTests
or whatever (which I doubt, note that e.g.NixOps users actually lose on average by using it for above
reasons), it should be made
internal
and hidden from users.nix-instantiate
environmentnix-env -qaP
diffs/cc @roberth @Ericson2314 @matthewbauer from git-blame, @7c6f434c