Re: [PATCH] built-in "git grep" (git grip).

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

 



Junio C Hamano <junkio@xxxxxxx> writes:

> Linus Torvalds <torvalds@xxxxxxxx> writes:
>
>> On Tue, 2 May 2006, Junio C Hamano wrote:
>>> 
>>>  - The shell-script one, if you use GNU grep, accepts more
>>>    options to grep than what the current built-in one supports.
>>>    Notable ones that are missing: fixed strings (-F), patterns
>>>    from file (-f), count matches (-c), omit filenames (-h),
>>>    skipping binary files (-I, -U), files without match (-L),
>>>    pcre (-P), silent (-q), word expression (-w), NUL (-z).  They
>>>    should be easy to add if somebody cares enough, and I plan to
>>>    do a few myself before pushing it out to "master".
>>
>> I use "-w" all the time, along with -5 or similar to get context for the 
>> grep.
>
> Noted; -w is missing; -A/-B/-C are already there so you could
> say -C 5 instead, and -<n> should be easy to add.

I did both -<n> and -w, and pushed it out in "next".

What we have:

        -<n>, -[ABC] <n> (and -[ABC]<n>)
        -E
        -G
        -H (but it is an no-op -- we always show name)
        -c
        -e (you can do multiple patterns now)
        -i
        -n
        -v
        -w
	-l

What are still missing:

        -I (easy)
        -L (probably a bit intrusive)
        -P (code is easy -- deciding dependency on pcre is OK is harder)
        -U (probably not so easy but may be useful)
        -Z (probably easy but is it useful?)
        -q (may not be worth doing)
        -z (easy but pointless)
	-F (dunno)
	-f (with the enhancement to do multiple -e, trivial to add this)


-
: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[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]