r1260 - trunk/etc

Alexander E. Patrakov patrakov at ums.usu.ru
Sun Dec 11 05:04:35 PST 2005


jhuntwork at linuxfromscratch.org wrote:

>+case $TERM in
>+	xterm*)
>+		BOLD=$WHITE ;;
>+	*)
>+		BOLD="\[\033[0;38m\]" ;;
>+esac
>+
>  
>
1) This still doesn't work as expected in Terminal

2) I found a better form for this, and it works for arbitrary terminal type:

BOLD=`tput bold`

If you want both bold and underlined:

tput sgr 0 1 0 0 0 1 0 0 0 ; echo Bold Underlined Text ; tput sgr0

For more details:

man tput
man terminfo

BTW I think that it is a good idea to extend this scheme to other color 
variables.

-- 
Alexander E. Patrakov



More information about the livecd mailing list