From 19f0d86d818fac3f69b2ac15ef06389a14e992da Mon Sep 17 00:00:00 2001 From: Simon Rieger Date: Sun, 27 Aug 2023 19:09:24 +0200 Subject: [PATCH] add fzf --- .zshrc_darwin | 2 ++ dot_fzf.bash | 13 +++++++++++++ dot_fzf.zsh | 13 +++++++++++++ 3 files changed, 28 insertions(+) create mode 100644 dot_fzf.bash create mode 100644 dot_fzf.zsh diff --git a/.zshrc_darwin b/.zshrc_darwin index 4e90083..964d457 100644 --- a/.zshrc_darwin +++ b/.zshrc_darwin @@ -9,6 +9,8 @@ fi source /opt/homebrew/share/zsh-autosuggestions/zsh-autosuggestions.zsh #source /opt/homebrew/share/zsh-autocomplete/zsh-autocomplete.plugin.zsh +[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh + PATH="$PATH:/Applications/WezTerm.app/Contents/MacOS" export PATH diff --git a/dot_fzf.bash b/dot_fzf.bash new file mode 100644 index 0000000..ebf72a7 --- /dev/null +++ b/dot_fzf.bash @@ -0,0 +1,13 @@ +# Setup fzf +# --------- +if [[ ! "$PATH" == */opt/homebrew/opt/fzf/bin* ]]; then + PATH="${PATH:+${PATH}:}/opt/homebrew/opt/fzf/bin" +fi + +# Auto-completion +# --------------- +[[ $- == *i* ]] && source "/opt/homebrew/opt/fzf/shell/completion.bash" 2> /dev/null + +# Key bindings +# ------------ +source "/opt/homebrew/opt/fzf/shell/key-bindings.bash" diff --git a/dot_fzf.zsh b/dot_fzf.zsh new file mode 100644 index 0000000..be24395 --- /dev/null +++ b/dot_fzf.zsh @@ -0,0 +1,13 @@ +# Setup fzf +# --------- +if [[ ! "$PATH" == */opt/homebrew/opt/fzf/bin* ]]; then + PATH="${PATH:+${PATH}:}/opt/homebrew/opt/fzf/bin" +fi + +# Auto-completion +# --------------- +[[ $- == *i* ]] && source "/opt/homebrew/opt/fzf/shell/completion.zsh" 2> /dev/null + +# Key bindings +# ------------ +source "/opt/homebrew/opt/fzf/shell/key-bindings.zsh"