tools/your-first-terminal-commands-pwd-ls-cd-and-friends-with-no-fear.md

Your first terminal commands: pwd, ls, cd and friends, with no fear

Tools · 9 min read ·

The terminal is a window where you type commands instead of clicking, and about a dozen of them cover most of what you'll do every day: pwd, ls and cd to find your way around, mkdir, touch, cp, mv and rm to manage files, cat and echo to read and write them.

This guide explains what a path is (absolute vs relative, plus the shortcuts . .. and ~), why rm has no undo, and how Tab completion saves you from typos. Then you practise everything in a safe in-page terminal with a guided quest.

$ ls tools/

see all →
tools/regular-expressions-describe-the-shape-of-text-and-watch-a-pattern-fin.md Regular expressions: describe the shape of text and watch a pattern find it A regular expression describes the shape of text instead of spelling it out, so one short pattern can find every phone number or check that… 4 min read · 14 Nov tools/file-permissions-what-rwxr-xr-x-means-and-why-a-script-says-permission.md File permissions: what rwxr-xr-x means, and why a script says Permission denied You run your first script and the terminal says Permission denied. Nothing is wrong with your code: every file and folder carries read… 6 min read · 2 Nov tools/git-stash-how-to-set-half-done-work-aside-without-committing-it.md Git stash: how to set half-done work aside without committing it You are halfway through a change when you need to switch branches, but the work isn't ready to commit. Git stash puts your unfinished edits… 4 min read · 30 Oct tools/gitignore-how-git-decides-which-files-to-skip-and-the-one-rule-that-su.md Gitignore: how Git decides which files to skip, and the one rule that surprises everyone Why does a file show up in git status when you wanted it hidden, and why does a file you ignored sometimes stay tracked anyway? Five short… 5 min read · 27 Oct tools/pipes-how-the-in-a-terminal-turns-small-commands-into-one-big-answer.md Pipes: how the | in a terminal turns small commands into one big answer How do you find the most popular page in a file of 15 million visits? In a terminal, you join small programs with the vertical bar `|`… 5 min read · 23 Oct tools/git-branches-why-making-one-doesn-t-copy-your-project.md Git branches: why making one doesn't copy your project When someone says "make a branch for that," it sounds like Git must copy your whole project. It doesn't. A branch is just a name stuck on… 4 min read · 20 Oct