help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Emacs Shell Ansi Colors


From: Thierry Volpiatto
Subject: Re: Emacs Shell Ansi Colors
Date: Sun, 28 Sep 2008 23:19:54 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

Hi Lorenzo,

Lorenzo Isella <lorenzo.isella@gmail.com> writes:

> Dear All,
> I often use M-x shell to open a shell within Emacs.  Since I miss the
> colorized output, I tried to enable ansi-colors in my Emacs shell.
> After googling, I found suggestions along the lines of the link pasted
> below
>
> http://www.grokblok.com/articles/2007/12/13/emacs-shell-ansi-colors/
>
> The problem is that I added those few lines to my .emacs file, but
> nothing changed.
> I had a look also at:
> http://www.emacswiki.org/cgi-bin/wiki/ansi-color.el
> but I did not copy the ansi-color.el file anywhere in my system (in
> case it matters, I am running emacs22 on a Debian testing box).
> I notice that issuing the command (within emacs shell):
> ls --color=yes
> give the nice colorized output I am looking for, hence I do not think
> there is any substantial problem by default, just it seems that my
> output is not colorized by default (though when I type M-x shell I
> read the message
> Loading ansi-color...done ).
> Can anyone help me out with this?
> Many thanks

Try that in your .emacs:

,----
| (autoload 'ansi-color-for-comint-mode-on "ansi-color" nil t)
| (add-hook 'shell-mode-hook 'ansi-color-for-comint-mode-on)
`----

-- 
A + Thierry Volpiatto
Location: Saint-Cyr-Sur-Mer - France





reply via email to

[Prev in Thread] Current Thread [Next in Thread]