feat: Add oh-my-zsh plugin compatibility.

This commit is contained in:
Alexandre Beaulieu 2019-09-30 14:09:35 -04:00
parent 0c960fca54
commit 32b1b42f2c
No known key found for this signature in database
GPG key ID: 8B02EA7AE3FC7081

13
navi.plugin.zsh Normal file
View 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