Linux & Shell · Command
grep
grep prints input lines that match one or more patterns. It can search files, standard input, or directory trees.
Last updated
Syntax
grep [OPTION]... PATTERNS [FILE]...
grep [OPTION]... -e PATTERNS ... [FILE]...
grep [OPTION]... -f PATTERN_FILE ... [FILE]...In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
regex(7)pcre2pattern(3)findsort -zxargs -0