Skip to content
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

nix-shell: allow symlinks to .drvs #1983

Merged
merged 1 commit into from Mar 17, 2018

Conversation

lheckemann
Copy link
Member

This makes persistent shell environments easier to use.

This makes persistent shell environments easier to use.
@@ -271,10 +271,14 @@ void mainWrapped(int argc, char * * argv)
exprs = {state.parseStdin()};
else
for (auto i : left) {
auto absolute = i;
try {
absolute = canonPath(absPath(i), true);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we care that this will also resolve symlinks in the store?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think so, since this only affects the .drv case.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And what happens if there are symlinks in the store path (i.e. /nix/ is a symlink)? Does it move from «purity not guaranteed» to «doesn't work»?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/nix is not allowed to be a symlink anyway

@shlevy shlevy merged commit 12913cc into NixOS:master Mar 17, 2018
@lheckemann lheckemann deleted the shell-drv-indirect branch March 17, 2018 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants