Notes I wrote while I was learning the terminal, turned into a course.
There are three reasons it exists. The first is to remind myself later, because I forget things, and a page in my own words brings it back faster than a search does. The second is that I wrote every line of it by hand while learning it. None of it is AI generated. The third is that once it was written well enough for me to come back to, it was already good enough for someone else to start from.
So if something confused me, it gets its own explanation here instead of one line saying “this is obvious”.
Total time: about 11 hours 15 min, split over 9 chapters.
The chapters
| # | chapter | time | what u learn |
|---|---|---|---|
| 1 | Command Line Basics | ~45 min | echo, CLI vs GUI, terminal / emulator / shell, variables, quotes, the Tab key |
| 2 | The Linux File System | ~45 min | what the real tree is: /etc /var /usr /tmp /home and the rest |
| 3 | Files and Navigation | ~90 min | cd ls pwd mkdir touch rm cp mv cat less head tail, the * wildcard, man |
| 4 | Searching: grep and find | ~60 min | grep and its flags, find and its patterns |
| 5 | Permissions and sudo | ~75 min | root, sudo, reading -rw-r--r--, chmod, chown |
| 6 | Text Editors | ~60 min | nano, and vim with the modes idea behind it |
| 7 | Scripts, Env and PATH | ~75 min | compiled vs interpreted, shebang, export, .bashrc, aliases, PATH |
| 8 | Input, Output and Processes | ~105 min | exit codes, > >> 2>, the | pipe, &&, background jobs, ps kill top |
| 9 | Bash Scripting Basics | ~120 min | arguments, if, loops, read, functions, and a real 25 line script |
And when u forget something later: the cheat sheet, every command in the course on one page.
Why this order
The chapters build on each other, and a few of them sit where they are on purpose:
- The editors come before the scripting chapters (6 before 7 and 9),
because u cannot write a 30 line script with
echoand>>. U neednanoorvimfirst. - Permissions come before scripts (5 before 7), because the first thing
that happens when u run ur own script is
Permission denied, and u should already know why. - Pipes and exit codes come before bash scripting (8 before 9), because
if [ $? -eq 0 ]is meaningless until u know what$?is.
How the chapters are organized
Every chapter has the same 3 parts, always in this order:
- The lecture. The actual topics, numbered, each one with the command and its real output.
- NOTES. Small things that are useful to know but are not a topic on their own. Sometimes they relate to the chapter and sometimes they do not, they are just things u should know by that point.
- The assignment. Tasks built only from what u learned in that chapter.
The answers are in a
solutions.mdnext to it, so u only see them when u decide to open them.
How to study this
- Do them in order. Chapter 9 uses things from chapter 8, and chapter 8 uses things from chapter 3. Skipping will not work.
- Type the commands, do not read them. It looks easy when u read it, and then it is gone in two days. Open a terminal next to the page and run every single block.
- Make a
practicefolder somewhere and do everything inside it, so u never break something u care about. - Do the assignment before u open the solution. If u open it first, u are only reading again.
- Forgetting a command later is normal and expected. That is what
manand the cheat sheet are for. U are learning where to look, not memorising a list. - The times assume u are actually typing everything and doing the assignment, not reading. One chapter a day is a good pace, so this is about two weeks.
References
- The video I used as the main reference: Boot.dev, Learn the Terminal
man <command>for everything else. It is already on ur machine.
The video
Watch it here, about 24 minutes. If u want the player with the cheat sheet open beside it instead, that page is on the dev-101 site.
Watch it after the chapters, or alongside them. It is a summary and not a replacement: it shows u what happens, and these chapters are where the why is. Every command in it was run on a real machine, and the output u see is what actually came back.
It ends on a two page cheat sheet, and that sheet is CHEATSHEET.md here if u want to copy from it.