PTENES
MODULE 0.2

⌨️ Installation on Windows/Mac/Linux, no fear of the terminal

The terminal doesn’t bite. Step-by-step installation on all three systems and the four commands you need to know before moving on.

6
Topics
35
Minutes
Beginner
Level
Practice
Type
0 of 60%
1

⬛ What is a terminal

New here? One terminal is just a text box for giving direct commands to the computer — without clicking any icons. You type a command (a text instruction, like a short sentence the computer understands), press Enter, and the computer executes it right away. It’s the same idea as a calculator: you type, press “=”, and get the result. There’s no mystery or “movie hacker” stuff — it’s just another way to talk to the machine, using text instead of clicks.

Every module from here on will ask you to open the terminal and paste a command. If you’ve never opened one before, the most common fear is “I’m going to break something.” In practice, the commands this course uses (install, enter a folder, list files, open the agent) don’t delete anything or change system settings — they’re limited to the folder you’re working in.

You type "claude" + Enter Terminal passes it to the system Result on the screen the cycle repeats with each command: type → Enter → response

Each command is a short, self-contained cycle: nothing stays “pending” — either the terminal responds right away or shows an error message explaining what’s missing.

💡 Main Concept

  • •On Windows: the “Terminal” or “PowerShell” app.
  • •On Mac: the “Terminal” app, already installed.
  • •On Linux: usually a desktop shortcut or “Ctrl+Alt+T”.

😰 Common error: “I accidentally closed the terminal”

Closing the terminal window doesn't break anything—it just disappears. Open it again (same icon, same app) and navigate back to the folder with cd (topic 4). No work saved to a file is lost; only the “conversation” from that window’s session.

2

🪟 Install on Windows (via WSL)

New here? WSL (Windows Subsystem for Linux) is an official Microsoft "Linux inside Windows" — it avoids 90% of the compatibility problems that come up when trying to install terminal tools directly on standard Windows. And install here simply means "installing a program on the computer" — the same as downloading and setting up any app, only through the command line instead of a clickable installer.

Run as Administrator means opening PowerShell with elevated permissions—right-click the icon and choose “Run as administrator.” Without that, Windows blocks the installation for security reasons (the same reason your phone asks for a password before installing an app outside the official store).

# In PowerShell as Administrator, paste and press Enter:
wsl --install

Objective: install WSL. How to verify: restart the computer; when it turns back on, an Ubuntu window should open automatically asking for a new username/password (these are local to this environment only).

1

Open PowerShell as Administrator.

2

Paste wsl --install and press Enter.

3

Restart the computer when asked.

4

Create an Ubuntu username/password in the window that opens automatically.

😰 Common error: “wsl is not recognized”

Appears in older versions of Windows 10 (before the May 2020 update). Go to Settings → Windows Update → Check for updates, update the system, and try again. If the command asks you to enable “Virtual Machine Platform” manually, follow the link shown in the error—it opens a Windows settings page, not something from the course.

✓ Do

  • ✓Run PowerShell as Administrator
  • ✓Restart when asked

✗ Avoid

  • ✗Install in a regular Command Prompt (without Admin)
  • ✗Ignore the restart request
3

🍎 Install on Mac and Linux, right from the Terminal

On Mac and Linux, there’s no extra layer: open the Terminal app and paste the official Claude Code installation command (available in Anthropic’s documentation).

New here? This command has two parts connected by a pipe (the symbol |): the first (curl -fsSL <endereço>) downloads a small script (a text file with instructions) directly from Anthropic’s official site; the second (sh) runs this script right away. It’s the same idea as downloading an installer and double-clicking it — just without going through Finder/File Explorer.

# Paste into the Terminal (Mac or Linux) and press Enter:
curl -fsSL https://claude.ai/install.sh | sh

Objective: download and install Claude Code. How to verify: the terminal should display “installed successfully” (or an equivalent message) at the end, with no red errors.

🔍 Inside

The installer puts the program in a folder just for your user account (it doesn’t touch system folders) and downloads only a few megabytes—it doesn’t need significant disk space. In this specific step, no data of yours is sent over the internet beyond the download itself; the installation is free, though using the agent later may cost something (usage credits, depending on your plan).

✓ Do

  • ✓Copy the entire command without breaking it across lines
  • ✓Paste with Cmd+V (Mac) or Ctrl+Shift+V (Linux)

✗ Avoid

  • ✗Typing the command manually (easy to mistype one character)
  • ✗Copy from sources other than the official documentation

😰 Common error: “permission denied” or Mac lock screen

On Linux, “permission denied” almost always means you don’t have permission to access a protected folder — it rarely happens with this specific command, but if it does, check that you typed the command exactly as shown here. On Mac, Gatekeeper (the default security protection) may ask you for extra confirmation in “System Settings → Privacy & Security” the first time — that’s expected; just allow it.

💡 Practical Tip

If you’re asked for your Mac/Linux user password, that’s normal—it’s the same password you use to unlock your computer. When you type it, the terminal won’t show any characters on screen (not even dots). It may look stuck, but it’s recording your input normally; just type the password and press Enter.

4

📂 The four commands you need to know

You don’t have to memorize dozens of commands — just four things handle 90% of your day-to-day work in the terminal. New here? One folder (or “directory”) in the terminal is the same folder you already know from File Explorer/Finder—except instead of double-clicking to open it, you type its name after cd.

💻 your computer 📁 Documents ls shows this 📁 my-first-project cd meu-primeiro-projeto comes in here 📁 Downloads another folder cd .. always takes you back to the larger box outside
1

cd nome-da-pasta

Enters a folder (“change directory”). cd .. go back one folder.

2

ls (Mac/Linux) or dir (Windows)

List what’s in the current folder.

3

Enter

Confirm the command you typed—nothing happens until you press Enter.

4

claude

Open Claude Code in the current folder—the command you’ll use throughout the course.

💡 Practical Tip

You don’t need to type the whole folder name: start typing the first few letters and press Tab — the terminal completes it for you (this is called "autocomplete"). It works on Windows, Mac, and Linux and prevents typos, especially in long names or names with accents.

😰 Common error: “No such file or directory”

It means the folder you typed doesn't exist where you are — usually the name has a typo, or the folder is one level above or below where expected. Run ls (or dir on Windows) first to see the exact names, and use Tab to avoid errors. Names with spaces need quotation marks: cd "minha pasta".

5

✅ Verify that the installation worked

Before moving on, confirm that everything is set up correctly. A version command returns a number—a green light.

New here? The flag --version (two hyphens before the word) is a standard request that almost every terminal program understands: "tell me which version of you is installed, without doing anything else." It's a safe way to test whether the installation worked without running the actual program.

# In the terminal, paste and press Enter:
claude --version

Objective: confirm that the program was installed. How to verify: you should see something like 1.x.x — a version number, not a "command not found" error message.

✓ Sign that it worked

  • ✓A version number appears (e.g., 1.4.2)
  • ✓There’s no red text in the response

✗ Sign that something failed

  • ✗"command not found" / "command not found"
  • ✗The window freezes without a response for more than 1 minute

⚠️ Attention

If “command not found” appears, close and reopen the terminal (sometimes it needs to reload the configuration, called PATH — the list of places the terminal searches for installed programs) before suspecting something more serious. If it persists after reopening, repeat the installation command from topic 2 or 3—installing over the existing version won’t cause any problems.

6

🚀 Your first conversation with the agent

It’s time for the course’s “hello world”: create a test folder, go into it, and send your first message. New here? mkdir means “make directory” — creates a new empty folder. Using a separate test folder (instead of working directly with important files) is the safest way to experiment with no risk at all this first time.

# Create and enter a test folder:
mkdir <meu-primeiro-projeto>
cd <meu-primeiro-projeto>
# Open the agent:
claude

Objective: open your first session. How to verify: a Claude Code welcome screen appears with a cursor waiting for you to type. Write “hi, what can you do?” and press Enter.

🔍 Inside

Each time you run claude in a folder, a new one starts session — the agent "forgets" previous conversations, but can still see the files in that folder (covered in modules 0.3 and 0.4). The only thing sent to the internet in that first message is the text you typed (and, when requested, the contents of the files in that folder) — nothing else from your computer is sent. And the installation isn't what costs money: usage does, billed according to your account plan.

😰 Common error: “I typed before the screen loaded”

If you type too quickly, before the welcome screen finishes appearing, the text may get lost or appear choppy. Wait for the cursor to blink on its own before you start typing—it takes only 1 or 2 seconds after the command claude.

💡 Practical Tip

To exit a session at any time, type /exit or press Ctrl+C twice in a row. Neither one deletes the folder or files — it only ends the conversation with the agent.

✅ Module Summary

✓
Terminal: a text box that gives direct commands to the computer.
✓
Installation: WSL on Windows, directly in Terminal on Mac/Linux.
✓
4 commands: cd, ls/dir, Enter, claude — cover the essentials.
✓
Check: claude --version confirms it worked before you continue.

Next module:

0.3 — Anatomy of a project