[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
grep branch, master, updated. v3.3-54-ga517df5
From: |
Paul Eggert |
Subject: |
grep branch, master, updated. v3.3-54-ga517df5 |
Date: |
Sun, 29 Dec 2019 21:58:27 -0500 (EST) |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "grep".
The branch, master has been updated
via a517df5bd51e68c1290ec596b87e8fbe7a381279 (commit)
from ba4202cce98d8bef3d91f0d6edf1aa0ae1d1704d (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit/grep.git/commit/?id=a517df5bd51e68c1290ec596b87e8fbe7a381279
commit a517df5bd51e68c1290ec596b87e8fbe7a381279
Author: Paul Eggert <address@hidden>
Date: Sun Dec 29 18:57:28 2019 -0800
doc: Add -- to more-complex example
Suggested by Stephane Chazelas (Bug#38792).
* doc/grep.in.1, doc/grep.texi: Add â--â to recently-added example.
diff --git a/doc/grep.in.1 b/doc/grep.in.1
index a382966..a91b2a6 100644
--- a/doc/grep.in.1
+++ b/doc/grep.in.1
@@ -1333,13 +1333,18 @@ The following example outputs the location and contents
of any line
containing \*(lqf\*(rq and ending in \*(lq.c\*(rq,
within all files in the current directory whose names
contain \*(lqg\*(rq and end in \*(lq.h\*(rq.
-The command also searches the empty file /dev/null,
-so that file names are displayed
+The
+.B \-n
+option outputs line numbers, the
+.B \-\-
+argument treats expansions of \*(lq*g*.h\*(rq starting with \*(lq\-\*(rq
+as file names not options,
+and the empty file /dev/null causes file names to be output
even if only one file name happens to be of the form \*(lq*g*.h\*(rq.
.PP
.in +2n
.EX
-$ \fBgrep\fP \-n 'f.*\e.c$' *g*.h /dev/null
+$ \fBgrep\fP \-n \-\- 'f.*\e.c$' *g*.h /dev/null
argmatch.h:1:/* definitions and prototypes for argmatch.c
.EE
.in
diff --git a/doc/grep.texi b/doc/grep.texi
index 873b53c..42832ab 100644
--- a/doc/grep.texi
+++ b/doc/grep.texi
@@ -1585,12 +1585,13 @@ showing the location and contents of any line
containing @samp{f} and ending in @samp{.c},
within all files in the current directory whose names
contain @samp{g} and end in @samp{.h}.
-The command also searches the empty file @file{/dev/null},
-so that file names are displayed
+The @option{-n} option outputs line numbers, the @option{--} argument
+treats any later arguments starting with @samp{-} as file names not
+options, and the empty file @file{/dev/null} causes file names to be output
even if only one file name happens to be of the form @samp{*g*.h}.
@example
-$ @kbd{grep -n 'f.*\.c$' *g*.h /dev/null}
+$ @kbd{grep -n -- 'f.*\.c$' *g*.h /dev/null}
argmatch.h:1:/* definitions and prototypes for argmatch.c
@end example
-----------------------------------------------------------------------
Summary of changes:
doc/grep.in.1 | 11 ++++++++---
doc/grep.texi | 7 ++++---
2 files changed, 12 insertions(+), 6 deletions(-)
hooks/post-receive
--
grep
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- grep branch, master, updated. v3.3-54-ga517df5,
Paul Eggert <=