-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Introduce nix instantiate
#11506
base: master
Are you sure you want to change the base?
Introduce nix instantiate
#11506
Conversation
This is simmilar to `nix-instantiate` with support for installables (and flakes).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks overall like a clean subset of nix-instantiate
.
However some integration test would be nice and should be easy to add (with and without JSON).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think instantiate
should not be placed under the derivation
namespace. As I see it, derivation
commands should operate on derivations and should not have to know about expressions/flakes/installables. This command however operates on installables to produce a derivation.
See also #7868 and #7903, cc @Ericson2314
@fgaz All right, but where then ? |
The best place I can think of right now is |
Both look fine to me. Another option is
I think for now we can just wait for a nix maintainer to give their opinion. |
I think BTW, the reason that the new CLI doesn't have an equivalent for |
We're already doing a good job at this, but in this new scenario, we'll still need the functionality of writing |
This is similar to
nix-instantiate
with support for installables (and flakes).Motivation
The ability to obtain a derivation with the new cli has never been really implemented. #3908 (comment) is the best work-around, but it does not add a gc root for the generated paths.
This brings a dedicated entry-point with the right semantics instead of the workaround above.
Context
Fixes #3908
To some extent, this also addresses #7138 because outputs can easily be rooted. This brings that capability to store derivations.
Priorities and Process
Add 👍 to pull requests you find important.
The Nix maintainer team uses a GitHub project board to schedule and track reviews.