From: Alexander Barton Date: Wed, 28 Jan 2015 08:40:43 +0000 (+0100) Subject: Let tset(1) fix up TERM, don't do it "manually" X-Git-Url: https://arthur.barton.de/gitweb/?p=ConfigScripts.git;a=commitdiff_plain;h=2a7105b52eeb9c8811738fd27f3f6c315c96359c Let tset(1) fix up TERM, don't do it "manually" --- diff --git a/sys/profile b/sys/profile index 4573228..7088872 100644 --- a/sys/profile +++ b/sys/profile @@ -40,14 +40,6 @@ fi # Clean up ... unset LC_CTYPE LC_encoding 2>/dev/null -# Fix TERM: -# Use "xterm-256color" for xterm's (and the like) when it is available -[ "$TERM" = "xterm" -a -r "/usr/share/terminfo/x/xterm+256color" ] \ - && export TERM="xterm-256color" -# Don't use "xterm-256color" when it is not available -[ "$TERM" = "xterm-256color" -a -r "/usr/share/terminfo/x/xterm+256color" ] \ - || export TERM="xterm" - # Initialize PATH variable if [ -x /usr/libexec/path_helper ]; then eval `/usr/libexec/path_helper -s \ @@ -191,6 +183,10 @@ case "$-" in *) return ;; esac +# Use "xterm-256color" for xterm's (and the like) when it is available +[ "$TERM" = "xterm" -a -r "/usr/share/terminfo/x/xterm+256color" ] \ + && export TERM="xterm-256color" + # validate terminal definition type -t tset >/dev/null && eval `tset -s -Q`