author | Linus Torvalds <torvalds@osdl.org> | |
Wed, 17 May 2006 18:12:22 +0000 (11:12 -0700) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Wed, 17 May 2006 22:51:38 +0000 (15:51 -0700) | ||
commit | bbb66c60613fe89c58d7c97a92e067add7056f4d | |
tree | defbdda7c8555731789970d969265587d499c734 | tree | snapshot |
parent | e9ce27543d29aa23bb4740a241339c6d42674f7d | commit | diff |
builtin-grep: workaround for non GNU grep.
Of course, it still ignores the fact that not all grep's support some of
the flags like -F/-L/-A/-C etc, but for those cases, the external grep
itself will happily just say "unrecognized option -F" or similar.
So with this change, "git grep" should handle all the flags the native
grep handles, which is really quite fine. We don't _need_ to expose
anything more, and if you do want our extensions, you can get them with
"--uncached" and an up-to-date index.
No configuration necessary, and we automatically take advantage of any
native grep we have, if possible.
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Of course, it still ignores the fact that not all grep's support some of
the flags like -F/-L/-A/-C etc, but for those cases, the external grep
itself will happily just say "unrecognized option -F" or similar.
So with this change, "git grep" should handle all the flags the native
grep handles, which is really quite fine. We don't _need_ to expose
anything more, and if you do want our extensions, you can get them with
"--uncached" and an up-to-date index.
No configuration necessary, and we automatically take advantage of any
native grep we have, if possible.
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
builtin-grep.c | diff | blob | history |