From: David Miani <nanothief@gmail.com>
To: bug-gnu-emacs@gnu.org, jasonspiro4@gmail.com
Subject: bug#1279: color output from external programs not working by default in eshell
Date: Fri, 31 Oct 2008 02:39:44 +1000 [thread overview]
Message-ID: <200810310239.44166.davidmiani@gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1968 bytes --]
When running eshell, using an external program that outputs in color results
in the raw terminal escape codes being displayed. For example,
~ $ yaourt -Ss emacs
^[[3m^[[1;32mextra/^[[0m^[[0m^[[1memacs ^[[1;32m22.3-1
^[[7m^[[1;33m[installed]^[[0m ^[[1;34m^[[0m
^[[3m The Emacs Editor^[[0m
^[[3m^[[1;32mextra/^[[0m^[[0m^[[1msnd ^[[1;32m10.1-1^[[0m ^[[1;34m^[[0m
^[[3m Snd is the emacs of sound editor^[[0m
^[[3m^[[1;32mextra/^[[0m^[[0m^[[1mtexmacs ^[[1;32m1.0.6.14-1^[[0m
^[[1;34m^[[0m
^[[3m GNU TeXmacs is a free scientific text editor, which was both
inspired by TeX^[[0m
...
However, if the following code is used in ~/.emacs (code found at
http://www.emacswiki.org/emacs/EshellColor):
(require 'ansi-color)
(require 'eshell)
(defun eshell-handle-ansi-color ()
(ansi-color-apply-on-region eshell-last-output-start
eshell-last-output-end))
(add-to-list 'eshell-output-filter-functions 'eshell-handle-ansi-color)
the output is correctly displayed in color as:
$ yaourt -Ss emacs
extra/emacs 22.3-1 [installed]
The Emacs Editor
extra/snd 10.1-1
Snd is the emacs of sound editor
extra/texmacs 1.0.6.14-1
GNU TeXmacs is a free scientific text editor, which was both inspired by
TeX
...
I think that this should be included and enabled by default with eshell, as it
doesn't change existing behaviour for non-color output, it only makes color
output readable. I have a fair few programs that output in color, and the
default behaviour made eshell unusable for me.
In GNU Emacs 22.3.1 (i686-pc-linux-gnu, GTK+ Version 2.12.11)
of 2008-09-09 on p15200770.pureserver.info
Windowing system distributor `The X.Org Foundation', version 11.0.10402000
configured using `configure '--prefix=/usr' '--sysconfdir=/etc' '--
libexecdir=/usr/lib' '--localstatedir=/var' '--mandir=/usr/share/man' '--
without-sound' '-with-x-toolkit=gtk' 'CFLAGS=-march=i686 -mtune=generic -O2 -
pipe''
[-- Attachment #2: Type: text/html, Size: 7505 bytes --]
next reply other threads:[~2008-10-30 16:39 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <877i4ovtfm.fsf@cyd.mit.edu>
2008-10-30 16:39 ` David Miani [this message]
2008-10-31 3:36 ` bug#1279: color output from external programs not working by default in eshell Stefan Monnier
2008-11-01 2:27 ` nanothief
2009-01-22 4:55 ` bug#1279: marked as done (color output from external programs not working by default in eshell) Emacs bug Tracking System
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200810310239.44166.davidmiani@gmail.com \
--to=nanothief@gmail.com \
--cc=1279@emacsbugs.donarmstrong.com \
--cc=bug-gnu-emacs@gnu.org \
--cc=jasonspiro4@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.