flake/parseFlakeRef: add explicit entryFile parameter#15700
Open
hsjobeki wants to merge 2 commits intoNixOS:masterfrom
Open
flake/parseFlakeRef: add explicit entryFile parameter#15700hsjobeki wants to merge 2 commits intoNixOS:masterfrom
hsjobeki wants to merge 2 commits intoNixOS:masterfrom
Conversation
instead of isFlake, we might want to support explicit entry points, such as "default.nix". Right now the name parseFlakeRef is still coupled to flakes, but could be renamed to parseSourceRef or similar in a later pr. The motivation behind this commit is to decouple nix commands from flakes
hsjobeki
commented
Apr 16, 2026
| const std::optional<std::filesystem::path> & baseDir = {}, | ||
| bool allowMissing = false, | ||
| bool isFlake = true, | ||
| const std::optional<std::string> & entryFile = "flake.nix", |
Contributor
Author
There was a problem hiding this comment.
This should probably live in some constant?
ce3f822 to
3aebaed
Compare
2 tasks
3aebaed to
1ad4188
Compare
Member
|
I don't think this is a good idea. One of the main goals of flakes was to standardize what a Nix project looks like, i.e. to remove the chaos of having different entry points like |
Contributor
Author
|
I don't think one follows from the other. Allowing a flexible CLI vs flakes adoption. A lot of people don't use flakes and feel treated like second class citizen. |
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.
Motivation (also in commit message)
instead of
isFlake, we might want to support explicit entry points, such as "default.nix". Right now the nameparseFlakeRefis still coupled to flakes, but could be renamed toparseSourceRefor similar in a later pr. The motivation behind this commit is to decouple nix commands from flakesNote: This should be equivalent behavior refactoring, just for decoupling and opening the road
Context
Add 👍 to pull requests you find important.
The Nix maintainer team uses a GitHub project board to schedule and track reviews.