Skip to main content
Albero Academy

The Shell & Navigation

What the shell is, moving around the filesystem, and the everyday commands for files and folders.

Chapter 1Bash12 min readBeginner friendly
  • #Bash
  • #Shell
  • #Basics

The shell is a text interface to your computer — you type commands, it runs them. Bash is the most common one on Linux and macOS, and it's the language of servers, deployment, data pipelines and cloud tools (see the AWS course). Learning it makes you dramatically faster at tasks that are slow or impossible by clicking.

What is the shell?

When you open a terminal you get a prompt waiting for input. You type a command, press Enter, and the shell runs a program and shows its output. That's the whole loop — but composed together, simple commands become powerful.

The filesystem is a tree of folders. Three commands let you move around it:

moving around
pwd # print working directory — where am I?
ls # list files here
ls -la # long format, including hidden files
cd projects # change into the projects folder
cd .. # up one level
cd ~ # home directory
cd - # back to the previous directory

Files & folders

creating & managing
mkdir reports # make a directory
mkdir -p a/b/c # make nested directories
touch notes.txt # create an empty file
cp notes.txt copy.txt # copy
mv copy.txt final.txt # move / rename
rm final.txt # remove a file
rm -r old_folder # remove a folder and its contents
cat notes.txt # print a file's contents

Getting help

Every command documents itself. Use man ls for the full manual, or ls --help for a quick summary of options. You'll never memorise every flag — you look them up.

Practice

From your home directory, create a folder albero/notes with mkdir -p, cd into it, create a couple of files with touch, list them with ls -la, rename one, and delete another. Use Tab completion throughout.

Key takeaways

  1. 01The shell is a text interface: type a command, it runs a program and shows output.
  2. 02Navigate with pwd (where), ls (list) and cd (change directory).
  3. 03Manage files with mkdir, touch, cp, mv, rm and cat.
  4. 04rm deletes permanently — there is no undo; verify before rm -r.
  5. 05Use Tab completion, the up arrow, and man / --help to work fast and self-serve.