refactor
Installation
SKILL.md
Refactor Skill
Goal
Improve code structure, readability, or maintainability while guaranteeing that all existing behavior is preserved. Tests are the safety net — if they fail after refactoring, the refactor was incorrect.
Steps
- Establish the safety net
- Run the full test suite:
[test command from AGENTS.md] - If tests fail before you start: STOP — fix the failing tests first (they're not a safe net)
- Record baseline: number of passing tests, coverage %
- Run the full test suite: