mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-22 05:56:15 +02:00
nix shell: fix symlink resolution
This commit is contained in:
parent
05d4a86923
commit
1a2019bb81
1 changed files with 3 additions and 1 deletions
|
@ -1,3 +1,4 @@
|
|||
#include "canon-path.hh"
|
||||
#include "current-process.hh"
|
||||
#include "run.hh"
|
||||
#include "command-installable-value.hh"
|
||||
|
@ -155,7 +156,8 @@ struct CmdShell : InstallablesCommand, MixEnvironment
|
|||
auto pathString = store->printStorePath(path);
|
||||
|
||||
for (auto const& pathV : extraPathVarMapping) {
|
||||
if (auto st = accessor->maybeLstat(CanonPath(pathString + pathV.second)); st)
|
||||
auto realPath = accessor->resolveSymlinks(CanonPath(pathString + pathV.second));
|
||||
if (auto st = accessor->maybeLstat(realPath); st)
|
||||
extraPathVars[pathV.first].push_front(pathString + pathV.second);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue