zsh: prompt.zsh: fix rprompt indent
Various shells apparently do not support ZLE_RPROMPT_IDENT=0 properly and shift the cursor one to the left. As a result, autocompleting leads to weird shifting of the user input and 'overlapping' text. In order to fix this issue, it seems to be sufficient to set ZLE_RPROMPT_INDENT=-1. (see https://github.com/bhilburn/powerlevel9k/issues/110)
This commit is contained in:
parent
219bbaf74c
commit
151032b726
1 changed files with 1 additions and 7 deletions
|
|
@ -89,14 +89,8 @@ zshrc_prompt_precmd() {
|
|||
# suffix characters in first and second line
|
||||
local top_suffix="%F{cyan}${top_right_corner}%f"
|
||||
local bottom_suffix="%F{cyan}${bottom_right_corner}%f"
|
||||
# use %{ .. %} for bottom_right_corner to remove useless space after RPROMPT
|
||||
# remove useless space after RPROMPT
|
||||
if [[ $TERM != "tmux-256color" ]]; then
|
||||
# use %{ .. %} for bottom_right_corner if not in tmux
|
||||
bottom_suffix="%{${bottom_suffix}%}"
|
||||
else
|
||||
ZLE_RPROMPT_INDENT=0
|
||||
fi
|
||||
ZLE_RPROMPT_INDENT=-1
|
||||
|
||||
# combine them to create the prompt
|
||||
local top_left=""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue