zsh/dot-config/zsh/zinit
2023-10-23 15:20:13 +11:00

42 lines
1.2 KiB
Bash

#! zsh
typeset -A ZINIT
ZINIT[HOME_DIR]=$ZINIT_HOME
ZINIT[ZCOMPDUMP_PATH]=$XDG_CACHE_HOME/zsh/zcompdump
if [[ ! -f $ZINIT_HOME/bin/zinit.zsh ]]; then
git clone https://github.com/zdharma-continuum/zinit $ZINIT_HOME/bin
zcompile $ZINIT_HOME/bin/zinit.zsh
fi
source $ZINIT_HOME/bin/zinit.zsh
load=light
zinit $load willghatch/zsh-saneopt
zinit $load mafredri/zsh-async
zinit $load rupa/z
if (( $+commands[starship] )); then
source <(starship init zsh --print-full-init)
autoload starship_pure_title_precmd starship_pure_title_preexec
precmd_functions+=(starship_pure_title_precmd)
preexec_functions+=(starship_pure_title_preexec)
else
zinit $load sindresorhus/pure
fi
if (( $+commands[vivid] )); then
export LS_COLORS=$(vivid generate molokai)
else
zinit pack:no-dir-color-swap for ls_colors
fi
zinit ice silent wait:1 atload:_zsh_autosuggest_start
zinit $load zsh-users/zsh-autosuggestions
zinit ice blockf; zinit $load zsh-users/zsh-completions
zinit ice silent wait:1; zinit $load mollifier/cd-gitroot
zinit ice silent wait:1; zinit $load micha/resty
zinit ice silent wait:1; zinit $load supercrabtree/k
zinit ice silent wait!1; zinit $load zdharma-continuum/fast-syntax-highlighting