gnome-terminal (or VTE) sets $TERM to xterm rather than xterm-256color
问题 Is there a compelling reason why gnome-terminal (and, under the hood, maybe the VTE widget) sets $TERM to xterm rather than xterm-256color ? Clearly it supports 256 colors. For a while, I had a line in my .bashrc / .zshrc to simply export TERM=xterm-256color , because that's usually the terminal emulator that I'm using. But then I open up tmux , and the behavior / colors are wrong in many CLI applications, such as emacs and htop , because tmux will set the TERM variable to screen-256color,