From: Nguyen Thai Ngoc Duy Date: Sat, 24 May 2008 09:20:39 GMT Subject: Re: [PATCH] git-grep: add --color to highlight matches Message-ID: In-Reply-To: On Sat, May 24, 2008 at 3:28 PM, Jakub Narebski wrote: > Nguyen Thai Ngoc Duy writes: > >> +--color:: >> + Show colored matches. >> + > > Why not borrow from GNU grep manpage? > > --colour[=WHEN], --color[=WHEN] > Surround the matching string with the marker find in GREP_COLOR > environment variable. WHEN may be 'never', 'always', or 'auto' > > We probably would also want it configurable (via config variables), > as `color.grep' I guess. Yes. But this patch was really to scratch my itch and I felt good after having it colorized so did not bother with configuration system. I will probably make it a config var when I get tired of typing --color too often ;) > I think compatibility with grep (using GREP_COLOR) would be good idea, > and easily implemented. I had no idea that variable existed. > -- > Jakub Narebski > Poland > ShadeHawk on #git > -- Duy