fix(zsh): restore keybindings on transient prompt

This commit is contained in:
Jan De Dobbeleer 2022-10-19 11:58:25 +02:00 committed by Jan De Dobbeleer
parent cad0a1be8f
commit a94ce52f98

View file

@ -109,11 +109,9 @@ if [[ "::TRANSIENT::" = "true" ]]; then
zle -N zle-line-init _posh-zle-line-init
# restore broken key bindings
# https://github.com/JanDeDobbeleer/oh-my-posh/discussions/2617#discussioncomment-3888718
bindkey '^[[A' up-line-or-search
bindkey '^[[B' down-line-or-search
bindkey '^[[F' end-of-line
bindkey '^[[H' beginning-of-line
# https://github.com/JanDeDobbeleer/oh-my-posh/discussions/2617#discussioncomment-3911044
bindkey '^[[A' up-line-or-beginning-search
bindkey '^[[B' down-line-or-beginning-search
fi
# legacy functions for backwards compatibility