summaryrefslogtreecommitdiffstats
path: root/share
diff options
context:
space:
mode:
authorAlejandro Colomar <alx.manpages@gmail.com>2022-05-11 20:46:01 +0200
committerAlejandro Colomar <alx.manpages@gmail.com>2022-05-11 21:24:44 +0200
commit439553e50dbc17c9ef29a50aaeae93bb9f6cbf81 (patch)
tree83685a6788d963b107d652c846046f7570252e97 /share
parentf417552f109cff273293be848b79813ee60110b4 (diff)
grepc, grepc.1: Add optional FILE trailing arguments
Reported-by: наб <nabijaczleweli@nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
Diffstat (limited to 'share')
-rw-r--r--share/man/man1/grepc.122
1 files changed, 20 insertions, 2 deletions
diff --git a/share/man/man1/grepc.1 b/share/man/man1/grepc.1
index 6caaeb5..b8403f9 100644
--- a/share/man/man1/grepc.1
+++ b/share/man/man1/grepc.1
@@ -5,15 +5,33 @@ grepc \- find C declarations and definitions in source code
.B grepc
.RI [ option " ...]"
.I identifier
+.RI [ file " ...]"
.SH DESCRIPTION
.MR grepc 1
-searches for all C declarations and definitions of
+searches for C declarations and definitions of
.I identifier
-in all .c and .h files under the current working directory.
+in each
+.IR file .
+.PP
.I identifier
is normally a C identifier,
but it is actually a PCRE pattern,
so it can be used to find complex patterns.
+.PP
+If
+.I file
+is a directory,
+the search is recursive within that directory.
+If
+.I file
+doesn't match a certain extension, it is skipped
+(see
+.B \-x
+in OPTIONS).
+If no
+.I file
+is given,
+the working directory is searched.
.SH OPTIONS
.TP
.B \-g