legacy-code-protocol
Protocol for working in legacy code, meaning existing code with few or no tests, or code nobody understands. Modes - survey maps an unfamiliar area (structure, coupling, coverage, hotspots, seams); plan sequences the work into stacked PRs and tickets; pin locks current behavior with characterization tests; change makes one change safely through seams and test-first edits; replace swaps in a new implementation using characterization tests as the parity oracle; review audits a pull request that touches legacy code. Based on Michael Feathers' Working Effectively with Legacy Code. For new code, or code already covered by tests, use tdd.
Source facts
- Repository
- dgalarza/agent-skills
- Last source activity
- November 9, 2026 at 21:45
- Detected SKILL.md language
- English
- Stars
- 72
- Forks
- 10
Install options
The review-first prompt is selected by default. You can switch to a direct command or download a local copy.
Review the source files
Read SKILL.md and any companion files shown by SkillsMP before deciding whether to install.
Showing SKILL.md
| name | legacy-code-protocol |
|---|---|
| description | Protocol for working in legacy code, meaning existing code with few or no tests, or code nobody understands. Modes - survey maps an unfamiliar area (structure, coupling, coverage, hotspots, seams); plan sequences the work into stacked PRs and tickets; pin locks current behavior with characterization tests; change makes one change safely through seams and test-first edits; replace swaps in a new implementation using characterization tests as the parity oracle; review audits a pull request that touches legacy code. Based on Michael Feathers' Working Effectively with Legacy Code. For new code, or code already covered by tests, use tdd. |