summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--tag-zsh/config/zsh/zshenv17
1 files changed, 10 insertions, 7 deletions
diff --git a/tag-zsh/config/zsh/zshenv b/tag-zsh/config/zsh/zshenv
index 3e8d1da8..98050a0d 100644
--- a/tag-zsh/config/zsh/zshenv
+++ b/tag-zsh/config/zsh/zshenv
@@ -1,11 +1,14 @@
-if [[ -f $ZDOTDIR/zshenv.local ]]
+if [[ $SHLVL = 1 ]]
 then
-	. $ZDOTDIR/zshenv.local
-fi
+	if [[ -f $ZDOTDIR/zshenv.local ]]
+	then
+		. $ZDOTDIR/zshenv.local
+	fi
 
-ZPLUG_HOME=${ZPLUG_HOME:-~/projects/zplug}
+	ZPLUG_HOME=${ZPLUG_HOME:-~/projects/zplug}
 
-if [[ -z $SSH_AUTH_SOCK ]]
-then
-	export SSH_AUTH_SOCK=$XDG_RUNTIME_DIR/ssh-agent.socket
+	if [[ -z $SSH_AUTH_SOCK ]]
+	then
+		export SSH_AUTH_SOCK=$XDG_RUNTIME_DIR/ssh-agent.socket
+	fi
 fi