aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatarLarge Libravatar memdmp <memdmpestrogenzone>2025-05-27 18:45:55 +0200
committerLibravatarLarge Libravatar memdmp <memdmpestrogenzone>2025-05-27 18:45:55 +0200
commit50eb12378c164235026dbd6745adce5bcbab00c6 (patch)
tree1e290057d9c7757a8b35867b608a583c97520b85
parent759d8da79ee95780d8123666fdb59b6589335df2 (diff)
downloadzuwu-50eb12378c164235026dbd6745adce5bcbab00c6.tar.gz
zuwu-50eb12378c164235026dbd6745adce5bcbab00c6.tar.bz2
zuwu-50eb12378c164235026dbd6745adce5bcbab00c6.tar.lz
zuwu-50eb12378c164235026dbd6745adce5bcbab00c6.zip

feat: don't check for completion installation if _ZUWU_HYPERFAST is set

-rwxr-xr-xzuwu.zsh10
1 files changed, 8 insertions, 2 deletions
diff --git a/zuwu.zsh b/zuwu.zsh
index 4061256..0257f71 100755
--- a/zuwu.zsh
+++ b/zuwu.zsh
@@ -24,8 +24,9 @@ eval_append() {
<<<"$2" >> "$1"
eval "$2"
}
-if ! which compinit >/dev/null 2>/dev/null && ! grep compinit ~/.zshrc >/dev/null 2>/dev/null; then
- eval_append ~/.zshrc "$(<<EOF
+zuwu_compinstall() {
+ if ! which compinit >/dev/null 2>/dev/null && ! grep compinit ~/.zshrc >/dev/null 2>/dev/null; then
+ eval_append ~/.zshrc "$(<<EOF
# The following lines were added by compinstall
zstyle ':completion:*' completer _complete _ignored _approximate
zstyle ':completion:*' format 'Completing %d'
@@ -43,6 +44,11 @@ compinit
EOF
)"
+ fi
+}
+if [[ "$_ZUWU_HYPERFAST" == "" ]]; then
+ zuwu_compinstall
+ unset -f zuwu_compinstall
fi
# ZSH Env Setup