Paths/Claude Engineer/Claude Code Essentials / Settings & Permissions
Write the Settings File
The settings file decides the model, the tools and the rules for every session. Write one for a project that builds with pnpm.
Validator
IDLE — checks run live as you type commands; submit when done
01Requirements
live checks- Directory ~/.claude exists○
- File ~/.claude/settings.json exists○
- The settings name the model○
- The settings list allowed and denied commands○
02Walkthrough
4 steps- 01
Create the claude directory
The user settings live in your home directory, so every project inherits them.
mkdir -p ~/.claude - 02
Write the settings
model picks the engine, permissions decides what runs without a prompt. The allow list is short on purpose.
echo '{\n "model": "claude-sonnet-4",\n "permissions": {\n "allow": ["Bash(pnpm test:*)", "Bash(pnpm build:*)", "Read", "Edit"],\n "deny": ["Bash(rm -rf:*)", "Bash(git push:*)", "Read(./.env)"]\n }\n}' > ~/.claude/settings.json - 03
Verify the settings
cat prints the file. Every allowed command is a command you no longer approve one by one.
cat ~/.claude/settings.json - 04
Submit for validation
The validator checks the model and both permission lists.
03Stuck?
0 of 3 revealedTake a hint without losing the lab — each one points at the thing to look at, not at the answer.
04AI Tutor
guides, never solvesTell me what you're stuck on — I'll nudge, not solve. Which requirement are you looking at?
04Notebook
saved locally in this browserlearner@lab — ubuntu:24.04
Session is disposable
↑/↓ recalls commands · Ctrl+Enter submits · type help for the command list