print lines matching a pattern
|
-f FILE, --file=FILE
Obtain patterns from FILE, one per line. The empty file contains zero patterns, and therefore
matches nothing. (-f is specified by POSIX.)
|
-B NUM, --before-context=NUM
Print NUM lines of leading context before matching lines. Places a line containing a group
separator (--) between contiguous groups of matches. With the -o or --only-matching option, this
has no effect and a warning is given.
|
-v, --invert-match
Invert the sense of matching, to select non-matching lines. (-v is specified by POSIX.)
|
-l, --files-with-matches
Suppress normal output; instead print the name of each input file from which output would normally
have been printed. The scanning will stop on the first match. (-l is specified by POSIX.)
|