* bug#1279: color output from external programs not working by default in eshell @ 2008-10-30 16:39 ` David Miani 2008-10-31 3:36 ` Stefan Monnier 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 0 siblings, 2 replies; 4+ messages in thread From: David Miani @ 2008-10-30 16:39 UTC (permalink / raw) To: bug-gnu-emacs, jasonspiro4 [-- 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 --] ^ permalink raw reply [flat|nested] 4+ messages in thread
* bug#1279: color output from external programs not working by default in eshell 2008-10-30 16:39 ` bug#1279: color output from external programs not working by default in eshell David Miani @ 2008-10-31 3:36 ` 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 1 sibling, 1 reply; 4+ messages in thread From: Stefan Monnier @ 2008-10-31 3:36 UTC (permalink / raw) To: David Miani; +Cc: bug-gnu-emacs, 1279, jasonspiro4 > 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 > ... FWIW, I consider it a bug for such programs to output ANSI escape sequences for color unless they have some concrete evidence that the terminal to which they talk does understand those escape sequences. What does $TERM say in your shell? Is this terminal type known to support color? If so, specifying such a terminal type is an error and we try and figure out where it comes from so we can fix it. Stefan ^ permalink raw reply [flat|nested] 4+ messages in thread
* bug#1279: color output from external programs not working by default in eshell 2008-10-31 3:36 ` Stefan Monnier @ 2008-11-01 2:27 ` nanothief 0 siblings, 0 replies; 4+ messages in thread From: nanothief @ 2008-11-01 2:27 UTC (permalink / raw) To: 1279 [-- Attachment #1: Type: text/plain, Size: 802 bytes --] > What does $TERM say in your shell? Is this terminal type known to > support color? If so, specifying such a terminal type is an error and > we try and figure out where it comes from so we can fix it. Well running in eshell echo $TERM gives no output. and I often get the error message "tput: No value for $TERM and no -T specified". Running the command export TERM="dumb" stops the error messages, but the program still outputs in color. Note that the program probably doesn't work correctly with a non-color shell, as it is meant as an advancement on another program, so it is unlikely the developers tested it with a non-color term. However, I'm not sure how relevant this is to this bug, as if eshell can be made to work easily with color, then why not set it as default? [-- Attachment #2: Type: text/html, Size: 2303 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
* bug#1279: marked as done (color output from external programs not working by default in eshell) 2008-10-30 16:39 ` bug#1279: color output from external programs not working by default in eshell David Miani 2008-10-31 3:36 ` Stefan Monnier @ 2009-01-22 4:55 ` Emacs bug Tracking System 1 sibling, 0 replies; 4+ messages in thread From: Emacs bug Tracking System @ 2009-01-22 4:55 UTC (permalink / raw) To: Chong Yidong [-- Attachment #1: Type: text/plain, Size: 922 bytes --] Your message dated Wed, 21 Jan 2009 23:46:53 -0500 with message-id <877i4ovtfm.fsf@cyd.mit.edu> and subject line Re: color output from external programs not working by default in eshell has caused the Emacs bug report #1279, regarding color output from external programs not working by default in eshell to be marked as done. This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact owner@emacsbugs.donarmstrong.com immediately.) -- 1279: http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=1279 Emacs Bug Tracking System Contact owner@emacsbugs.donarmstrong.com with problems [-- Attachment #2: Type: message/rfc822, Size: 12983 bytes --] [-- Attachment #2.1.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.1.2: Type: text/html, Size: 7505 bytes --] [-- Attachment #3: Type: message/rfc822, Size: 1088 bytes --] From: Chong Yidong <cyd@stupidchicken.com> To: 1279-done@emacsbugs.donarmstrong.com Subject: Re: color output from external programs not working by default in eshell Date: Wed, 21 Jan 2009 23:46:53 -0500 Message-ID: <877i4ovtfm.fsf@cyd.mit.edu> The 2009-01-21 checkin by John Wiegley fixes this. ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-01-22 4:55 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- [not found] <877i4ovtfm.fsf@cyd.mit.edu> 2008-10-30 16:39 ` bug#1279: color output from external programs not working by default in eshell David Miani 2008-10-31 3:36 ` 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
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.