← Back to Skills Marketplace
afine907

Commit Diff Analyzer

by afine907 · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ✓ Security Clean
44
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install commit-diff-analyzer
Description
Analyzes code changes between two git commits. Use when user provides two commit IDs and wants to understand what changed between them, including file modifi...
README (SKILL.md)

Commit Diff Analyzer

Usage Pattern

When user provides two commit IDs (in any order or format), analyze the changes between them:

  1. Validate commits exist: Run git cat-file -t \x3Ccommit> for each commit ID
  2. Get commit info: Run git log -1 --format=fuller \x3Ccommit> for both commits
  3. Show diff: Run git diff \x3Colder-commit>..\x3Cnewer-commit> (chronological order)
  4. Show stats: Run git diff --stat \x3Colder-commit>..\x3Cnewer-commit>

Output Organization

Present the analysis with:

  1. Commit metadata - Author, date, commit message for both commits
  2. Change summary - Files changed, insertions, deletions
  3. Detailed diff - Line-by-line changes with context
  4. File breakdown - Group by: Modified, Added, Deleted files

Key Commands

# Validate commits exist
git cat-file -t \x3Ccommit-id>

# Get full commit info
git log -1 --format="Hash: %H%nAuthor: %an%nDate: %ad%nMessage: %s%n" \x3Ccommit-id>

# Chronological diff (older..newer)
git diff \x3Colder-commit>..\x3Cnewer-commit>

# Diff stat
git diff --stat \x3Colder-commit>..\x3Cnewer-commit>

# Show files changed
git diff --name-only \x3Colder-commit>..\x3Cnewer-commit>

Handling Edge Cases

  • Invalid commit IDs: Report error and suggest running git log to see recent commits
  • Same commit: Notify user both IDs point to the same commit
  • Non-git directory: Error - skill only works in git repositories
  • Reverse order: Detect which commit is older and adjust command accordingly

Commit ID Formats

Accept various formats:

  • Full SHA: abc123def456...
  • Short SHA: abc123d (at least 7 chars)
  • Branch names (if they point to commits)
  • HEAD references like HEAD~5

Example Output Structure

=== Commit A ===
Hash: abc123...
Author: John Doe
Date: 2024-01-15 10:30:00
Message: feat: add user login

=== Commit B ===
Hash: def456...
Author: Jane Smith
Date: 2024-01-20 14:45:00
Message: fix: resolve auth bug

=== Changes Summary ===
5 files changed, 120 insertions(+), 35 deletions(-)

=== File Breakdown ===
Modified: src/auth.js, src/login.html
Added: src/auth-utils.ts
Deleted: src/old-auth.php

=== Diff ===
... (detailed diff output)
Usage Guidance
This appears safe for normal use as a git diff helper. Before installing, remember that it may show code and commit history from the current repository in the chat, so use it only where you are comfortable exposing that diff content to your agent session.
Capability Analysis
Type: OpenClaw Skill Name: commit-diff-analyzer Version: 1.0.0 The commit-diff-analyzer skill is a standard utility designed to help an AI agent analyze changes between two git commits. It uses legitimate git commands (git log, git diff, git cat-file) to retrieve metadata and file differences, with clear instructions for handling edge cases and formatting output. No malicious patterns, data exfiltration, or suspicious execution logic were found in SKILL.md or _meta.json.
Capability Assessment
Purpose & Capability
The requested behavior is coherent with the stated purpose: analyzing differences between two git commits.
Instruction Scope
The skill instructs the agent to run git commands using user-provided commit IDs or refs; this is expected for the purpose, but users should ensure it runs only in the intended repository.
Install Mechanism
There is no install spec and no executable code files; the skill is instruction-only.
Credentials
The commands are limited to local git inspection and diff output, which is proportionate for a commit comparison skill.
Persistence & Privilege
No persistence, credential use, background behavior, privilege escalation, or account access is described.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install commit-diff-analyzer
  3. After installation, invoke the skill by name or use /commit-diff-analyzer
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
Initial release
Metadata
Slug commit-diff-analyzer
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is Commit Diff Analyzer?

Analyzes code changes between two git commits. Use when user provides two commit IDs and wants to understand what changed between them, including file modifi... It is an AI Agent Skill for Claude Code / OpenClaw, with 44 downloads so far.

How do I install Commit Diff Analyzer?

Run "/install commit-diff-analyzer" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Commit Diff Analyzer free?

Yes, Commit Diff Analyzer is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Commit Diff Analyzer support?

Commit Diff Analyzer is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Commit Diff Analyzer?

It is built and maintained by afine907 (@afine907); the current version is v1.0.0.

💬 Comments