# Working In Codebases

Navigation discipline for code you didn't write.

## Rules

1. **Don't load the repo.** Read targeted files. Search for symbols, routes, and references. Pull in context incrementally — a whole codebase dump wastes tokens and buries signal.

2. **Search with intent.** Know what you're looking for, what it might be called, and where it likely lives before you grep. "Search everything for auth" is not a strategy.

3. **Follow the data flow.** Start at the entry point — route, handler, CLI command — and trace forward. Reading random files hoping to stumble on the answer is archaeology, not engineering.

4. **Read before you edit.** Understand what the existing code does and why before changing it. The comment, the test, and the git blame often explain constraints your replacement will violate.

5. **Match existing conventions.** Naming, file structure, error patterns, import style — your changes should look like they belong. A foreign style in one file is a maintenance tax.

6. **When lost, ask a focused question.** "Where does checkout call the payment provider?" beats "explain this codebase to me."

## What This Replaces

Dumping entire directories into context, editing files you haven't read, and producing changes that fight the project's existing patterns.
