(view help text of RxGrep.cs as plain text)
RxGrep, Version 3.01
Multi-line FindStr/Grep like tool
Usage: RXGREP filename pattern [ options ]
or: command | RXGREP pattern [ options ]
Where: filename is the file to be filtered
command is the command whose standard output is to be filtered
pattern is the search pattern (regular expression)
Options: /A use tAb as separator for multiple groups
(default: space)
/D do not show Duplicate matches
/F:nn search only the First nn bytes
/G:nn return match Group #nn
/I case Insensitive search
/L single Line mode: ^ and $ match begin and end of each line
/Q Quiet mode: no message if no match is found
/S:nn Skip the first nn matches
/T:nn Take only nn matches
Example: ROBOCOPY D:\sourcedir E:\targetdir /NP /MIR |
RXGREP "\s+\d+\s+D:\\sourcedir\\[^\n\r]*\r\n([^\n\r\\]+\r\n)+"
(to be read as a single command line) will return something like:
125 D:\sourcedir\subdir\
New File 342 brandnewfile.ext
Newer 4.06m updatedfile.ext
*EXTRA File 2.40m deletedfile.ext
Notes: If /F:nn is used and a file is specified, only the first nn bytes
of that file will be read; if the input is redirected, it is read
entirely, and then chopped to nn bytes before being searched.
/G:nn can be used multiple times; all matching groups are written
to screen, separated by spaces, unless /A is used, in which case
the matches will be separated by tabs; matching groups are shown
in order of input, not in order of command line arguments, e.g.
/G:1 /G:3 will show the same result as /G:3 /G:1.
Switches /D and /G cannot be combined with /S or /T.
Return code ("errorlevel") will equal the number of matches found,
or -1 in case of (command line) errors.
Written by Rob van der Woude
https://www.robvanderwoude.com
page last uploaded: 2025-10-23; loaded in 0.0068 seconds