Skip to content
Back to skills

Repository History

ASecurity

Explain why code exists: Git blame, renames, reverts, and linked PRs.

  • 10 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 23, 2026
ai-agentsgodebugginggitapidocumentation

Works with

  • api

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned October 6, 2026

npx -y skills add fmind/dot --skill repository-history --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Repository History?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Repository History
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/fmind-repository-history/badge)](https://www.skillsdirectory.com/skills/fmind-repository-history)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: repository-history
description: "Explain why code exists: Git blame, renames, reverts, and linked PRs."
license: MIT
metadata:
  kind: task
  author: Médéric HURIER (Fmind)
  source: github.com/fmind/dot/tree/main/skills/repository-history
  created: "2026-08-08"
  updated: "2026-10-05"
---

# Repository History

Explain why tracked code exists from Git lineage and recorded rationale. Keep present-day debugging in [systematic-debugging](../systematic-debugging/SKILL.md) and external API choices in [research-brief](../implementation-plan/references/research-brief.md).

## Workflow

1. **Bound the question**: path, symbol, revision range, and the decision the history should inform.
1. **Trace evidence**: follow [investigation.md](references/investigation.md) for coverage, blame, line history, pickaxe, renames, commit inspection, and exact PR mapping through [gh](../gh/SKILL.md).
1. **Explain the timeline**: connect behavior changes, tests, reverts, and later superseding decisions; treat formatting and co-change as clues rather than causes.
1. **Report**: the investigation's history note, rating confidence with the scale in Gotchas.

## Gotchas

- **Investigation is read-only**: Preserve the working tree and existing refs. Fetch missing objects into an isolated clone when needed for the requested investigation; use a disposable worktree for bisect experiments. Pulling into the working tree, rewriting history, and contacting authors require authority for those effects.
- **Current blame is not original authorship**: a committer is not necessarily the designer, and a message can state intent without proving the constraint still holds; redact email addresses from returned evidence.
- **Rate confidence by evidence**: `High` needs explicit rationale that agrees with the patch, tests, and later history; `Medium` has agreeing lineage and co-change without stated rationale; `Low` rests on blame, one title match, a semantic search, sparse history, or an ancestry break; otherwise say `UNKNOWN`.
- **Downgrade stale rationale**: A revert describes a past decision; downgrade it when later architectural changes contradict the trade-off.
- **Missing history is not absence**: Never infer that a missing commit or discussion does not exist; state the gap and lower confidence.

## Documentation

- [git blame](https://git-scm.com/docs/git-blame) · [git log](https://git-scm.com/docs/git-log) · [Pull requests associated with a commit](https://docs.github.com/en/rest/commits/commits#list-pull-requests-associated-with-a-commit)
- Adapted from [awesome-llm-apps commit-archaeologist](https://github.com/Shubhamsaboo/awesome-llm-apps/blob/779e9f9bcf87fa8cd95870a438b70b84e47d3173/agent_skills/commit-archaeologist/SKILL.md).
- Companion skills: [systematic-debugging](../systematic-debugging/SKILL.md) (reproduce a current failure), [repository-review](../repository-review/SKILL.md) (one change or cross-cutting audit), [research-brief](../implementation-plan/references/research-brief.md) (current external facts), [github-issues](../github-issues/SKILL.md) (remote issue state).

Files in this skill

  • SKILL.md3.3 KB
  • references/investigation.md3.6 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…