flake/dev: rename nixpkgs input to avoid shadowing#3121
Merged
mergify[bot] merged 1 commit intonix-community:mainfrom Mar 28, 2025
Merged
flake/dev: rename nixpkgs input to avoid shadowing#3121mergify[bot] merged 1 commit intonix-community:mainfrom
nixpkgs input to avoid shadowing#3121mergify[bot] merged 1 commit intonix-community:mainfrom
Conversation
Rename `inputs.nixpkgs` to `inputs.dev-nixpkgs` to avoid shadowing the root flake's `inputs.nixpkgs`. Having the dev flake shadow an input can be confusing, since overriding the root flake's input will have no effect when evaluating outputs that depend on the dev partition. The only reason we specify a `nixpkgs` input at all here, is so the other inputs can follow it. Once nix 2.26 is more prevalent, we can follow the root flake's inputs using a `"path:../.."` input.
khaneliman
approved these changes
Mar 28, 2025
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
MattSturgeon
added a commit
to MattSturgeon/nixvim
that referenced
this pull request
Mar 28, 2025
Apply changes from 8e732cf (nix-community#3121) Flake lock file updates: • Added input 'dev-nixpkgs': 'github:NixOS/nixpkgs/bd3bac8bfb542dbde7ffffb6987a1a1f9d41699f?narHash=sha256-jAIUqsiN2r3hCuHji80U7NNEafpIMBXiwKlSrjWMlpg%3D' (2025-03-26) • Updated input 'devshell/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs' • Updated input 'git-hooks/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs' • Updated input 'home-manager/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs' • Updated input 'nix-darwin/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs' • Removed input 'nixpkgs' • Updated input 'treefmt-nix/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs'
MattSturgeon
added a commit
to MattSturgeon/nixvim
that referenced
this pull request
Mar 28, 2025
Apply changes from 8e732cf (nix-community#3121) Flake lock file updates: • Added input 'dev-nixpkgs': 'github:NixOS/nixpkgs/1750f3c1c89488e2ffdd47cab9d05454dddfb734?narHash=sha256-oDJGK1UMArK52vcW9S5S2apeec4rbfNELgc50LqiPNs%3D' (2025-03-24) • Updated input 'devshell/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs' • Updated input 'git-hooks/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs' • Updated input 'home-manager/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs' • Updated input 'nix-darwin/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs' • Removed input 'nixpkgs' • Updated input 'treefmt-nix/nixpkgs': follows 'nixpkgs' → follows 'dev-nixpkgs'
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Rename
inputs.nixpkgstoinputs.dev-nixpkgsto avoid shadowing the root flake'sinputs.nixpkgs.Having the dev flake shadow an input can be confusing, since overriding the root flake's input will have no effect when evaluating outputs that depend on the dev partition (i.e. outputs listed in
partitionedAttrs).The only reason we specify a nixpkgs input in the dev flake at all, is so the other inputs can follow it.
Once nix 2.26 is more prevalent, we can follow the root flake's inputs using a
"path:../.."input. See 2.26 release notes and NixOS/nix#10089.This may also require changes in flake-compat, since that is used by flake-parts to load the partition flake, see NixOS/flake-compat#18. The nix-community fork has support for
path:references, however idk if it is compatible with NixOS/nix#10089 which introduced lockfile changes in nix 2.26. I'm also unsure exactly which version of flake-compat is in use by flake-parts.