I have my dotfiles versioned on github (shameless fork of other people's fine work). At work, I have them on a central linux server (SuSE Enterprise Linux 10). I rsync them from a central management server to target servers (they often don't have external http access).
We've rolled out SuSE Enterprise Linux 11 and I'm noticing on those servers "red" or magenta bash prompt colors from my profile settings don't seem to be working. Similarly, my vim colorscheme settings don't work - for example instead of search-term highlighting, the word disappears. Reds and yellows aren't honored.
Can someone point me to an env var or setting that might be different on these SLES 11 boxes? Below are screenshots of my SLES10 vs SLES11 logins with dotfiles in sync (e.g. .bash_profile, .bash_prompt, .vimrc, etc).
$TERM on both servers is
xterm-256color. **see update notes
From a SLES10 server:
Same dotfiles, but on a SLES11 server:
- I noticed $TERM was different if I SSHed directly from my workstation versus from the SLES10 utility server. I believe TERM is being forwarded from the utility server.
- The .bash_prompt init script sets
$TERMbased on the output of
infocmpwhich comes from the
ncurses-develpackage which I've confirmed isn't on the SLES11 server image. If
infocmpdoesn't run or isn't available,
$TERMis left unset or whatever it was before the script ran.
- In the event that
$TERMis inherited (already set), the .bash_prompt script conditional logic currently leaves it untouched when
- The .bash_prompt script then uses
tputcommands to initialize several vars with color codes - values far above the 8 color default.
tputis influenced by
My current theory: my
PS1 setup script may be emitting some unsupported terminal values - set earlier from conditional logic based on commands that are influenced by the incorrect/unsupported
$TERM. This then “messes up” subsequent commands like
Can anyone confirm this theory based on their understanding of
tput and the influence of
ncurses on the system? I've noticed articles about how ncurses enables more color values in the terminal.