Re: Git bug: Filter ignored when "--invert-grep" option is used.

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

 



Dotan Cohen <dotancohen@xxxxxxxxx> writes:

>> I think --author and --grep uses the same internal pattern matching
>> engine, so with --invert-grep, I would not be surprised if the
>> command looks for commits that do not have Revert and (or is that
>> or?  I dunno) not authored by Shachar.
>
> Possibly, but the flag is called --invert-grep not --invert-matches so
> one would expect it to revert grep only.

That is an actionable improvement idea to introduce a synonym ;-)

But in general, the way the internal "git grep" machinery is exposed
to the commands in the "git log" family is very limited.  With "git
grep", it is quite straight-forward to say "report hits for lines
that has this but not that"

    $ git grep -e this --and --not -e that

but because that the commands in the "log" family already use
"--not" for a quite different purpose, "git log --grep" cannot even
express something similar, even to find hits on a single line, let
alone finding hits on two different lines (i.e. one on the "author"
header, the other in the message part, of the commit object).





[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux