commit-message

Generate conventional commit messages from staged or changed git files.

Updated Jun 4, 2026
One-click install
npx skills add https://github.com/PeteRichardson/skills --skill commit-message-peterichardson
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: commit-message
Source: https://github.com/PeteRichardson/skills/tree/main/commit-message
Command: npx skills add https://github.com/PeteRichardson/skills --skill commit-message-peterichardson

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Writing clear, consistent commit messages is tedious and often skipped, leaving repositories with vague history. This Skill analyzes your git diff and produces a properly formatted conventional commit message you can paste directly into your Git client. ## Core Features & Use Cases - Diff-Based Generation: Reads git status, git diff --staged, and git diff to base the message strictly on actual changes. - Conventional Commit Format: Produces a type(scope): description title with correct type selection (feat, fix, refactor, docs, etc.) and an optional explanatory body. - Staging Awareness: Warns when nothing is staged and bases the message on unstaged changes, or stops when there is nothing to commit. - Use Case: After finishing a feature, type /commit-message to get a ready-to-paste message like feat(auth): add JWT token refresh on 401 response with a body explaining the motivation. ## Quick Start Ask the assistant to generate a commit message for your current staged changes by typing /commit-message.

Frequently Asked Questions about commit-message

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

FAQPage Schema
How do I generate a conventional commit message from my git changes?

Invoke the skill with /commit-message or /commit after making changes. It runs git status and git diff to inspect staged or changed files, then produces a conventional commit message with a type, scope, and imperative description you can paste into your Git client.

What commit types does the conventional commit format support?

The supported types are feat, fix, docs, style, refactor, test, chore, perf, ci, and build. Each maps to a kind of change, such as feat for new capabilities, fix for bug corrections, and chore for tooling or dependency updates.

What happens if no files are staged when generating a commit message?

The skill falls back to analyzing all unstaged changes with git diff and shows a warning that no files are staged. If nothing is staged and nothing has changed, it tells you there is nothing to commit and stops.

Does this skill run git commit or git add automatically?

No, it only generates the message text. It never runs git commit or git add, so you stay in control of staging and committing in your own Git client.

When should a commit message include a body or breaking change note?

Include a body when the motivation or side effects are not obvious from the diff, explaining why rather than what. Add a BREAKING CHANGE footer when the change alters existing behavior that consumers depend on.