X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=core%2F90_theme%2F90_theme.zshrc;h=7fb4301287afbc74a0a94755b38d23e5f6eba832;hb=602d2931b1cd78bbfb75a4e1fd8de7e6a8553689;hp=a6325c2ac01c234aec268632e68d184e2f605f96;hpb=ebe1d8780721dd40f8352f4fd639b0c272cd96d7;p=ax-zsh.git diff --git a/core/90_theme/90_theme.zshrc b/core/90_theme/90_theme.zshrc index a6325c2..7fb4301 100644 --- a/core/90_theme/90_theme.zshrc +++ b/core/90_theme/90_theme.zshrc @@ -1,6 +1,25 @@ # AX-ZSH: Alex' Modular ZSH Configuration # 90_theme.zshrc: Load AX-ZSH theme -[[ -n "$AXZSH_THEME" ]] && source "$AXZSH_THEME" +# Don't load any "enhanced" theme on dumb terminals, but instead use a very +# simple and sane built-in prompt that should work "everywhere". And try to +# make sure that nothing else "disturbs" such terminals ... +if ! axzsh_is_modern_terminal; then + if axzsh_is_dumb_terminal; then + # Don't use any theme on dumb terminals! + unset AXZSH_THEME -axzsh_is_dumb_terminal && unset RPS1 + # Set simple prompt: + PS1="%n@%m:%3~ %# " + unset RPS1 + else + # Use the default theme on legacy ("not modern") terminals: + AXZSH_THEME="$AXZSH/themes/ax.axzshtheme" + fi + + # See + unset zle_bracketed_paste +fi + +# 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).