You can use the grep -o
option, possibly in combination with changing the pattern to ".{0,10}<original pattern>.{0,10}"
to see some context around it:
-o, --only-matching
Show only the part of a matching line that matches PATTERN.
.. or -c
:
-c, --count
Suppress normal output; instead print a count of matching lines
for each input file. With the -v, --invert-match option (see
below), count non-matching lines.
Ether Jan 9 '10 at 20:21 2010-01-09 20:21
source share