Reuben Thomas wrote:
> Note that shell-mode can handle colour via ansi-color.el (from
the
> text-modes package); use ansi-color-for-comint-mode-on to enable it.
Yes; I'd already found this, but just colouring wasn't enough. Also,
for the main thing for which this would be useful, ls --color, this
would need some fiddling in my .bashrc, because dircolors rightly
notices that TERM=emacs doesn't support colour, and so doesn't set
things up right. I guess the thing to do would be to temporarily set
TERM to vt100, run dircolors, and then restore it, but if you have a
better suggestion, I'd be glad to hear it.
Either modify the "emacs" terminfo/termcap entry to indicate that it
supports ANSI colour, with:
colors#8,
and
setab=\E[4%p1%dm, setaf=\E[3%p1%dm,
or create a new, colour-enabled, terminfo/termcap entry and use that
instead of "emacs" (you would have to hard-code it; comint doesn't
have an equivalent of term-term-name).
--
Glynn Clements <glynn.clements(a)virgin.net>