Add e? func for quickly searching and opening files
This commit is contained in:
parent
b5a86e4b0c
commit
df0ef42f72
9
zshrc
9
zshrc
@ -55,8 +55,15 @@ if (( $+commands[direnv])); then
|
|||||||
eval "$(direnv hook zsh)"
|
eval "$(direnv hook zsh)"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Use fzf
|
||||||
|
if (( $+commands[fzf] )); then
|
||||||
|
e?() {
|
||||||
|
$EDITOR $(fzf)
|
||||||
|
}
|
||||||
|
fi
|
||||||
|
|
||||||
# Use fd for fzf
|
# Use fd for fzf
|
||||||
if (( $+commands[fd] )); then
|
if (( $+commands[fd] && $+commands[fzf] )); then
|
||||||
_fzf_compgen_path() {
|
_fzf_compgen_path() {
|
||||||
fd --hidden --follow --exclude ".git" . "$1"
|
fd --hidden --follow --exclude ".git" . "$1"
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user