-
Notifications
You must be signed in to change notification settings - Fork 564
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
Directory History is not populated when setting PROMPT_COMMAND #943
Comments
If you just want the default prompt, why are you setting |
If you meant that why not prepend a '\n' before the
The solution would be to set these variables to fix all the above issues PROMPT_COMMAND="export PROMPT_COMMAND=echo"
alias clear="unset PROMPT_COMMAND; clear; set PROMPT_COMMAND=export PROMPT_COMMAND='echo'" But this causes the issue with zoxide. I understand these are small detail, but the reason we setting these are to customize to our needs. |
This command is what I'm not able to understand: PROMPT_COMMAND="export PROMPT_COMMAND=echo" Why are you setting Just initialize it like this: PROMPT_COMMAND='echo'
eval "$(zoxide init bash)" |
When you create a new terminal session you don't want the On creating a new terminal session
I hope I made it clear. |
Ensure that |
Issue
I use the bash shell and installed zoxide via homebrew. The issue was that setting
PROMPT_COMMAND
seem to interfere with zoxide and not populating the directory history as I navigate through files.My .bashrc
I am setting
PROMPT_COMMAND
to echo a newline after executing each shell command so that I can distinguish between each command. This solution works but introduces the mentioned issue.What I Tried?
I was able to figure out what changes introduced the bug but not sure why is it happening.
PROMPT_COMMAND="export PROMPT_COMMAND=echo"
the bug is introducedPROMPT_COMMAND
after initializing zoxide doesn't fix the issue.PROMPT_COMMAND="echo"
and no bug, zoxide just works fine.I am okay with setting
PROMPT_COMMAND="echo"
as it does get the job done. but puts an unnecessary newline at the start of the every terminal session which can be annoying.Version
The text was updated successfully, but these errors were encountered: