1
0
Fork 0
mirror of https://github.com/ohmyzsh/ohmyzsh.git synced 2024-12-18 10:22:00 +00:00

fix(dirhistory): make sure to call built-in zle widgets (#9771)

Without this patch, if the called zle widgets have been redefined this plugin might come into
conflict. Related: #9770.
This commit is contained in:
Stéphane Caron 2021-04-01 00:35:28 +02:00 committed by GitHub
parent 2b1d412279
commit 2d40b562e5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -108,16 +108,16 @@ function dirhistory_forward() {
# Bind keys to history navigation # Bind keys to history navigation
function dirhistory_zle_dirhistory_back() { function dirhistory_zle_dirhistory_back() {
# Erase current line in buffer # Erase current line in buffer
zle kill-buffer zle .kill-buffer
dirhistory_back dirhistory_back
zle accept-line zle .accept-line
} }
function dirhistory_zle_dirhistory_future() { function dirhistory_zle_dirhistory_future() {
# Erase current line in buffer # Erase current line in buffer
zle kill-buffer zle .kill-buffer
dirhistory_forward dirhistory_forward
zle accept-line zle .accept-line
} }
zle -N dirhistory_zle_dirhistory_back zle -N dirhistory_zle_dirhistory_back
@ -160,15 +160,15 @@ function dirhistory_down() {
# Bind keys to hierarchy navigation # Bind keys to hierarchy navigation
function dirhistory_zle_dirhistory_up() { function dirhistory_zle_dirhistory_up() {
zle kill-buffer # Erase current line in buffer zle .kill-buffer # Erase current line in buffer
dirhistory_up dirhistory_up
zle accept-line zle .accept-line
} }
function dirhistory_zle_dirhistory_down() { function dirhistory_zle_dirhistory_down() {
zle kill-buffer # Erase current line in buffer zle .kill-buffer # Erase current line in buffer
dirhistory_down dirhistory_down
zle accept-line zle .accept-line
} }
zle -N dirhistory_zle_dirhistory_up zle -N dirhistory_zle_dirhistory_up