mirror of
https://github.com/denisidoro/navi.git
synced 2024-09-19 22:37:16 +03:00
feat: Add oh-my-zsh plugin compatibility.
This commit is contained in:
parent
0c960fca54
commit
32b1b42f2c
13
navi.plugin.zsh
Normal file
13
navi.plugin.zsh
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
local _navi_path=$(dirname $0:A)
|
||||||
|
|
||||||
|
_call_navi() {
|
||||||
|
local buff="$BUFFER"
|
||||||
|
zle kill-whole-line
|
||||||
|
local cmd="$(NAVI_USE_FZF_ALL_INPUTS=true $_navi_path/navi --print <> /dev/tty)"
|
||||||
|
zle -U "${buff}${cmd}"
|
||||||
|
# zle accept-line
|
||||||
|
}
|
||||||
|
|
||||||
|
zle -N _call_navi
|
||||||
|
|
||||||
|
bindkey '\eg' _call_navi
|
Loading…
Reference in New Issue
Block a user