aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Polden <mpolden@mpolden.no>2023-07-22 18:07:50 +0200
committerMartin Polden <mpolden@mpolden.no>2023-07-22 18:07:50 +0200
commit777c17016c60bd21828cd2b8ef5d72bb08c60310 (patch)
tree2b3d406eabe3760525c024bf67722435eeb78d43
parentb6872d74cec5d4a81494719baf464c18b728b31e (diff)
zsh: use bfs as fzf find command
-rw-r--r--zshenv16
1 files changed, 4 insertions, 12 deletions
diff --git a/zshenv b/zshenv
index c67ec90..8caf9ec 100644
--- a/zshenv
+++ b/zshenv
@@ -92,18 +92,10 @@ elif (( $+commands[dircolors] )); then
eval "$(dircolors -b)"
fi
-# Use fd as find command in fzf
-if (( $+commands[fzf] )); then
- fd_opts="--type f --hidden"
- if (( $+commands[fdfind] )); then
- # fd binary is named fdfind on Debian
- export FZF_DEFAULT_COMMAND="fdfind ${fd_opts}"
- elif (( $+commands[fd] )); then
- export FZF_DEFAULT_COMMAND="fd ${fd_opts}"
- fi
- unset fd_opts
- # Use fd when finding files with C-t
- [[ -n "$FZF_DEFAULT_COMMAND" ]] && export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND"
+# Use bfs as find command in fzf
+if (( $+commands[fzf] && $+commands[bfs] )); then
+ export FZF_DEFAULT_COMMAND="bfs"
+ export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND"
fi
# Remove mosh prefix from terminal title