rescue-hotspotslisted
Install: claude install-skill vivekbhange-hub/legacy-rescue-skill
# rescue-hotspots
Most of a legacy codebase is quiet. A small set of files gets changed every week and is also
the hardest to read; that is where bugs, slow reviews and production incidents come from, and
where a safety net pays back first. This skill finds that set with numbers instead of
opinions: change frequency from git, complexity measured from the current files, coupling
from files that are committed together. The output is a ranked list the team can argue with.
## Inputs
- `$ARGUMENTS`: repository path (default `.`) and an optional time window.
- Default window: the last 12 months. Use 18-24 months for slow-moving repos (fewer than
about 100 commits in 12 months). Use the full history only if it is short.
- `rescue/map.md` if it exists, to name modules in the write-up.
## Output
- `rescue/hotspots.md`: the script's tables plus your interpretation at the top.
- `rescue/hotspots.json` (optional, with `--format json`) for `rescue-plan`.
## Steps
1. **Check history is usable.** Run `git rev-list --count HEAD` and
`git log --format=%ad --date=short | tail -1`. If there are fewer than about 30 commits,
tell the user churn will be thin and lean on complexity. If the repo is a shallow clone
(`git rev-parse --is-shallow-repository` prints `true`), say the numbers only cover the
fetched history.
2. **Run the analysis.**
```
python3 "${CLAUDE_SKILL_DIR}/hotspots.py" --repo . --since "12 months ago" --top 25 --output rescue/hotspots.md
```
Useful