Precedes each line by the block number on which it was found. This is sometimes useful in locating disk block numbers by context.
–c
Displays a count of matching lines rather than displaying the lines that match.
–h
Does not display filenames.
–i
Ignores the case of letters in comparisons (i.e., upper- and lowercase are considered identical).
–l
Lists only the names of files with matching lines (once), separated by newline characters.
–n
Precedes each line by its relative line number in the file.
–s
Works silently, that is, displays nothing except error messages. This is useful for checking the exit status.
–v
Inverts the search to display only lines that do not match.
–w
Searches for the expression as a word, as if surrounded by \< and \>. This applies to grep only. (Not all versions of grep support this feature; e.g., SCO UNIX does not.)
Table 4.2. grep's OptionsOptionWhat It Does–bPrecedes each line by the block number on which it was found. This is sometimes useful in locating disk block numbers b