feat(main, config): the big fzf update
This commit is contained in:
parent
4de9fd9e30
commit
11a19acd9e
2 changed files with 23 additions and 1 deletions
17
main
17
main
|
@ -89,6 +89,13 @@ zinit light zsh-users/zsh-completions
|
|||
# Inline Command Suggestions based on history
|
||||
zinit light zsh-users/zsh-autosuggestions
|
||||
#
|
||||
# Initialize fzf if it exists
|
||||
if [ "${USE_FZF}" = "1" ] && command -v fzf &> /dev/null
|
||||
then
|
||||
eval "$(fzf --zsh)"
|
||||
zinit light Aloxaf/fzf-tab
|
||||
fi
|
||||
#
|
||||
# Load the zsh completion system
|
||||
autoload -U compinit && compinit
|
||||
#
|
||||
|
@ -119,6 +126,16 @@ alias ls="ls --color=auto"
|
|||
# ls like colored completions
|
||||
zstyle ':completion:*' list-colors "${(s.:.)LS_COLORS}"
|
||||
#
|
||||
# Ignore completion capitalisation
|
||||
zstyle ':completion:*' matcher-list 'm:{a-z}={A-Za-z}'
|
||||
#
|
||||
# Disable the default autocompletion if fzf exists and show a better cd completion
|
||||
if [ "${USE_FZF}" = "1" ] && command -v fzf &> /dev/null
|
||||
then
|
||||
zstyle ':completion:*' menu no
|
||||
zstyle ':fzf-tab:complete:cd:*' fzf-preview 'ls --color $realpath'
|
||||
fi
|
||||
#
|
||||
# Alias please to run0, doas, sudo or su
|
||||
if command -v doas &> /dev/null
|
||||
then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue