Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Getting color in Putty/Secure CRT: Dumb terminal question

316 views
Skip to first unread message

mico...@gmail.com

unread,
Apr 18, 2006, 11:20:13 AM4/18/06
to
Hi,

I connect to a Sun sparc system through SecureCRT/Putty. However, I do
not get any colors with directories or xemacs/emacs. Is there anyways,
I can activate them. I have tried following configurations:

ANSI (with ANSI color)
VT 100 (which I realized does not support color later)

my ENV variables from 'env|grep term' were initially

TERM=xterm
ORIG_TERM=xterm

I later set them to TERM='xterm-color' in my .cshrc but then on login I
get the following message
tcsh: using dumb terminal settings.

Any help would be appreciated.

Thomas Dickey

unread,
Apr 18, 2006, 12:26:13 PM4/18/06
to
mico...@gmail.com wrote:

> I connect to a Sun sparc system through SecureCRT/Putty. However, I do
> not get any colors with directories or xemacs/emacs. Is there anyways,
> I can activate them. I have tried following configurations:

hmm - I recently noticed a posting in comp.unix.solaris purportedly from
a Sun employee stating that they hadn't updated their terminfo database
for ten years (since SunOS 2.5.4, iirc ;-).

> ANSI (with ANSI color)
> VT 100 (which I realized does not support color later)

yes

> my ENV variables from 'env|grep term' were initially

> TERM=xterm
> ORIG_TERM=xterm

> I later set them to TERM='xterm-color' in my .cshrc but then on login I
> get the following message
> tcsh: using dumb terminal settings.

tcsh is not able to find "xterm-color" in the terminal database. That
probably does not exist in Sun's terminfo database, unless someone has
installed ncurses' terminfo database which would not be in

/usr/share/lib/terminfo.

but perhaps in

/opt/sfw/share/terminfo

"xterm-color" is a misfeature of ncurses that I would like to disown
(see my ncurses faq). You can set the TERMINFO variable for this
purpose if ncurses' terminfo is installed, but in that case, TERM=putty
would be more apt. (I see this host has an old ncurses terminfo - no
"putty"). If you don't have a reasonably recent ncurses terminfo
database, you're best off setting $TERMINFO to one of your own
directories and using tic to install a suitable terminfo.

Depending on how old the "Sun sparc" system is, tcsh may be linked with
termcap since it was not originally a Solaris package and would have
been built ad hoc (but a check on this Solaris 8 host shows that the
package is installed here, and using terminfo):

system SUNWtcsh Tenex C-shell (tcsh)

--
Thomas E. Dickey
http://invisible-island.net
ftp://invisible-island.net

mico...@gmail.com

unread,
Apr 18, 2006, 1:19:08 PM4/18/06
to
Thanks for the detailed information. I did find xterm color in
/opt/sfw/share/terminfo folder but how do I go ahead from there.

Would setnev TERMINFO=xterm-color give color in my terminal (life)?

Or is it something else?

mico...@gmail.com

unread,
Apr 18, 2006, 1:24:55 PM4/18/06
to
i checked the web about how to set the variable TERMINFO
Now my .cshrc file reads as below

# IMPORTANT: DO NOT REMOVE THIS SOURCE STATEMENT!
source /usr/local/lib/init/master.cshrc
# ADD CHANGES BELOW THIS LINE

set notify
setenv TERMINFO
setenv TERM xterm-color

I still have no colors.

Thomas Dickey

unread,
Apr 18, 2006, 1:36:12 PM4/18/06
to
mico...@gmail.com <mico...@gmail.com> wrote:
> i checked the web about how to set the variable TERMINFO
> Now my .cshrc file reads as below

> # IMPORTANT: DO NOT REMOVE THIS SOURCE STATEMENT!
> source /usr/local/lib/init/master.cshrc
> # ADD CHANGES BELOW THIS LINE

> set notify
> setenv TERMINFO
setenv TERMINFO /opt/sfw/share/terminfo

> setenv TERM xterm-color

> I still have no colors.

Solaris ls doesn't do colors (there are some packages including GNU ls
that do). Note that GNU ls ignores termcap and terminfo, using a table
of strings matched to TERM ("putty" is not there, but "xterm-color" is
;-).

emacs/xemacs may still insist on using termcap (again, it depends on the
package).

To see if the terminfo is working, I'd markup my prompt, which is easily
doable in tcsh. You can capture the output of tput (a string) and do
that. For instance

tput setaf 2

should set the text color to green (until something resets it).

mico...@gmail.com

unread,
Apr 18, 2006, 3:13:22 PM4/18/06
to
:((

Stupid colorless solaris.....

Thomas Dickey

unread,
Apr 18, 2006, 4:10:37 PM4/18/06
to
mico...@gmail.com <mico...@gmail.com> wrote:
> :((

> Stupid colorless solaris.....

It can be made colorful. I have a half-dozen applications on this account
that I compiled to get colors...

Message has been deleted

mico...@gmail.com

unread,
Apr 18, 2006, 4:54:18 PM4/18/06
to
One last question on this acccount.

I am not that picky about colors in 'ls' as I am about having colors in
xemacs.
Would using terminal in Linux (gnome or KDE) make any difference or is
it a solaris issue ?

Thomas Dickey

unread,
Apr 19, 2006, 7:11:23 AM4/19/06
to

The responses you got in comp.emacs.xemacs seem apt enough - it's a combination
of the terminal description and emacs configuration.

mico...@gmail.com

unread,
Apr 19, 2006, 9:52:03 AM4/19/06
to
Just to update.

Adding following to my init.el in .xemacs gives four colors atleast
when I do M-x edit-faces.

(mapcar (lambda (dev)
(when (eq 'tty (device-type dev))
(set-device-class dev 'color)))
(device-list))

So Solaris is not totally colorless!

0 new messages