Duplicated Prompt
Opened this issue · 7 comments
Hello there,
first of all - thanks for the awesome shell extension. Really enjoying it - i.e. the setup process is very user friendly.
The only thing I want to complain about is that the prompt is sometimes showing up in a duplicated manner, as you can see in the screenshot below. This usually happens after a "clear" command and waiting for some time. I did not even press enter or anything in the terminal. I also have it configured in a way that only the latest prompt that is active should be styled in this way (don't know the exact name of that setting, but I could configure this during the setup process in the beginning)
Let me know if you need more information about this.
See https://github.com/romkatv/powerlevel10k?tab=readme-ov-file#horrific-mess-when-resizing-terminal-window. If you aren't manually resizing the terminal, it's possible that the terminal is doing it on its own when something special is happening (e.g., it might do that when the computer goes to sleep or wakes up).
@romkatv thanks for this really fast reply. Indeed this can be reproduced when i resize the terminal window. I'm using the iTerm2 application as well as the integrated terminal within intelliJ and it happens in both of them. Which mitigation listed in that readme would u recommend me?
You can either change your prompt as described in the last bullet point here, or use zsh4humans.
i tried to adjust the settings as stated in the last bullet point by adding these to my .zshrc
:
export POWERLEVEL9K_SHOW_RULER=false
export POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR=' '
export POWERLEVEL9K_MULTILINE_FIRST_PROMPT_SUFFIX=''
export POWERLEVEL9K_MULTILINE_NEWLINE_PROMPT_SUFFIX=''
export POWERLEVEL9K_MULTILINE_LAST_PROMPT_SUFFIX=''
export POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=()
the issue is still not resolved this way.
Probably i need to set these somewhere else like in the .p10k.zsh
file?
Probably i need to set these somewhere else like in the
.p10k.zsh
file?
Good guess. This is also stated in your .zshrc
that you've just edited.
Ok, now the lines from above are on the bottom of the .p10k.zsh
-file. Ofc i also sourced .zshrc
again. But still the issue persists.
Edit: also using typeset -g
instead of export
did not help
If the issue is still happening, keep removing things from your prompt until there are no long lines between the start of prompt and cursor. Refer to the doc if this isn't clear.