chore(zinit): switch to newer for-syntax for zinit declarations

This commit is contained in:
2022-04-28 12:10:39 +01:00
parent a5671fca28
commit 44ea1976e4
13 changed files with 73 additions and 71 deletions

View File

@@ -2,7 +2,8 @@
# direnv setup
#
zinit ice wait lucid from'gh-r' as'program' mv'direnv* -> direnv' \
zinit light-mode wait lucid from'gh-r' as'program' pick'direnv' \
mv'direnv* -> direnv' \
atclone'./direnv hook zsh > .zinitrc.zsh' atpull'%atclone' \
pick'direnv' src='.zinitrc.zsh'
zinit light direnv/direnv
src='.zinitrc.zsh' \
for @direnv/direnv

View File

@@ -3,8 +3,8 @@
#
if command-exists docker; then
zinit ice wait lucid from'gh-r' as'program' mv'ctop-* -> ctop'
zinit light bcicen/ctop
zinit light-mode wait lucid from'gh-r' as'program' mv'ctop-* -> ctop' \
for @bcicen/ctop
fi
docker_remove_exited() {

View File

@@ -20,8 +20,8 @@ fi
path_prepend "$HOME/.config/doom-emacs/bin"
# install emacs-sandbox.sh
zinit ice wait lucid as'program' pick'emacs-sandbox.sh' from'gh'
zinit light alphapapa/emacs-sandbox.sh
zinit light-mode wait lucid as'program' pick'emacs-sandbox.sh' from'gh' \
for @alphapapa/emacs-sandbox.sh
# Setup vterm if shell is within vterm inside Emacs.
if [[ "$INSIDE_EMACS" = 'vterm' ]]; then

View File

@@ -8,11 +8,11 @@ export FZF_TMUX=0
export FZF_CTRL_T_OPTS="--preview='less {}'"
# Install fzf binary from latest GitHub Release.
zinit ice wait lucid from'gh-r' as'program' pick'fzf'
zinit light junegunn/fzf
zinit light-mode wait lucid from'gh-r' as'program' pick'fzf' \
for @junegunn/fzf
# Install fzf-tmux command and zsh plugins from default branch on GitHub.
zinit ice wait lucid from'gh' as'program' pick'bin/fzf-tmux' \
zinit light-mode wait lucid from'gh' as'program' pick'bin/fzf-tmux' \
multisrc'shell/{completion,key-bindings}.zsh' \
id-as'junegunn/fzf-extras'
zinit light junegunn/fzf
id-as'junegunn/fzf-extras' \
for @junegunn/fzf

View File

@@ -7,9 +7,9 @@
# ==============================================================================
# Create symlink for "g" called "gv", as I have "g" aliased to "git".
zinit ice wait lucid as'program' pick'bin/g' from'gh' \
atclone'cd bin && ln -s g gv' atpull'%atclone'
zinit light stefanmaric/g
zinit light-mode wait lucid as'program' pick'bin/g' from'gh' \
atclone'cd bin && ln -s g gv' atpull'%atclone' \
for @stefanmaric/g
# ==============================================================================
# global golang packages

View File

@@ -19,8 +19,8 @@ if command-exists kubectl; then
switch "$@"
}
zinit ice wait lucid as'program' from'gh-r'
zinit light stackrox/kube-linter
zinit light-mode wait lucid as'program' from'gh-r' \
for @stackrox/kube-linter
if ! kubectl krew &> /dev/null; then
krew-bin() {
@@ -29,30 +29,30 @@ if command-exists kubectl; then
-e 's/aarch64$/arm64/')"
}
zinit ice wait lucid as'null' from'gh-r' bpick'krew.tar.gz' \
atclone'KREW='"'$(krew-bin)'"' && ./$KREW install krew'
zinit light kubernetes-sigs/krew
zinit light-mode wait lucid as'null' from'gh-r' bpick'krew.tar.gz' \
atclone'KREW='"'$(krew-bin)'"' && ./$KREW install krew' \
for @kubernetes-sigs/krew
export KREW_ROOT="$HOME/.krew"
path_append "${KREW_ROOT}/bin"
fi
zinit ice wait lucid as'program' from'gh-r' mv'kind-* -> kind' \
atclone'./kind completion zsh > _kind' atpull'%atclone'
zinit light kubernetes-sigs/kind
zinit light-mode wait lucid as'program' from'gh-r' mv'kind-* -> kind' \
atclone'./kind completion zsh > _kind' atpull'%atclone' \
for @kubernetes-sigs/kind
zinit ice wait lucid as'program' from'gh-r' \
atclone'./flux completion zsh > _flux' atpull'%atclone'
zinit light fluxcd/flux2
zinit light-mode wait lucid as'program' from'gh-r' \
atclone'./flux completion zsh > _flux' atpull'%atclone' \
for @fluxcd/flux2
zinit ice wait lucid as'program' from'gh-r' \
atclone'./kustomize completion zsh > _kustomize' atpull'%atclone'
zinit light kubernetes-sigs/kustomize
zinit light-mode wait lucid as'program' from'gh-r' \
atclone'./kustomize completion zsh > _kustomize' atpull'%atclone' \
for @kubernetes-sigs/kustomize
zinit ice wait lucid as'program' from'gh-r' pick'kubeseal'
zinit light bitnami-labs/sealed-secrets
zinit light-mode wait lucid as'program' from'gh-r' pick'kubeseal' \
for @bitnami-labs/sealed-secrets
zinit ice wait lucid as'program' from'gh-r' mv'argocd-* -> argocd' \
atclone'./argocd completion zsh > _argocd' atpull'%atclone'
zinit light argoproj/argo-cd
zinit light-mode wait lucid as'program' from'gh-r' mv'argocd-* -> argocd' \
atclone'./argocd completion zsh > _argocd' atpull'%atclone' \
for @argoproj/argo-cd
fi

View File

@@ -10,6 +10,6 @@ export TERM="xterm-256color"
path_append "/opt/tigervnc/bin"
zinit ice wait lucid as'program' from'gh-r' mv'shfmt* -> shfmt' \
atclone'./shfmt completions zsh > _shfmt' atpull'%atclone'
zinit light mvdan/sh
zinit light-mode wait lucid as'program' from'gh-r' mv'shfmt* -> shfmt' \
atclone'./shfmt completions zsh > _shfmt' atpull'%atclone' \
for @mvdan/sh

View File

@@ -16,9 +16,9 @@ elif [[ "$OSTYPE" == "linux"* ]]; then
zinit_volta_bpick='*linux-openssl-1.1.tar.gz'
fi
zinit ice wait lucid as'program' from'gh-r' bpick"$zinit_volta_bpick" \
atclone'./volta completions zsh > _volta' atpull'%atclone'
zinit light volta-cli/volta
zinit light-mode wait lucid as'program' from'gh-r' bpick"$zinit_volta_bpick" \
atclone'./volta completions zsh > _volta' atpull'%atclone' \
for @volta-cli/volta
# ==============================================================================
# aliases

View File

@@ -7,14 +7,14 @@
# ==============================================================================
# install pyenv
zinit ice wait lucid as'program' pick'bin/pyenv' from'gh' \
zinit light-mode wait lucid as'program' pick'bin/pyenv' from'gh' \
atclone'src/configure && make -C src; libexec/pyenv init - > .zinitrc.zsh' \
atpull'%atclone' src'.zinitrc.zsh' nocompile'!'
zinit light pyenv/pyenv
atpull'%atclone' src'.zinitrc.zsh' nocompile'!' \
for @pyenv/pyenv
zinit ice wait lucid as'program' pick'plugins/python-build/bin/python-build' \
from'gh' id-as'pyenv/python-build'
zinit light pyenv/pyenv
zinit light-mode wait lucid as'program' pick'plugins/python-build/bin/python-build' \
from'gh' id-as'pyenv/python-build' \
for @pyenv/pyenv
# ==============================================================================
# aliases

View File

@@ -2,6 +2,6 @@
# Rclone
#
zinit ice wait lucid as'program' from'gh-r' mv'**/rclone -> rclone' \
atclone'./rclone genautocomplete zsh - > _rclone' atpull'%atclone'
zinit light rclone/rclone
zinit light-mode wait lucid as'program' from'gh-r' mv'**/rclone -> rclone' \
atclone'./rclone genautocomplete zsh - > _rclone' atpull'%atclone' \
for @rclone/rclone

View File

@@ -7,18 +7,18 @@
# ==============================================================================
# Install rbenv
zinit ice wait lucid as'program' pick'bin/rbenv' from'gh' \
zinit light-mode wait lucid as'program' pick'bin/rbenv' from'gh' \
atclone'src/configure && make -C src; libexec/rbenv init - > .zinitrc.zsh' \
atpull'%atclone' src'.zinitrc.zsh' nocompile'!'
zinit light rbenv/rbenv
atpull'%atclone' src'.zinitrc.zsh' nocompile'!' \
for @rbenv/rbenv
# install ruby-build
zinit ice wait lucid as'program' pick'bin/ruby-build' from'gh'
zinit light rbenv/ruby-build
zinit light-mode wait lucid as'program' pick'bin/ruby-build' from'gh' \
for @rbenv/ruby-build
# install rbenv-each plugin
zinit ice wait lucid as'program' pick'bin/rbenv-each' from'gh'
zinit light rbenv/rbenv-each
zinit light-mode wait lucid as'program' pick'bin/rbenv-each' from'gh' \
for @rbenv/rbenv-each
# ==============================================================================
# aliases

View File

@@ -11,10 +11,10 @@ alias tmm="tmn -s main"
# Tmuxifier
zinit ice wait lucid as'program' pick'bin/tmuxifier' from'gh' \
zinit light-mode wait lucid as'program' pick'bin/tmuxifier' from'gh' \
atclone'./bin/tmuxifier init - > .zinitrc.zsh' atpull'%atclone' \
src='.zinitrc.zsh'
zinit light jimeh/tmuxifier
src='.zinitrc.zsh' \
for @jimeh/tmuxifier
alias m="tmuxifier"
alias ms="tmuxifier load-session"

25
zshrc
View File

@@ -48,27 +48,28 @@ zinit snippet OMZ::plugins/git
zinit cdclear -q # forget completions provided up to this point
# Enable interactive selection of completions.
zinit snippet OMZ::lib/completion.zsh
zinit for @OMZ::lib/completion.zsh
# Set various sane defaults for ZSH history management.
zinit snippet OMZ::lib/history.zsh
zinit for @OMZ::lib/history.zsh
# Enable Ruby Bundler plugin from oh-my-zsh.
zinit snippet OMZ::plugins/bundler
zinit for @OMZ::plugins/bundler
zinit ice lucid as'program' from'gh-r' \
zinit light-mode lucid as'program' from'gh-r' \
atclone'./starship completions zsh > _starship; ./starship init zsh --print-full-init > .zinitrc.zsh' \
atpull'%atclone' pick'starship' src'.zinitrc.zsh'
zinit light starship/starship
atpull'%atclone' pick'starship' src'.zinitrc.zsh' \
for @starship/starship
zinit ice wait lucid atinit"ZINIT[COMPINIT_OPTS]=-C; zicompinit; zicdreplay"
zinit light zdharma-continuum/fast-syntax-highlighting
zinit light-mode wait lucid \
atinit"ZINIT[COMPINIT_OPTS]=-C; zicompinit; zicdreplay" \
for @zdharma-continuum/fast-syntax-highlighting
zinit ice wait lucid blockf
zinit light zsh-users/zsh-completions
zinit light-mode wait lucid blockf \
for @zsh-users/zsh-completions
zinit ice wait lucid atload"!_zsh_autosuggest_start"
zinit light zsh-users/zsh-autosuggestions
zinit light-mode wait lucid atload"!_zsh_autosuggest_start" \
for @zsh-users/zsh-autosuggestions
# ==============================================================================
# Completion