for plugin ($plugin_list); do
axzsh_load_plugin "$plugin" "$script_type" "$cache_file"
done
+
+ # Read the "theme file", if any and in "zshrc" stage:
+ if [[ "$script_type" = "zshrc" ]]; then
+ if [[ -r "$AXZSH_THEME" ]]; then
+ source "$AXZSH_THEME"
+ if [[ -n "$cache_file" ]]; then
+ # Include the theme into the new cache file:
+ echo "# BEGIN Theme" >>"$cache_file"
+ "$cat_cmd" "$AXZSH_THEME" >>"$cache_file"
+ echo "# END Theme" >>"$cache_file"
+ fi
+ fi
+ fi
fi
# Clean up ...
# simple and sane built-in prompt that should work "everywhere". And try to
# make sure that nothing else "disturbs" such terminals ...
if axzsh_is_dumb_terminal; then
+ unset AXZSH_THEME
+
+ # Set simple prompt:
PS1="%n@%m:%3~ %# "
unset RPS1
# See <https://github.com/syl20bnr/spacemacs/issues/3035>
unset zle_bracketed_paste
-
- return
fi
-# Read in the theme configuration.
-[[ -n "$AXZSH_THEME" ]] && source "$AXZSH_THEME"
+# NOTE: The theme itself is read in by the ax.zsh script itself: last and into
+# the global context (code for the cache file is generated as required).