Refactor share
Codebase
What it measures
The share of each week's code churn (additions + deletions, after noise exclusion) that came from deletion-heavy PRs — PRs that removed at least as many lines as they added. Weeks with no merged churn show a gap, not a zero.
Why it matters
Refactoring and debt paydown are invisible in throughput numbers — a week spent deleting dead code looks like a slow week everywhere else. This panel gives cleanup work a place to show up, so delivery pressure doesn't silently crowd it out.
How to read it
- A healthy codebase usually shows a nonzero floor — some fraction of work is always pruning.
- Zero for many weeks running is the conversation starter: when did we last delete anything?
- The share is churn-weighted: one big cleanup counts for what it touched, not one tick.
- On repos with few or small PRs the line is spiky — a quiet week with one cleanup PR reads as 100%. Read multi-week patterns, not single spikes.
- The drilldown lists the deletion-heavy PRs behind each week.
Anti-blame
Common misreads
- A file move or rename looks deletion-heavy (delete here, add there) — renames inflate the share.
- A genuine refactor that grows the code (extracting, clarifying) does not count at all.
- This is a proxy built from PR shape, not a measure of code quality.