-
Notifications
You must be signed in to change notification settings - Fork 57
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
generateNixPathFromInputs
should use a dir entry instead of per-flake entries
#105
Comments
I don't think I quite catch the issue here, could you elaborate? Maybe with help of few examples. I personally really do not care for NIX_PATH and I truly believe that it should get removed. I have added it for compatibility reasons in case you need |
@gytis-ivaskevicius When you have a directory entry without a name in It's nice because it means you don't need to start a new shell session to get the updated NIX_PATH when you add a new input or remove one. Like if I removed |
What @ElvishJerricco. And to be clear, you do not put a Implementing this solution reuses your existing {
nix.nixPath = mkIf cfg.generateNixPathFromInputs [ "/etc/nix/inputs" ];
} This produces a |
Thank you, I had no idea about this feature of nix |
generateNixPathFromInputs
symlinks relevant inputs into/etc/nix/inputs
and synthesizes aNIX_PATH
with an entry for each input. I assume it does this so that way theNIX_PATH
entries will always reference the current configuration without having to spawn a new shell. The downside is any additions/removals to the input set won't be reflected in existing shells.Instead of adding one entry per input to
NIX_PATH
, it should just add a single entry for/etc/nix/inputs
. This way it will always reflect the current state of the system regardless of what happens to the inputs.The text was updated successfully, but these errors were encountered: