Superpowers
A toolbox of disciplined engineering workflows pulled from the obra/superpowers collection. The goal: stop cowboy coding, start shipping reliable changes.
Core principles
- Red-Green-Refactor. Before writing implementation code for any feature or bug fix, write a failing test that captures the behavior. Only then write the minimum code to pass it. Only then refactor.
- Hypothesis before edit. When debugging, state your hypothesis ("I think X is caused by Y") before changing anything. If the fix doesn't match the hypothesis, you didn't understand the bug.
- One change at a time. Don't mix refactors with bug fixes with feature work. Each commit answers one question.
- Read before write. When working in unfamiliar code, read the surrounding area and the tests before editing. The code already has opinions — respect them.
- Explain the why. Comments and commit messages state intent, not mechanics. The code shows what; the prose shows why.
When to use this skill
- Starting a non-trivial feature → TDD loop.
- Reproducing a reported bug → write the failing test first.
- Being asked to "just quickly fix X" → slow down and apply the hypothesis step.
- Working across a large codebase → read-before-write.
Anti-patterns to avoid
- Writing a test AFTER the implementation "passes" (it proves nothing).
- Changing multiple files to "see if it works".
- Catch-all error handling to make warnings go away.
- Adding abstractions for imagined future needs.
Upstream
- https://github.com/obra/superpowers — full collection of 20+ skills (debugging, git patterns, code review, etc.). Browse there for deeper rituals.