
Git Commit Message Writer
Generate semantic commit messages from code diffs automatically
What You Can Do
Claude analyzes your code diffs and generates standardized commit messages that follow the Conventional Commits specification. The skill automatically determines the correct commit type, scope, and description based on the changes you've made, ensuring your messages are parseable by automation tools while remaining human-readable for code reviewers.
Features
automatically selects from feat, fix, docs, style, refactor, perf, test, ci, chore, build, or revert based on change analysis
identifies affected components or modules and includes them in the message format
flags BREAKING CHANGE footers when modifications affect API contracts or major functionality
consolidates changes across multiple files into cohesive, semantically accurate messages
ensures strict adherence to formatting rules: imperative mood, present tense, proper line wrapping at 72 characters
produces machine-parseable output suitable for automated changelog generation and semantic versioning workflows
includes detailed explanations of why changes were made (not just what) with proper issue references and close directives
Example Output
Input (diff):
--- a/src/auth.js
+++ b/src/auth.js
@@ -45,6 +45,8 @@ export function validateToken(token) {
+ const isExpired = token.exp < Date.now();
+ if (isExpired) throw new AuthError('Token expired');
Output:
fix(auth): prevent expired token validation bypass
Add expiration check before token validation to prevent
use of expired tokens in protected routes.
Closes #342
Input (mixed changes): Refactored utils module, added new logging feature, updated tests
Output:
feat(utils): add structured logging throughout module
Implement JSON-based logging system with configurable
levels. Includes utility refactor to support new logger
pattern.
BREAKING CHANGE: Old log function signature replaced
Closes #567
What's Included
- git-commit-message-writer.md: Complete skill instruction file with Conventional Commits specification reference
- Conventional Commits type reference: Quick lookup table for all commit types and when to use each
- Diff analysis template: Structured prompt template for analyzing different diff formats
- Breaking change checklist: Framework for identifying and documenting breaking changes
- Scope naming conventions: Best practices and examples for component/module scope naming
Who It's For
- Software engineers — automate consistent commit message creation across pull requests
- DevOps/Platform engineers — ensure parseable commits for automated versioning and release pipelines
- Tech leads & architects — enforce commit standards across team codebases
- Open-source maintainers — maintain readable commit histories and automated changelogs
- Code review leads — standardize commit quality during pull request reviews
Best For
- Analyzing staged git diffs and generating corresponding commit messages
- Creating standardized messages across teams to enable semantic versioning
- Generating machine-readable commits for CI/CD pipelines and automated changelog tools
- Identifying and documenting breaking changes in API or major functionality updates
- Consolidating multi-file changes into semantically accurate, cohesive messages







