Skills › 💻 Terminal & git

Make nested folders in one go with mkdir -p

mkdir a/b/c fails if a doesn't exist yet. Add -p and it builds the whole path, no errors.

⏱ 15s

  1. Type mkdir -p and the full path you want, like mkdir -p notes/2026/march.
  2. Press Enter: every missing parent folder is created on the way.
  3. Run it again: -p doesn't complain if the folders already exist.
  4. Add -v to print each folder as it's made.

Tip: Combine it with braces to make sibling folders at once: mkdir -p site/{css,js,img}.

Try it now: Run mkdir -pv /tmp/crumbs/a/b/c and watch it make all four folders.

Practice in the feed →

Next crumbs

Sources