code-simplify
Code
Refactors in small steps that are each verified: one simplification per commit.
How to call it
/code-simplify [scope] | A path, a branch, or “again” to go over everything the branch touched. |
|---|---|
simplifica esse branch | Asking to refactor or simplify. |
What it does, in order
Set the scope.
Learn why the code exists before removing it.
Make one simplification per commit.
Run type check, lint, unit tests and the affected e2e after each.
Give a wanted change of behaviour its own commit, called out.
Give a bug found on the way its own fix commit, with a test that fails on the old code.
After changing a shared export, test every package that uses it.
The rules it keeps
- One simplification per commit.
- Behaviour stays the same unless a commit says otherwise.
- The uses of an export are counted before it is removed.
- Every commit passes the checks on its own.
What comes out
The commits, one line each, what was left alone and why, any change of behaviour, and the decisions still open.