git-commit

Partition pending changes into atomic Conventional Commits with git add -p.

Updated May 4, 2026
One-click install
npx skills add https://github.com/mhert/claude-code-helpers --skill git-commit-mhert
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: git-commit
Source: https://github.com/mhert/claude-code-helpers/tree/main/skills/git-commit
Command: npx skills add https://github.com/mhert/claude-code-helpers --skill git-commit-mhert

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill prevents messy, multi-concern commit history by automatically guiding you to split pending work into atomic chunks and write Conventional Commits messages that explain the motivation, not just the diff.

Core Features & Use Cases

  • Commit partitioning (Linux-kernel style): Groups hunks into one logical change per commit so you can review and revert cleanly.
  • Precision staging guidance: Uses git add -p and related techniques to stage exactly the hunks that belong to each individual commit.
  • Conventional Commits message authoring: Drafts type/scope/subject and an intent-focused body (and optional breaking-change footers) that match what was staged.

Quick Start

Use the git-commit skill to stage and commit your current working changes as multiple atomic commits with Conventional Commits messages that explain the why.

Frequently Asked Questions about git-commit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I split pending git changes into atomic commits?

To split pending git changes into atomic commits, you group related diff hunks into individual logical changes and stage them precisely using git add -p, ensuring each commit represents a single reviewable unit.

What is a conventional commit message and how does it explain code changes?

A conventional commit message uses a structured type, scope, and subject format to categorize changes. It focuses on explaining the motivation behind the diff in the body, rather than just describing what was changed.

How do I stage specific hunks for a commit without adding entire files?

You stage specific hunks without adding entire files by using precision staging techniques like git add -p. This allows you to interactively select individual diff sections that belong to a single logical commit.

Can I amend commits on a feature branch using conventional commits?

Yes, you can amend commits on an owned feature branch. The process applies to creating and amending commit history by validating that each commit accurately reflects only the staged hunks.

What is the best way to generate git commit messages for refactoring?

The best way to generate git commit messages for refactoring is to partition pending changes by type and scope, drafting conventional messages with a subject, body, and optional breaking-change footers that match the staged hunks.