diff options
author | Roman Kyrylych <roman@archlinux.org> | 2007-12-12 10:28:37 -0600 |
---|---|---|
committer | Aaron Griffin <aaronmgriffin@gmail.com> | 2007-12-13 11:15:06 -0600 |
commit | 9d86b8814583509069ad6707688e2b41fc0d292f (patch) | |
tree | cba3a6c07c1b15185dc1810330868d8eef1e1e41 /functions | |
parent | 662a52c15343338e9d843c6f70d39acefd3a2c4c (diff) | |
download | initscripts-9d86b8814583509069ad6707688e2b41fc0d292f.tar.xz |
Fix FS#8843 (no colors in rc.sysinit output with separate /usr)
when tput returns exit code 3 - assume it output '8'
(as written in the /usr/share/terminfo/l/linux file)
Signed-off-by: Roman Kyrylych <roman@archlinux.org>
Converted to if/elsif form
Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
Diffstat (limited to 'functions')
-rw-r--r-- | functions | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -21,7 +21,9 @@ STAT_COL=$[$STAT_COL - 13] # disable colors on broken terminals TERM_COLORS="$(tput colors 2>/dev/null)" -if [ -n "${TERM_COLORS}" ]; then +if [ $? = 3 ]; then + TERM_COLORS=8 +elif [ -n "${TERM_COLORS}" ]; then case "${TERM_COLORS}" in *[!0-9]*) USECOLOR="" |