mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-22 14:06:16 +02:00
nix develop: do not assume that saved vars are set
This fixes https://github.com/NixOS/nix/issues/6809
This commit is contained in:
parent
de287964d5
commit
04386f7d69
1 changed files with 3 additions and 1 deletions
|
@ -288,8 +288,10 @@ struct Common : InstallableCommand, MixProfile
|
|||
|
||||
out << "unset shellHook\n";
|
||||
|
||||
for (auto & var : savedVars)
|
||||
for (auto & var : savedVars) {
|
||||
out << fmt("%s=${%s:-}\n", var, var);
|
||||
out << fmt("nix_saved_%s=\"$%s\"\n", var, var);
|
||||
}
|
||||
|
||||
buildEnvironment.toBash(out, ignoreVars);
|
||||
|
||||
|
|
Loading…
Reference in a new issue