summaryrefslogtreecommitdiff
path: root/grep.h
diff options
context:
space:
mode:
authorRené Scharfe <rene.scharfe@lsrfire.ath.cx>2009-07-01 22:03:44 (GMT)
committerJunio C Hamano <gitster@pobox.com>2009-07-02 02:16:46 (GMT)
commit046802d015b3be2e055ae68f29f76741023bc32d (patch)
treed65f59ba86ab3ba0932b02d2ab835575c08a8f09 /grep.h
parent5dd06d38795b2f6d05f851b25c814732238f8df1 (diff)
downloadgit-046802d015b3be2e055ae68f29f76741023bc32d.zip
git-046802d015b3be2e055ae68f29f76741023bc32d.tar.gz
git-046802d015b3be2e055ae68f29f76741023bc32d.tar.bz2
grep: print context hunk marks between files
Print a hunk mark before matches from a new file are shown, in addition to the current behaviour of printing them if lines have been skipped. The result is easier to read, as (presumably unrelated) matches from different files are separated by a hunk mark. GNU grep does the same. Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'grep.h')
-rw-r--r--grep.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/grep.h b/grep.h
index 0883214..730ffd6 100644
--- a/grep.h
+++ b/grep.h
@@ -85,6 +85,7 @@ struct grep_opt {
unsigned pre_context;
unsigned post_context;
unsigned last_shown;
+ int show_hunk_mark;
};
extern void append_grep_pattern(struct grep_opt *opt, const char *pat, const char *origin, int no, enum grep_pat_token t);