Claude Code

Configure it once per repository, then judge it on the diffs it produces.

2guides Feed

Claude Code is a terminal agent that reads and edits files, runs shell commands and iterates against your own tests. It attaches to a repository as it is — there is no index to build and no layout it expects.

Three files do the configuration. CLAUDE.md at the repository root describes how the project actually builds and is loaded into every session. .claude/settings.json holds permission rules and hooks and is committed. .claude/settings.local.json holds personal overrides and is not.

Reach for it when a task is specifiable and mechanically verifiable, and when you can run the whole test suite in under a couple of minutes. That feedback loop is what makes the difference between output you can trust and output you have to trace by hand.

What goes wrong is nearly always configuration. A CLAUDE.md that describes what a project usually looks like rather than what yours does sends the agent after commands that do not exist. Permission rules that are absent produce approval fatigue, which produces overly broad rules a week later. And a session that has been running for two hours has accumulated context you cannot audit, which shows up as later edits being worse than early ones.

The version detail matters here more than with most tools: settings keys and hook schemas have changed between major releases. Check claude --version before copying configuration from anywhere, including from here, and treat a rejected key as a documentation question rather than a syntax error.

Start here

How to Use Claude Code on an Existing TypeScript Project

Add Claude Code to a TypeScript repo you already have: a CLAUDE.md that matches your real build, permission rules that block dangerous commands, and a typecheck loop the agent runs itself.

Intermediate · 5 min read

Beginner to advanced

A reading order that builds Claude Code knowledge in the sequence it is actually needed.

  1. Start How to Use Claude Code on an Existing TypeScript Project 5 min
  2. Build An AI Coding Agent Workflow That Keeps Diffs Reviewable 5 min

Common problems

Failure modes that come up repeatedly with Claude Code, and where each one is solved.

Every command stops for approval
No allow rules match. Pre-approve the narrow set you want running unattended using prefix rules, and deny the rest explicitly.
CLAUDE.md is ignored halfway through
The file is too long. Keep it under roughly 200 lines of factual, copy-pasteable commands and let the agent discover the rest on demand.
The agent remembers a decision you already reverted
Compaction kept a lossy summary of the previous task. Clear the session between unrelated tasks instead of compacting.

Latest Claude Code guides

Browse the archive

Recently updated

Frequently asked questions

Where do Claude Code settings live?

Project settings in `.claude/settings.json`, committed to git. Personal overrides in `.claude/settings.local.json`, which should be gitignored. Memory and conventions go in `CLAUDE.md` at the repository root.

Should CLAUDE.md be committed?

Yes. It is shared project knowledge and belongs next to the code it describes, reviewed like any other file. A widened permission allow list in the same directory is a security change and deserves the same scrutiny.

Does it work in a monorepo?

Yes. It reads the instructions file in the current working directory and walks up toward the repository root, so a short root file plus a per-package file gives you shared conventions and local specifics.

Sources

  1. Claude Code overview Anthropic Primary source
  2. Claude Code settings Anthropic Primary source
  3. Claude Code hooks Anthropic Primary source