GNU bug report logs - #5211
Color escape codes in the output of vc-git-print-log

Previous Next

Package: emacs;

Reported by: Juanma Barranquero <lekktu <at> gmail.com>

Date: Mon, 14 Dec 2009 16:20:04 UTC

Severity: minor

Tags: patch

Found in version 23.1.90

Done: Juanma Barranquero <lekktu <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: bug-gnu-emacs <at> gnu.org (Emacs bug Tracking System)
To: Juanma Barranquero <lekktu <at> gmail.com>
Subject: bug#5211 closed by Juanma Barranquero <lekktu <at> gmail.com> (Re:
 bug#5211: Color escape codes in the output of vc-git-print-log)
Date: Mon, 28 Dec 2009 02:49:02 +0000
[Message part 1 (text/plain, inline)]
This is an automatic notification regarding your bug report
which was filed against the emacs,vc package:

#5211: Color escape codes in the output of vc-git-print-log

It has been closed by Juanma Barranquero <lekktu <at> gmail.com>.

Their explanation is attached below along with your original report.
If this explanation is unsatisfactory and you have not received a
better one in a separate message then please contact Juanma Barranquero <lekktu <at> gmail.com> by
replying to this email.


-- 
5211: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=5211
Emacs Bug Tracking System
Contact bug-gnu-emacs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Juanma Barranquero <lekktu <at> gmail.com>
To: Andreas Schwab <schwab <at> linux-m68k.org>
Cc: 5211-done <at> debbugs.gnu.org
Subject: Re: bug#5211: Color escape codes in the output of vc-git-print-log
Date: Mon, 28 Dec 2009 03:47:52 +0100
On Wed, Dec 16, 2009 at 00:57, Juanma Barranquero <lekktu <at> gmail.com> wrote:

> So --no-color was first included in a release of 2006-08-13. Is that
> old enough? (git 1.0.0 is from 2005-12-21, barely eight months
> earlier, so 1.4.2 is quite old indeed).

I've committed this change (with the acquiescence of Chong Yidong).

    Juanma

[Message part 3 (message/rfc822, inline)]
From: Juanma Barranquero <lekktu <at> gmail.com>
To: Bug-Gnu-Emacs <bug-gnu-emacs <at> gnu.org>
Subject: Color escape codes in the output of vc-git-print-log
Date: Mon, 14 Dec 2009 17:12:24 +0100
Package: emacs,vc
Tags: patch
Version: 23.1.90
Severity: minor


Depending of your setting of color.diff, color is used for log output,
and vc-print-log shows garbage (OK, escape codes for color):

^[[33mcommit 43a3bf88e5e495ad048b3a6d3cf852e1e7a02f1c^[[m
Author: xxx <yyy <at> zzz>
Date:   2009-12-14 17:11:35 +0200

    blah blah blah


As color in *vc-change-log* buffers is an issue for font-locking, and
not for git log, the command should be called with --no-color.

OK to the following patch?

    Juanma


2009-12-14  Juanma Barranquero  <lekktu <at> gmail.com>

	* vc-git.el (vc-git-print-log): Pass --no-color to `git log'.


=== modified file 'lisp/vc-git.el'
--- lisp/vc-git.el	2009-12-08 15:56:57 +0000
+++ lisp/vc-git.el	2009-12-14 16:08:54 +0000
@@ -555,7 +555,7 @@
 	(apply 'vc-git-command buffer
 	       'async files
 	       (append
-		'("log")
+		'("log" "--no-color")
 		(when shortlog
 		  '("--graph" "--decorate"
 		    "--date=short" "--pretty=format:%d%h  %ad  %s" "--abbrev-commit"))



This bug report was last modified 15 years and 149 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.