-
Notifications
You must be signed in to change notification settings - Fork 423
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
Allow a trigger before enabling SHLVL (LP_ENABLE_SHLVL) #821
Comments
I suppose a As a work around, you could add something to your bash/zshrc that decrements |
Tried this in if [ "x$TMUX" != "x" ]; then
SHLVL="$(( SHLVL - 1 ))"
fi
While without the decrement code, it works well:
|
Weird, it works perfectly for me if I add this to my if [[ -n ${TMUX-} ]]; then
SHLVL=$(( SHLVL - 1 ))
fi Of course, if you then run SHLVL=0 tmux |
Thanks for your suggestions @Rycieos, but I can't make them to work on my system (Yep, I'm running Bash inside Tmux, good catch!). Anyway, it's not blocking, and I can wait, and hope |
|
Description
I discovered LP_ENABLE_SHLVL today, nice!
But, as I'm always running my shells under Tmux, the bold green mark is always present ("└2"), which distract me. And, more importantly, I would not notice when I'm actually running a subshell ("└3")!
Would it be possible to display the mark only when
$SHLVL
is greater than 2, by example?How will this be useful?
Warn about sub shells only when the user needs it.
The text was updated successfully, but these errors were encountered: