summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzachir <zachir@librem.one>2025-07-19 22:43:50 -0500
committerzachir <zachir@librem.one>2025-07-19 22:44:22 -0500
commit1e976efb21acb4a4e1046dd97e89307bba5e6baf (patch)
tree65434ca986889ae8046be54412a4ced8f518522b
parent3d3d9d5bdffcad1f32b99246591b9a03c4efe2ef (diff)
Add optimization to zsh loading
It requires using ZDOTDIR again
-rw-r--r--sh/profile2
-rw-r--r--zsh/.zshenv (renamed from zsh/zshenv)0
-rw-r--r--zsh/.zshrc (renamed from zsh/zshrc)10
3 files changed, 8 insertions, 4 deletions
diff --git a/sh/profile b/sh/profile
index 1582d5a..e4659a5 100644
--- a/sh/profile
+++ b/sh/profile
@@ -40,7 +40,7 @@ export NUGET_PACKAGES="$XDG_CACHE_HOME"/NuGetPackages
export RXVT_SOCKET="$XDG_RUNTIME_DIR"/urxvtd
export _JAVA_OPTIONS=-Djava.util.prefs.userRoot="$XDG_CONFIG_HOME"/java
export GTK2_RC_FILES="$XDG_CONFIG_HOME"/gtk-2.0/gtkrc
-#export ZDOTDIR=$HOME/.config/zsh
+export ZDOTDIR=$HOME/.config/zsh
export CARGO_HOME="$XDG_DATA_HOME"/cargo
export RUSTUP_HOME="$XDG_DATA_HOME"/rustup
export WEECHAT_HOME="$XDG_CONFIG_HOME"/weechat
diff --git a/zsh/zshenv b/zsh/.zshenv
index 3719ef4..3719ef4 100644
--- a/zsh/zshenv
+++ b/zsh/.zshenv
diff --git a/zsh/zshrc b/zsh/.zshrc
index 09a5e32..791b5d1 100644
--- a/zsh/zshrc
+++ b/zsh/.zshrc
@@ -68,7 +68,7 @@ zle -N zle-line-init
zle -N zle-keymap-select
export KEYTIMEOUT=1
-fpath+="$XDG_CONFIG_HOME/zsh/zfunc"
+#fpath+="$XDG_CONFIG_HOME/zsh/zfunc"
if [ -n "$ZPLUG_INSTALLED" ]; then
# zsh history substring search
@@ -88,8 +88,12 @@ if [ -n "$ZPLUG_INSTALLED" ]; then
zplug load
fi
-autoload -Uz compinit
-compinit -d "$XDG_CACHE_HOME"/zsh/zcompdump-"$ZSH_VERSION"
+autoload -Uz compinit
+if [[ -n ${ZDOTDIR}/.zcompdump(#qN.mh+24) ]]; then
+ compinit
+else
+ compinit -C;
+fi;
zstyle ':completion:*' hosts off