Claude Code Subagents Tutorial: Build a Read-Only Code Reviewer
Anthropic's code-reviewer subagent has Read, Grep, Glob and Bash, and Bash can still write files. Build a Claude Code reviewer that's truly read-only.
Tested, copy-paste configs for AI coding agents: hooks, subagents, skills, slash commands, MCP servers, CLAUDE.md and Cursor rules.
Anthropic's code-reviewer subagent has Read, Grep, Glob and Bash, and Bash can still write files. Build a Claude Code reviewer that's truly read-only.
A 322-line CLAUDE.md cut to 24 lines: what loads, what to cut, where rare rules go, model routing with subagents, and one AGENTS.md for every agent.
Seven Claude Code guardrails with real scripts: hooks that block rm -rf and .env edits, deny/ask/allow rules, ${VAR} secrets, a clone audit and a Stop hook.
Run Claude Code, Cursor and Codex on one repo? Keep skills, MCP servers and AGENTS.md in one place with one symlink and a short sync script.
A planted AGENTS.md or repo hook can hijack your coding agent. The files that run code in Claude Code, Cursor and Codex, plus a 2-minute pre-open check.
Copy-paste CLAUDE.md, AGENTS.md and Cursor .mdc rules that make coding agents ask first, plan, keep diffs small, leave unrelated files alone and verify.
Claude Code ignoring your CLAUDE.md? Check it loads, put hard rules first, then enforce them with settings.json deny rules and hooks instead of hoping.
Hitting Claude Code usage limits? Seven fixes: a Haiku subagent for small tasks, /compact and /clear, a lean CLAUDE.md, fewer MCP servers and plan-first work.
Copy-paste CLAUDE.md templates for Unity and Godot projects, plus the rules that stop Claude Code breaking .meta files, scenes and caches.
A copy-paste AGENTS.md template that Claude Code, Codex and Cursor all read, plus a HANDOFF.md pattern for switching tools and surviving compaction.
How Claude Code skills work: where SKILL.md lives, the frontmatter fields that matter, skills vs subagents, and 5 copy-paste skills you can use today.
Create Claude Code custom slash commands in .claude/commands/: frontmatter, $ARGUMENTS, shell injection and 7 copy-paste commands for commits and PRs.
Add MCP servers to Claude Code with claude mcp add or .mcp.json: scopes, HTTP vs stdio, env-var secrets, permissions and 5 ready configs.
Six working Claude Code hooks for settings.json: block rm -rf, protect .env, auto-format, run tests before stop, desktop notifications and session context.
How to create Claude Code subagents in .claude/agents/: frontmatter fields, tool scoping and 4 working examples: planner, reviewer, tester, debugger.
A free copy-paste CLAUDE.md template for Claude Code, plus 7 rules for project memory Claude actually follows.
How Cursor project rules work (.cursor/rules/*.mdc with description, globs and alwaysApply) plus 5 copy-paste rules for safety, TypeScript and Next.js.