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

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

bug#20728: 25.0.50; grep and grep-find templates should have a place hol


From: Eli Zaretskii
Subject: bug#20728: 25.0.50; grep and grep-find templates should have a place holder for the --color argument
Date: Mon, 29 Jun 2015 18:26:38 +0300

> Cc: 20728@debbugs.gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> Date: Mon, 29 Jun 2015 18:01:58 +0300
> 
> >> Whether we want a given command to use a colorized Grep output, is not
> >> dependent on the OS, is it?
> >
> > I don't think so.  But it might depend on the values of grep-program
> > etc., i.e. on user customizations.  Users might want to put shell
> > scripts or pipelines there.
> 
> Well, okay. If it's a significant use case, we might want to continue 
> supporting it.

I don't know if it's a significant use case.  Maybe it isn't, and we
should just go ahead and do what you suggest.

> On the other hand, we might want to choose to set 
> `grep-highlight-matches' to `always' in grep-compute-defaults, 
> irrespective of the OS.

Won't that bring back the problem in symref/grep.el again?

> So that every command that knows it does not need the ANSI codes, will 
> bind this variable to nil without relying on auto-detection thanks to 
> calling Grep via a pipe. Then we won't have to test on Windows to find 
> bugs like that.

Assuming we can count on commands that live far away, like
symref/grep.el, to make a point of doing this, it will work, of
course.

> And if a user customized grep-program, etc, to unexpectedly postprocess 
> Grep ouput using a pipe, they can customize `grep-highlight-matches' to 
> `auto' as well.

Yes, given enough documentation that mentions this.





reply via email to

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