GNU bug report logs - #20062
[PATCH] diff: add support for --color

Previous Next

Package: diffutils;

Reported by: Giuseppe Scrivano <gscrivan <at> redhat.com>

Date: Sun, 8 Mar 2015 21:57:02 UTC

Severity: normal

Tags: patch

Done: Jim Meyering <jim <at> meyering.net>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Norihiro Tanaka <noritnk <at> kcn.ne.jp>
To: Giuseppe Scrivano <gscrivan <at> redhat.com>
Cc: Andreas Grunbacher <agruen <at> gnu.org>, 20062 <20062 <at> debbugs.gnu.org>
Subject: bug#20062: [bug-diffutils] bug#20062: bug#20062: bug#20062: bug#20062: [PATCH] diff: add support for --color
Date: Mon, 16 Mar 2015 08:49:29 +0900
Giuseppe Scrivano <gscrivan <at> redhat.com> wrote:

> I think the default for --color should be auto.  Outputting stdout to a
> file happens more often with diff than with ls and having the colors
> commands in a diff file is to be avoided as much as possible (if people
> really want it, then they can force it with always).

I disagree.  I think we should not make difference for default among
diff, ls and grep, and they should not also be neither AUTO nor ALWAYS.

AUTO and ALWAYS are POSIX incompatible, as they change output in byte
level.  So I think that if only users and/or distributors expect it,
they should manually change color option into AUTO or ALWAYS.

> grep seems to default to "auto" as well when --color is specified.

However, grep will suffer from the disadvantage of performance down with
--color option.





This bug report was last modified 8 years and 80 days ago.

Previous Next


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