Color support for more xterms

This commit is contained in:
Kevin van Zonneveld 2014-07-23 11:30:33 +02:00
parent 667bfd7350
commit 3f8ac03553

View File

@ -54,8 +54,8 @@ function _fmt () {
fi
color_reset="\x1b[0m"
if [ "${TERM}" != "xterm" ] || [ -t 1 ]; then
local color_reset="\x1b[0m"
if [[ "${TERM}" != "xterm"* ]] || [ -t 1 ]; then
# Don't use colors on pipes or non-recognized terminals
color=""
color_reset=""