Skip to content

Searching with grep

Finding text with grep

  • grep searches for a word and prints only the lines that contain it:
grep error log.txt
  • Out of a huge log, you instantly see just the lines that matter.

grep filters lines: many go in, only those containing the word come out

Log in or create account

IGCSE & A-Level