Full-screen terminal applications like htop and vim don't just print text — they take over the entire screen, redraw parts of it selectively, and read your keystrokes one at a time. Here's the layer that makes that possible.
Re-running the last command with sudo, or fuzzy-searching back through everything you've typed today, both rely on the same underlying mechanism — a persisted, indexed log of your previous commands.
An unquoted variable works fine in testing, then silently breaks in production the first time it holds a value with a space in it. This is the single most common category of real-world shell scripting bug.
Pressing Tab and getting a sensible list of filenames, commands, or flags looks simple from the outside. Underneath, it's a programmable system matching the word you're typing against rules specific to the command you're running.
'Terminal' and 'shell' get used interchangeably constantly, but they're genuinely separate programs with separate jobs — one draws characters on screen and manages input, the other interprets commands.
That colorful prompt showing your git branch, exit code, and current directory isn't a separate program running alongside your shell — it's a string your shell re-evaluates before every single command.
Ctrl-Z, bg, fg, and the & at the end of a command all touch the same underlying mechanism — a shell feature that manages which processes can read your keyboard input at any given moment.
FreeBSD's default shells didn't evolve from the Bourne shell lineage Bash and Zsh belong to — they descend from an entirely separate design philosophy, one built to feel more like C than like a scripting language.
By the time a command you typed actually runs, the shell has already rewritten it — expanding variables, substituting command output, and turning wildcard patterns into real filenames. Here's the exact order that happens in.
They all accept most of the same basic commands, which is exactly what makes their real differences easy to miss until a script written for one breaks silently on another.