Cheat sheet: moving around in Linux
Bookmark this. These are the commands you’ll use every single day.
| Command | What it does | Example |
|---|---|---|
pwd |
Print working directory: where am I? | pwd → /home/you |
ls |
List what’s in this folder | ls |
ls -la |
List everything, including hidden files, with details | ls -la |
cd folder |
Change into a folder | cd loopnotes |
cd .. |
Go up one folder | cd .. |
cd ~ or cd |
Go to your home folder | cd |
cd - |
Go back to the previous folder | cd - |
Keyboard shortcuts
Section titled “Keyboard shortcuts”| Keys | What they do |
|---|---|
| Tab | Complete a file or folder name |
| Tab Tab | Show all possible completions |
| ↑ / ↓ | Previous / next command from history |
| Ctrl+R | Search your command history |
| Ctrl+C | Stop the running command |
| Ctrl+L | Clear the screen |
Try it
Section titled “Try it”pwdlscd /tmppwdcd -