1
0
mirror of https://github.com/frebib/dotfiles.git synced 2024-06-14 12:57:23 +00:00

zsh: move compinit to end of zshrc

This saves one compinit load, from 3 to 2 which should slightly reduce startup time
This commit is contained in:
Joe Groocock 2020-05-17 12:39:39 +01:00
parent fbb43dfff5
commit ee9af5eeca
Signed by: frebib
GPG Key ID: E0B16BEACFBB6A86

View File

@ -44,15 +44,6 @@ fi
setopt sharehistory histignorealldups histignorespace histreduceblanks
setopt pathdirs autocd autopushd extendedglob nullglob alwaystoend interactivecomments dvorak
# Completion initialisation
autoload -U compinit ; compinit
autoload -U bashcompinit ; bashcompinit
# gopass completion
if exists gopass; then
source <(gopass completion bash)
fi
zstyle ':completion:*:sudo|_::' environ PATH="/sbin:/usr/sbin:$PATH" HOME="/root"
zstyle ':completion:*' matcher-list '' 'm:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'r:|[._-]=** r:|=**' 'l:|=* r:|=*'
zstyle ':completion:*' rehash true
@ -175,3 +166,13 @@ source "$ZSH_DIR/plugins/git-rprompt.zsh"
[ -f '/usr/share/fzf/key-bindings.zsh' ] && source /usr/share/fzf/key-bindings.zsh
[ -f '/usr/share/doc/pkgfile/command-not-found.zsh' ] && source /usr/share/doc/pkgfile/command-not-found.zsh
[ -r '/usr/share/z/z.sh' ] && source /usr/share/z/z.sh
# Completion initialisation
autoload -U compinit bashcompinit
compinit
bashcompinit
# gopass completion
if exists gopass; then
source <(gopass completion bash)
fi