Intelligently create git commits with proper formatting, conventional commit style, and Carbon ACX footer conventions.
This skill automates the creation of high-quality git commits for Carbon ACX by:
Trigger Patterns:
Do NOT Use When:
git status shows clean)git.pr.create skill instead)bash - Run git commands (status, diff, log, add, commit)read_file - Read modified files for contextgrep - Search for patterns in changesAccess Level: 2 (File Modification - can create commits)
Tool Rationale:
bash: Required for all git operationsread_file: Helps understand changes for better commit messagesgrep: Search commit history for style patternsExplicitly Denied:
--no-verify flag (never skip hooks).gitignore patternsInput:
Example:
"Commit the UX improvements to the dashboard"
"Create a commit for these changes"
"Commit with message: fix typo in README"
Output:
Validation:
Required:
.git directory exists)git add already run)Optional:
gh CLI for GitHub integration (for suggesting PR creation)Run in parallel:
git status
git diff --staged
git log --oneline -10
Analysis:
Format:
<type>(<scope>): <subject>
<body>
š¤ Generated with [Claude Code](https://claude.com/claude-code)
Conventional Commit Types:
feat - New featurefix - Bug fixchore - Maintenance, dependencies, toolingdocs - Documentation onlyrefactor - Code restructuring without behavior changetest - Adding or updating testsstyle - Formatting, whitespace, missing semicolonsperf - Performance improvementsScope Examples:
web - Modern web app (apps/carbon-acx-web)site - Static React sitecalc - Derivation enginedata - CSV data filesworkers - Cloudflare Workersci - CI/CD workflowsSubject Line:
Body:
Closes #123, Relates to #456Use HEREDOC for message:
git commit -m "$(cat <<'EOF'
feat(web): add dark mode toggle to dashboard
Users requested ability to switch between light and dark themes
for extended analysis sessions. This adds a theme toggle in the
header that persists preference to localStorage.
Closes #42
š¤ Generated with [Claude Code](https://claude.com/claude-code)
EOF
)"
If hook fails:
If hook modified files:
# Check if safe to amend
git log -1 --format='%an %ae' # Verify we're the author
git status # Verify not pushed yet
# If both checks pass:
git add .
git commit --amend --no-edit
If unsafe to amend:
git log -1 --oneline
git status
Report to user:
abc1234 feat(web): add dark mode toggleUser: "Commit the new emission chart component"
Claude Process:
git status, git diff --staged, git log -10apps/carbon-acx-web/src/components/feat(web): add EmissionChart component for layer visualization
Creates reusable chart component using Recharts to display
emission data by layer. Includes responsive design, hover
tooltips, and accessibility labels.
š¤ Generated with [Claude Code](https://claude.com/claude-code)
User: "Commit the bug fix"
Claude Process:
calc/derive.py line 245fix(calc): correct emission factor calculation for aviation layer
Previous calculation was using wrong unit conversion factor
(kg instead of tCO2e). This fixes the multiplier to match the
emission_factors.csv schema.
Fixes #128
š¤ Generated with [Claude Code](https://claude.com/claude-code)
pytest tests/ to verify fixUser: "Commit the dependency updates"
Claude Process:
package.json and pnpm-lock.yaml modifiedchore(deps): update React and TypeScript dependencies
- React 18.2.0 ā 18.3.1 (security patch)
- TypeScript 5.5.3 ā 5.5.4 (bug fixes)
All tests pass with updated versions.
š¤ Generated with [Claude Code](https://claude.com/claude-code)
git commitpnpm run lint --fix to auto-fixgit add .
git commit --amend --no-edit
User: "Commit the README updates"
Claude Process:
README.md changeddocs: update installation instructions for pnpm workspaces
Clarifies the difference between running commands from repo
root vs within app directory. Adds troubleshooting section
for common pnpm workspace issues.
š¤ Generated with [Claude Code](https://claude.com/claude-code)
User: "Commit these refactoring changes"
Claude Process:
apps/carbon-acx-web/src/refactor(web): reorganize components into feature-based folders
Restructures components from flat directory to feature-based
organization:
- charts/ - All visualization components
- forms/ - Activity and data entry forms
- layout/ - Headers, footers, navigation
No functional changes, only file moves and import updates.
š¤ Generated with [Claude Code](https://claude.com/claude-code)
pnpm test to verify imports still resolve correctly"Scope Limitations:
git add first)Known Edge Cases:
git addgit add files firstPerformance Constraints:
Security Boundaries:
Success Metrics:
Failure Modes:
git add filesgit configRecovery:
Composes With:
git.pr.create - After committing, create pull requestgit.branch.manage - Create branch before committingschema.linter - Validate data files before committing changesDependencies:
Alternative Skills:
git.pr.creategit.release.prepOwner: Workspace Team (shared skill) Review Cycle: Monthly Last Updated: 2025-10-24 Version: 1.0.0
Maintenance Notes: