-
-
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
nix run doesn't set IN_NIX_SHELL #2020
Comments
It's not clear whether it should set |
@edolstra I guess that just depends on the intended semantics of Regardless, at least something should be set. |
I've since found that |
Just running this into myself, it would be nice to have some way to tell. |
@giodamelio Does |
That won't really work for what I am doing. I want to simply display a
thing in my prompt when I am in a Nix shell, not when I am in a nested
shell. For example the SHLVL gets incremented when I am in a tmux session
(which makes sense), but it doesn't have anything to do with Nix
specifically.
…On Wed, Sep 12, 2018, 9:45 AM Will Fancher ***@***.***> wrote:
@giodamelio <https://github.com/giodamelio> Does SHLVL help? I found it
useful for more than just nix run; now I know *any* time I'm in a nested
shell, not just a nix run.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2020 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAa9LlDlK6l-0cr20NQDvw2bSe6LgVZuks5uaToMgaJpZM4S92cv>
.
|
I ran into this too. I have different prompts for different kinds of subshells, but I have no way to tell the difference from |
Couldn't |
+1 for this. I'd like to have some way to display it in the prompt e.g. when entering a shell with |
Related: #3862 |
Title. My shell prompt is set to look different when IN_NIX_SHELL is set, and I have
nix-shell
aliased to include my prompt. Sincenix run
doesn't setIN_NIX_SHELL
, I often have a hard time remembering if my shell is anix run
or not.The text was updated successfully, but these errors were encountered: