Stage 3 of 8 · 8 lessons · ~2 weeks
Text tools
Search, filter and reshape text and files with the classic Unix tools and jq. Logs, config files, CSV exports and API responses all become things you can question from the terminal.
Start: Viewing files: cat, less, head and tailLessons· one lesson for each topic, in this order
Do this
- Follow a log live with `tail -f` while you trigger new lines.
- Search a real project with `grep -rn` for a function name and for TODOs.
- Find the five largest files under your home folder with find or du.
- Produce a top 10 list from a log with `sort | uniq -c | sort -rn | head`.
- Test three regular expressions on regex101 before using them with grep.
- Replace a value across a file with sed, first previewing, then in place with Git as a backup.
- Pull fields from an API response with curl and jq.
Start with· follow one of these
- CourseFreeThe Missing Semester of Your CS Education
MIT · Beginner
The data wrangling lecture walks through grep, sed, awk and regular expressions on real logs
- BookFreeThe Linux Command Line
William Shotts · Beginner
Clear chapters on text processing, regular expressions and searching for files
Practise
Keep handy
Before moving on: A text file of 10 real questions you answered from a real log, CSV or JSON file (top error messages, largest files, busiest hour, active users from an API), each with the one-liner you used.

Take real data you care about, such as your own shell history, a Git log or an export from a spreadsheet, and question it. These tools only stick when you use them for something. If a one-liner grows past two lines, that is fine; if it grows past five, write a script.