Configuration
Directory Structure
~/.claude/
├── CLAUDE.md # Global instructions (loaded every session)
├── settings.json # Permissions, hooks, allowed tools
├── settings.local.json # Machine-specific overrides
├── commands/ # Slash commands (symlink -> vault)
├── agents/ # Agent definitions (symlink -> vault)
├── hooks/ # Pre/post tool hooks (symlink -> vault)
├── scripts/ # Utility scripts (symlink -> vault)
├── skills/ # Multi-step skill packs (symlink -> vault)
├── cache/ # Performance cache
├── projects/ # Per-project settings & history
└── todos/ # Task listsHow CLAUDE.md Works
~/.claude/CLAUDE.md is loaded into every Claude Code session as system instructions. It defines:
- Interaction style (direct, structured, no fluff)
- Autonomous task protocols (validation loops, completion criteria)
- Git sync rules (when to commit/push)
- Handoff protocols (what to tell the human when automation ends)
Each project can also have its own CLAUDE.md at the project root for project-specific instructions.
Settings Overview
settings.json controls:
| Setting | Purpose |
|---|---|
allowedTools | Which tools Claude can use without asking (Bash, Edit, Write, etc.) |
hooks | Scripts that run before/after tool use (context injection, validation) |
mcpServers | MCP (Model Context Protocol) server connections |
settings.local.json controls:
- Machine-specific bash patterns to allow
- Bypass mode for trusted environments
Hooks System
Hooks are scripts that execute automatically at specific points:
| Hook | Trigger | Purpose |
|---|---|---|
| SessionStart | Every new session | Load context, display status |
| PostToolUse (Edit/Write) | After file edits | Validate changes, run checks |
| PreCompletionCheck | Before marking task done | Ensure validation passed |
Last updated on