git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Add git-rev-list --invert-match

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Sep 21, 2007, 09:10 UTC
Message-ID
<Pine.LNX.4.64.0709210904210.28395@racer.site>
In-Reply-To
<20070921041821.GA28245@coredump.intra.peff.net>
Hi,
On Fri, 21 Sep 2007, Jeff King wrote:
Show 13 quoted lines
> On Thu, Sep 20, 2007 at 02:12:54PM +0100, Johannes Schindelin wrote:
> 
> > Further, it probably makes sense to have the option to say _both_: "Find 
> > me a commit that contains Bart in one line, but not Simpson, and that 
> > does not contain the word "Sverdoolaege" at all."
> 
> This is perhaps a little hack-ish compared to better grep support in the
> core, but I find complex logic through command line options to be
> somewhat unreadable. I prefer something more Perl-ish like this:
> 
>   git-revgrep 'message =~ /bart/i
>                && message !~ /Simpson/
>                && author_name !~ /Sverdoolaege/'

Indeed, it has a certain elegance to it. However, I cannot specify any rev-list options with your method, not even "--stat" or "--pretty=format:%H(%s)".

So while your script is a good interim solution, I'd like to see a generic grep support for this feature.

Ciao, Dscho

Previous: Jeff KingNext: Jeff King
Message 12 of 13 in “Add git-rev-list --invert-match”
  1. Add git-rev-list --invert-matchBart Trojanowski, Sep 19, 2007
  2. Add git-rev-list --invert-matchBart Trojanowski, Sep 20, 2007
  3. Junio C HamanoSep 20, 2007
  4. Bart TrojanowskiSep 20, 2007
  5. Johannes SchindelinSep 20, 2007
  6. Bart TrojanowskiSep 20, 2007
  7. Johannes SchindelinSep 20, 2007
  8. Junio C HamanoSep 20, 2007
  9. Johannes SchindelinSep 20, 2007
  10. [RFC] Add git-rev-list --not-(author|committer|grep)!=patternBart Trojanowski, Sep 22, 2007
  11. Jeff KingSep 21, 2007
  12. Johannes SchindelinSep 21, 2007
  13. Jeff KingSep 21, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.