TrueThink

The Terminal Isn't Scary: A Quick Command Reference

The only 5 terminal commands you need to know

The terminal (Terminal) is that window with white text on a dark background. It might look like something out of a hacker movie the first time you see it, but really it's just another way to talk to your computer -- typing instead of clicking.

In Vibe Coding, you'll use the terminal to start projects, install dependencies, and run builds. The good news: you only need a handful of commands.

Opening the Terminal

Terminal window: command prompt and basic commands

  • Mac: Press Cmd + Space, type Terminal, hit Enter
  • Windows: Press Win + R, type cmd, hit Enter (we recommend installing Windows Terminal)
  • VS Code / Cursor: Press Ctrl + ` to open the built-in terminal

Once it's open, you'll see a blinking cursor waiting for your input.

In the terminal, you're always "standing" inside some folder. It's just like having a file manager open to a specific directory.

# See which directory you're currently in
pwd

# List files and folders in the current directory
ls

# Enter a folder
cd my-app

# Go back up one level
cd ..

# Jump to a specific path
cd ~/projects/my-app

cd is the command you'll use the most -- every time you open the terminal, the first thing you do is cd into your project directory.

Tip: Type the first few letters of a folder name and press Tab to autocomplete.

Package Managers: Installing and Running

Web projects use package managers to handle dependencies (third-party libraries). The common ones are npm, pnpm, and yarn -- their commands are mostly interchangeable.

Actionnpmpnpm
Install all dependenciesnpm installpnpm install
Start dev servernpm run devpnpm dev
Build for productionnpm run buildpnpm build
Add a new dependencynpm install axiospnpm add axios

The most common workflow:

# 1. Navigate to the project directory
cd my-app

# 2. Install dependencies (only needed the first time, or after package.json changes)
pnpm install

# 3. Start the dev server
pnpm dev

After running pnpm dev, the terminal will show a local address (usually http://localhost:3000). Open it in your browser to see your app.

Quick Reference for Common Tasks

What you want to doCommand
See what files are in the projectls
Navigate to the project directorycd my-app
Install dependenciespnpm install
Start the dev serverpnpm dev
Stop a running commandCtrl + C
Clear the terminal screenclear or Cmd + K
Create a new foldermkdir my-folder
Delete a filerm filename.txt

Ctrl + C is especially important -- when the dev server is running, you need to press Ctrl + C to stop it before you can enter other commands.

When Things Go Wrong

Terminal errors are part of daily life. No need to stress. Here's how to handle the common ones:

command not found -- The command isn't installed. For example, pnpm: command not found means you haven't installed pnpm yet.

EACCES: permission denied -- Insufficient permissions. On Mac/Linux, add sudo before the command (it'll ask for your password).

node_modules acting up -- The universal fix: delete and reinstall.

rm -rf node_modules .next
pnpm install

Can't make sense of the error message? Copy the entire error and paste it to AI, then ask "What does this error mean and how do I fix it?" This is one of the most practical techniques in Vibe Coding.

Next Up

  • Version Control -- Use Git to manage code changes and roll back to any previous version

On this page