cowboylogic/ai-dev/git-commit-messages
Claude Code and agent skill by cowboylogic/ai-dev
- community
- ext:[{"type":"hook","description":"Pre/post lifecycle hooks"}]
Checking that the SKILL.md file is still in the repository.
Guide for writing descriptive yet succinct git commit messages following best practices. Use this when creating commit messages, reviewing commits, or establishing commit message conventions.
Install
npx vskill@latest install cowboylogic/ai-dev/git-commit-messagesSemi-extensibleMentions customization, but needs skill-specific knowledge. Read the extensible skills standard
SKILL.md
The same SKILL.md was published earlier as cowboylogic/ai-dev/git-commit-messages.
Git Commit Messages
This skill helps you write clear, descriptive, and succinct git commit messages that follow industry best practices and make project history more maintainable.
When to Use This Skill
Use this skill when:
- Writing commit messages for code changes
- Reviewing pull requests and commit quality
- Establishing commit message conventions for teams
- Understanding how to structure commit history
- Training team members on commit message best practices
Prerequisites
- Basic understanding of git commands
- Familiarity with your project's commit history
- Knowledge of the changes being committed
Commit Message Guidelines
Basic Structure
A good commit message follows this format:
Types
Use these conventional commit types:
- feat: New feature or functionality
- fix: Bug fix
- docs: Documentation changes
- style: Code style/formatting changes (no logic changes)
- refactor: Code refactoring (no feature changes or bug fixes)
- test: Adding or updating tests
- chore: Maintenance tasks, build changes, dependency updates
- perf: Performance improvements
- ci: CI/CD pipeline changes
- build: Build system or dependency changes
Subject Line Rules
- Limit to 50 characters - Keep it concise but descriptive
- Do not end with a period - No punctuation at the end
- Use imperative mood - "Add feature" not "Added feature" or "Adding feature"
- Be specific - Clearly describe what changed
Body Guidelines
- Separate from subject with blank line - Always add a blank line
- Wrap at 72 characters - Maintain readability
- Explain what and why - Describe the change and reasoning
- Use bullet points - For multiple related changes
- Reference issues - Link to tickets or issues when applicable
Footer Guidelines
- Breaking changes - Use "BREAKING CHANGE:" followed by description
- Issue references - Closes #123, Fixes #456, etc.
- Co-authors -
Co-authored-by: Name <email>
Instructions
Step 1: Analyze Your Changes
Before writing the commit message, understand what changed:
- Review the diff - Use
git diff --cachedto see staged changes - Categorize the change - Determine the appropriate type (feat, fix, etc.)
- Identify the scope - Which component, module, or feature was affected
- Note breaking changes - Any changes that break existing APIs
Step 2: Write the Subject Line
Craft a clear, concise subject line:
Step 3: Add Body (When Needed)
Include a body for complex changes:
Step 4: Include Footer (When Applicable)
Add footer information for special cases:
Step 5: Commit the Changes
Use git to create the commit:
Examples
Feature Addition
Bug Fix
Documentation Update
Refactoring
Breaking Change
Best Practices
Do's
- ✅ Keep subject lines under 50 characters
- ✅ Use conventional commit format when possible
- ✅ Explain the "why" behind changes, not just the "what"
- ✅ Reference related issues or pull requests
- ✅ Use bullet points for multi-part changes
- ✅ Review commit messages before pushing
Don'ts
- ❌ Write vague messages like "fix bug" or "update code"
- ❌ Include irrelevant details about your day or mood
- ❌ Use swear words or unprofessional language
- ❌ Commit large, unrelated changes together
- ❌ Forget to mention breaking changes
Team Consistency
- Establish conventions - Document your team's commit message standards
- Use templates - Create commit message templates for common scenarios
- Review process - Include commit message quality in code reviews
- Tools integration - Use commit hooks or CI to enforce standards
- Education - Train team members on best practices
Tools and Automation
Commit Message Linting
Use tools to enforce commit message standards:
Git Hooks
Add pre-commit hooks to validate messages:
Interactive Commit
Use git's interactive mode for complex commits:
Common Patterns
For Different Project Types
Web Applications:
APIs:
Infrastructure:
For Different Change Sizes
Small Changes:
Large Changes:
File Structure
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/git-commit-messages/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Extension points
hookPre/post lifecycle hooks
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/cowboylogic/ai-dev/git-commit-messages)