diff options
author | Junio C Hamano <junkio@cox.net> | 2006-09-20 12:39:46 -0700 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-09-20 12:39:46 -0700 |
commit | 480c1ca6fd8df58a783e231648b489ed2bfd17f1 (patch) | |
tree | 01627f1db5e68b2472da416e3acf512fc0084567 /grep.h | |
parent | a2ed6ae402582a3ee76e9b4639848eba261a12de (diff) | |
download | git-480c1ca6fd8df58a783e231648b489ed2bfd17f1.tar.gz |
Update grep internal for grepping only in head/body
This further updates the built-in grep engine so that we can say
something like "this pattern should match only in head". This
can be used to simplify grepping in the log messages.
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'grep.h')
-rw-r--r-- | grep.h | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -3,6 +3,8 @@ enum grep_pat_token { GREP_PATTERN, + GREP_PATTERN_HEAD, + GREP_PATTERN_BODY, GREP_AND, GREP_OPEN_PAREN, GREP_CLOSE_PAREN, @@ -10,6 +12,11 @@ enum grep_pat_token { GREP_OR, }; +enum grep_context { + GREP_CONTEXT_HEAD, + GREP_CONTEXT_BODY, +}; + struct grep_pat { struct grep_pat *next; const char *origin; |