-
-
Notifications
You must be signed in to change notification settings - Fork 5
/
.zsh_plugins
102 lines (91 loc) · 4.71 KB
/
.zsh_plugins
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
# plugin location: `~/.local/share/zinit/plugins`
# NOTE the public iterm zsh integration is broken
# TODO the `pick` command may not be working properly
# https://github.com/decayofmind/zsh-iterm2-utilities
zinit ice depth"1" \
pick"shell_integration/zsh" \
sbin"utilities/*" if"[[ $+ITERM_PROFILE ]]"
zinit load gnachman/iTerm2-shell-integration
###########################
# Completion Setup
# This is extremely finnicky and largely undocumented.
###########################
# IMPORTANT: load order is very important here!
# important to load suggestions *after* zsh-completions
# - zicompinit runs `compinit` to generate completions, this must be loaded before other completions
# - load syntax highlighting first
# - fzf/key-bindings: sets up reverse-si via fzf, ctrl+t, alt+c
# - fzf-tab: load order is important, must go last
# - forgit needs _git to be loaded in order for the additional src to work, which is why we zicompinit
# - git-fuzzy: adds $PATH which will get drops by direnv if it modifies PATH, so important to include this in the same block as asdf
# - zsh-history-substring-search claims that it must be loaded after syntax completion, but this is not
# - zinit and one of the zsh syntax highlighting plugins claim that it must be loaded last
# - git completions were tricky as well: https://mikebian.co/git-completions-tooling-on-the-command-line/
zinit wait lucid for \
OMZ::lib/functions.zsh \
OMZ::lib/termsupport.zsh \
hlissner/zsh-autopair \
OMZ::plugins/safe-paste \
mafredri/zsh-async \
as"program" pick"bin/git-fuzzy" bigH/git-fuzzy \
wintermi/zsh-mise \
iloveitaly/zsh-ai-completions \
'https://gist.github.com/iloveitaly/4eac0f4ddb3f8162f95fa3ed6f123a06/raw/1password.zsh' \
'https://gist.github.com/iloveitaly/b0748e2f9f6831f9b8781ed8790e3404/raw/gh-cli.plugin.zsh' \
'https://gist.github.com/iloveitaly/043d91a2968597fe601673664b124dd3/raw/orbctl.zsh' \
'https://gist.github.com/iloveitaly/a3f5967aca46f10c8a6833393eb1d2e5/raw/docker.plugin.zsh' \
'https://gist.github.com/iloveitaly/357a72f0f9e70f3a7d2aa6f8c40cf956/raw/bun.plugin.zsh' \
'https://gist.github.com/iloveitaly/b3c9fb69717d0d3f209cf682b3fa34b1/raw/ov.plugin.zsh' \
'https://gist.github.com/iloveitaly/bfca38b1ae8ff649f822cea704a49a5a/raw/uv.plugin.zsh' \
'https://gist.github.com/iloveitaly/c91b3e26d47f131badec7abb859b870a/raw/azure.plugin.zsh' \
'https://gist.github.com/iloveitaly/b342092217821c92e6d478ca501af342/raw/rg.plugin.zsh' \
'https://gist.github.com/iloveitaly/9103604f442e0474dd18b4acd596739a/raw/just.plugin.zsh' \
'http://github.com/dolthub/dolt/blob/main/dolt.plugin.zsh' \
'https://github.com/junegunn/fzf/blob/master/shell/completion.zsh' \
'https://github.com/junegunn/fzf/blob/master/shell/key-bindings.zsh' \
blockf atpull'zinit creinstall .' zsh-users/zsh-completions \
'https://github.com/ajeetdsouza/zoxide/blob/main/zoxide.plugin.zsh' \
wintermi/zsh-gcloud \
'https://gist.github.com/iloveitaly/7569436744f46132cf742072fc8f4d58/raw/atuin.plugin.zsh' \
Aloxaf/fzf-tab \
atload'_zsh_autosuggest_start' zsh-users/zsh-autosuggestions \
zpm-zsh/zsh-better-npm-completion \
atinit'ZINIT[COMPINIT_OPTS]=-C; zicompinit; zicdreplay' atclone"./zplug.zsh" atpull"%atclone" g-plane/pnpm-shell-completion
# TODO conflicts with fzf-tab
# marlonrichert/zsh-autocomplete
# experimental
# - zsh-256color: configures env for 256 color support
# - colors: sets aliases for some colors and most styles via '$c'
# - lib/spectrum.zsh: 'spectrum_ls' alias to visually inspect colors
zinit wait'1' lucid for \
MichaelAquilina/zsh-auto-notify \
chrissicool/zsh-256color \
zpm-zsh/colors \
OMZ::lib/spectrum.zsh \
zpm-zsh/ssh
# binaries installed via zinit
# - git-fuzzy: 'git fuzzy' for interactive git commit cli
# - ports: 'ports ls' to inspect what ports are o pen
# - universalarchive: 'ua' for easily unarchiving everything from the command line`
# TODO `ports` seems like something that should be a CLI tool/alias
zinit wait'2' lucid for \
wfxr/forgit \
caarlos0/ports \
OMZ::plugins/extract \
OMZ::plugins/universalarchive
# must load last
zinit ice ver"non-breaking-space" compile'(pure|async).zsh' pick'async.zsh' src'pure.zsh'
zinit light iloveitaly/pure
# avoid loading the builtin git and docker completions
# https://mikebian.co/git-completions-tooling-on-the-command-line/
if command -v brew &>/dev/null; then
rm $(brew --prefix)/share/zsh/site-functions/_git 2>/dev/null
rm $(brew --prefix)/share/zsh/site-functions/_docker 2>/dev/null
fi
# function don't get completions by default, aliases need to be manually assigned
zicompdef fdd=fd
zicompdef rgg=rg
zicompdef rgu=rg
zicompdef rgc=rg
zinit load zsh-users/zsh-history-substring-search
zinit load zsh-users/zsh-syntax-highlighting