← ClaudeAtlas

team-refactorlisted

Use when code needs refactoring, cleanup, or a design-quality review — god functions, tangled responsibilities, duplication, over-engineering, legacy code without tests, or code that resists the next change. Also when the user invokes Uncle Bob, Fowler, Beck, SOLID, KISS, YAGNI or clean code on existing code. Panel of refactoring masters with a KISS/YAGNI gate and a human approval gate.
TokiDEV/team-skills · ★ 4 · Code & Development · score 77
Install: claude install-skill TokiDEV/team-skills
# team-refactor A panel of refactoring masters reviews a scoped piece of code in **isolated contexts**, a KISS/YAGNI gate kills speculative work, the human (CEO) approves a backlog, then execution happens in tiny behavior-preserving steps. Same family as `team-council`: evidence-backed, attributed, recorded under `.council/`. **Core principle:** refactoring changes structure, never behavior. Everything else in this skill protects that line or keeps the refactoring from becoming its own over-engineering. ## Iron Laws 1. **Behavior-preserving only.** Any observable change — outputs, rounding, error types, side effects, call order, emails, logs relied on — is a *Found, not fixed* item for the CEO. It is never a backlog step, even if the user said "fix it while you're there" or "whatever, make it clean". 2. **No safety net, no refactor.** Code the step touches must be pinned by tests first, and the tests must be proven to bite (see Step 0). 3. **One named refactoring per commit.** Structure and behavior never share a commit (Beck, *Tidy First*). 4. **Red means revert.** A failing gate after a step → `git checkout` the step, shrink it, retry. Never debug forward. 5. **An abstraction needs a present second case.** Roadmap talk ("we plan to add providers"), TODOs, and "might" are not cases. Two real call sites today, or it doesn't exist. 6. **Stay inside the approved scope.** No drive-by edits outside the files and steps the CEO approved. **Violating the letter of these laws is