Agent skill

Git Investigate

by sd0xdev in sd0xdev/sd0x-harness

Git history investigation. An agent skill from sd0xdev/sd0x-harness.

MITAuto-check passedDevelopment

Install Git Investigate

skills CLI
$ npx skills add sd0xdev/sd0x-harness --skill git-investigate -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install sd0xdev/sd0x-harness git-investigate --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/sd0xdev/sd0x-harness.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/git-investigate .claude/skills/git-investigate && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
git-investigate
GitHub stars
192
Token cost
~634 tokens
SKILL.md length
147 words
Files
2 (incl. references)
Skills in repo
91
Repo updated
First seen
Licence
MIT

At a glance

Git history investigation. An agent skill from sd0xdev/sd0x-harness.

  • : tracking code changes
  • SKILL.md covers Trigger, When NOT to Use, Command and Workflow, plus 6 more sections
  • Calls git
  • Finding where bugs were introduced

What it does

Git Investigate is an agent skill from sd0xdev/sd0x-harness. Git history investigation. Use when: tracking code changes, finding where bugs were introduced, root cause analysis. Not for: code exploration (use code-explore), issue analysis (use issue-analyze). Output: history trace + root cause report.

Its SKILL.md is about 630 tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including reference files (for example `references/commands.md`).

It sits in Development, covering Root cause analysis and Git workflow. It works with Git. The repository describes itself as: The harness layer for Claude Code — a reference implementation of harness engineering with hook-enforced dual review, state-machine gates that survive context compaction, and… The licence is MIT.

When your agent uses it

  • : tracking code changes
  • Finding where bugs were introduced
  • Root cause analysis

Example prompts

  • “/git-investigate”

Requirements

  • Pre-approved tools (allowed-tools): Bash(git:*), Read, Grep, Glob, Agent

What it can do on your machine

Read from SKILL.md and the folder at commit c9a2036. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Bash(git:*)
    • Read
    • Grep
    • Glob
    • Agent

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • git

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Git Investigate loads about 634 tokens when it runs, and up to ~1.2k if it reads all its reference files. Until then it costs about 64 tokens; SKILL.md has 147 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~64
When it runs · the whole SKILL.md, loaded when a task matches
~634
With references · SKILL.md plus every file in references/, read only if the agent opens them
~1.2k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from sd0xdev/sd0x-harness at commit c9a2036, republished under its MIT licence (© sd0xdev). 147 words, ~634 tokens.

Download SKILL.mdSave it as .claude/skills/git-investigate/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
git-investigate
description
Git history investigation. Use when: tracking code changes, finding where bugs were introduced, root cause analysis. Not for: code exploration (use code-explore), issue analysis (use issue-analyze). Output: history trace + root cause report.
allowed-tools
Bash(git:*), Read, Grep, Glob, Agent

Git Investigate Skill

Trigger

  • Keywords: code history, git blame, track changes, who wrote this, when was it changed, root cause, code archaeology

When NOT to Use

  • Code review (use codex-review)
  • Feature development (use feature-dev)
  • Just want to read code (use Read directly)

Command

bash
/git-investigate src/service/xxx.ts:123      # Specific line
/git-investigate processToken                 # Function name
/git-investigate "error message"              # Keyword

Workflow

Locate code -> git blame -> find commit -> trace history -> analyze changes -> report

Investigation Framework

QuestionMethod
Who wrote it?git blame
When was it changed?git log --follow
Why was it changed?commit message + PR
What was missed?git diff compare original vs problematic version

Common Patterns

PatternSymptomRoot Cause
Type removedEnum value deletedAssumed no longer needed
Condition simplifiedIf conditions reducedMissed during refactoring
RenamePartially unchangedIncomplete search-and-replace
Boundary ignoredOnly handles main flowEdge cases not considered

Output

markdown
## Git Investigation Report
- **Target**: <file/feature>
- **Timeline**: <commit range>
- **Root cause**: <analysis>
- **Introduced by**: <commit hash + author>

Verification

  • Report includes: investigation target, author info, timeline, original vs problematic code
  • Root cause has clear analysis
  • Fix recommendation is specific and actionable

References

  • references/commands.md - Git command reference + report template

Examples

Input: Who changed this line of code?
Action: git blame -> find commit -> trace PR -> output report
Input: When was this bug introduced?
Action: git log -p -S -> locate introduction point -> analyze cause -> output report

© sd0xdev, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (references) in skills/git-investigate of sd0xdev/sd0x-harness.

  • SKILL.md
  • references/commands.md

Open the folder on GitHubat commit c9a2036

Compare with similar skills

Git Investigate next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Git Investigate compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Git Investigate this skillsd0xdev/sd0x-harness192—~634Automated safety check: PassMIT
Code Design Rationale Investigatorcursor/plugins10k9 repos~2.6kAutomated safety check: PassNone
Targeted Emergency Bug FixVeryGoodOpenSource/vgv-wingspan108—~1.9kAutomated safety check: PassMIT
Flowfile Failure ArchaeologyEdwardvaneechoud/Flowfile370—~7.5kAutomated safety check: PassMIT
TiDB Test Diff Triagepingcap/tidb41k—~498Automated safety check: PassApache-2.0
Finishing a Development Branchobra/superpowers296k5 repos~1.9kAutomated safety check: PassMIT

Similar skills

  • Official

    Digs into why code is shaped the way it is by checking git history, pull requests and connected tools in parallel, then reporting a cited read on the tradeoffs.

    10k GitHub starsUsed in 9 repos~2.6k tokens
    DevelopmentAuto-check passed
  • Targeted Emergency Bug Fix

    VeryGoodOpenSource/vgv-wingspan

    Applies a minimal fix to an emergency bug through triage, root-cause location, a hotfix branch and a blast-radius check, with tests and review still required.

    108 GitHub stars~1.9k tokensUpdated 7 days ago
    DevelopmentAuto-check passed
  • Flowfile Failure Archaeology

    Edwardvaneechoud/Flowfile

    Chronicles 25+ major incidents in Flowfile's git history (worker/kernel deadlocks and races, reverted or self-reverted branches, Electron/Tauri packaging breakage, codegen correctness bugs, CI…

    370 GitHub stars~7.5k tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Investigates TiDB plan or test-result diffs that the change does not explain, ruling out failpoint setup and merge effects before expected outputs are updated.

    41k GitHub stars~498 tokensUpdated today
    Testing & QAAuto-check passed
  • Walks the last step of a branch: confirm tests pass, detect the git environment, ask how to integrate, carry out your choice and clean up the worktree.

    296k GitHub starsUsed in 5 repos~1.9k tokens
    DevelopmentAuto-check passed
  • Merges external GitHub pull requests while keeping the original author credited, and fixes conflicts after the merge instead of rewriting the contribution.

    16k GitHub starsUsed in 1 repo~847 tokens
    DevelopmentAuto-check passed

More from sd0xdev/sd0x-harness

All 91 skills in this repo
  • Adr

    sd0xdev/sd0x-harness

    Write an Architecture Decision Record (ADR) for a feature — Context / Decision / Status / Consequences / Alternatives, filed as docs/features/<feature/adr-<NNN-<title.md with a 3-digit zero-padded…

    192 GitHub stars~4.8k tokensUpdated yesterday
    Auto-check passed
  • Load PR Review

    sd0xdev/sd0x-harness

    Load GitHub PR review comments into AI session — analyze, triage, plan.

    192 GitHub stars~4.4k tokensUpdated yesterday
    Auto-check passed
  • Next Step

    sd0xdev/sd0x-harness

    Change-aware next step advisor. An agent skill from sd0xdev/sd0x-harness.

    192 GitHub stars~1.6k tokensUpdated yesterday
    Auto-check passed
  • Obsidian CLI

    sd0xdev/sd0x-harness

    Obsidian vault integration via official CLI. An agent skill from sd0xdev/sd0x-harness.

    192 GitHub stars~1.1k tokensUpdated yesterday
    Auto-check passed
  • Orchestrate

    sd0xdev/sd0x-harness

    Agent-driven workflow orchestration (v1 report-only). An agent skill from sd0xdev/sd0x-harness.

    192 GitHub stars~2.5k tokensUpdated yesterday
    Auto-check passed
  • PR Comment

    sd0xdev/sd0x-harness

    Post friendly review comments to a GitHub PR — prepare locally, preview, then submit as atomic review.

    192 GitHub stars~1.5k tokensUpdated yesterday
    Auto-check passed

Works with

Categories

Questions about Git Investigate

What does Git Investigate do?

Git history investigation. An agent skill from sd0xdev/sd0x-harness. Git Investigate is an agent skill from sd0xdev/sd0x-harness. Git history investigation.

When should I use Git Investigate?

Git Investigate fits situations like: : tracking code changes; finding where bugs were introduced; root cause analysis.

How do I install Git Investigate in Claude Code?

Run `npx skills add sd0xdev/sd0x-harness --skill git-investigate -a claude-code`. Or copy the skill folder (skills/git-investigate in sd0xdev/sd0x-harness) into .claude/skills/git-investigate in your project. Claude Code loads it when a task matches its description.

How do I install Git Investigate in Codex?

Run `npx skills add sd0xdev/sd0x-harness --skill git-investigate -a codex`. Or copy the skill folder (skills/git-investigate in sd0xdev/sd0x-harness) into .agents/skills/git-investigate in your project. Codex loads it when a task matches its description.

Can I use Git Investigate in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add sd0xdev/sd0x-harness --skill git-investigate -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/git-investigate, .gemini/skills/git-investigate, .github/skills/git-investigate and .opencode/skills/git-investigate in your project.

What does Git Investigate need to run?

Going by SKILL.md and its folder, Git Investigate needs the command-line tools its instructions call (git). Its frontmatter pre-approves these tools: Bash(git:*), Read, Grep, Glob, Agent.

Does Git Investigate access the network?

SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Git Investigate safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Git Investigate use?

Git Investigate is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Git Investigate use?

About 634 tokens (SKILL.md is roughly 2.5k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 558 tokens, read only when the agent opens those files.

What are the alternatives to Git Investigate?

Skills that share tags, products or a category with Git Investigate: Code Design Rationale Investigator (cursor/plugins, 10k stars), Targeted Emergency Bug Fix (VeryGoodOpenSource/vgv-wingspan, 108 stars), Flowfile Failure Archaeology (Edwardvaneechoud/Flowfile, 370 stars) and TiDB Test Diff Triage (pingcap/tidb, 41k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Git Investigate?

sd0xdev (a GitHub user) maintains it in sd0xdev/sd0x-harness, which has 192 GitHub stars. The repository holds 91 skills in this directory. The repository was last updated on October 6, 2026.

Source: sd0xdev/sd0x-harness on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.