The shell is a program that takes your typed commands and tells the computer to run them. It is that black window with text where developers look very busy. In reality, they are often just typing ls again and again.
Terminal, shell, bash — what is what?
These three get mixed up constantly:
- Terminal: the window itself.
- Shell: the program inside that reads your commands. The most common one is bash.
- Command: the actual instruction you type, like
lsorcd.
So you open a terminal, which runs a shell, in which you type commands. Three layers, one black box.
Why bother when there are nice icons?
Clicking is fine for one file. But the shell shines when you want to do something many times or exactly the same way every time:
# rename, move, or process hundreds of files in one line
mkdir backup && cp *.txt backup/
Doing that by hand with a mouse would take ages and you would surely miss one.
A few starter commands
pwd # where am I right now?
ls # what is in this folder?
cd dir # go into a folder
cd .. # go back one level
Master these four and you can move around comfortably. More in Handy terminal commands.
Do not be scared
The shell feels intimidating because it does exactly what you say, even if what you say is silly. So read before pressing enter, especially anything with rm (delete). Start slow, and soon the black window becomes the fastest tool you own.