grep/grep-2.21-man-fix-gs.patch
Jaroslav Škarvada 712f266053 New version
Resolves: rhbz#1167657
- De-fuzzified patches
- Dropped pcre-backported-fixes patch (not needed)
2014-11-25 11:09:35 +01:00

62 lines
1.7 KiB
Diff

diff --git a/doc/grep.in.1 b/doc/grep.in.1
index b6362ee..5a1e3ea 100644
--- a/doc/grep.in.1
+++ b/doc/grep.in.1
@@ -314,7 +314,7 @@ Print
.I NUM
lines of trailing context after matching lines.
Places a line containing a group separator
-.RB ( \-\^\- )
+.RB "(described under " \-\^\-group\-separator )
between contiguous groups of matches.
With the
.B \-o
@@ -327,7 +327,7 @@ Print
.I NUM
lines of leading context before matching lines.
Places a line containing a group separator
-.RB ( \-\^\- )
+.RB "(described under " \-\^\-group\-separator )
between contiguous groups of matches.
With the
.B \-o
@@ -340,13 +340,24 @@ Print
.I NUM
lines of output context.
Places a line containing a group separator
-.RB ( \-\^\- )
+.RB "(described under " \-\^\-group\-separator )
between contiguous groups of matches.
With the
.B \-o
or
.B \-\^\-only\-matching
option, this has no effect and a warning is given.
+.TP
+.BI \-\^\-group\-separator= SEP
+Use
+.I SEP
+as a group separator. By default
+.I SEP
+is double hyphen
+.RB ( \-\^\- ).
+.TP
+.B \-\^\-no\-group-separator
+Use empty string as a group separator.
.SS "File and Directory Selection"
.TP
.BR \-a ", " \-\^\-text
diff --git a/src/grep.c b/src/grep.c
index 8dbf86e..e3461a7 100644
--- a/src/grep.c
+++ b/src/grep.c
@@ -1781,6 +1781,8 @@ Context control:\n\
"));
printf (_("\
-NUM same as --context=NUM\n\
+ --group-separator=SEP use SEP as a group separator\n\
+ --no-group-separator use empty string as a group separator\n\
--color[=WHEN],\n\
--colour[=WHEN] use markers to highlight the matching strings;\n\
WHEN is 'always', 'never', or 'auto'\n\