Agent skill
commit
Create a git commit with well-structured message and push to remote following BetterPortal project standards
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/commit-rawpatty-betterportal
SKILL.md
Git Commit Skill
Create a git commit for staged changes following BetterPortal project standards and push to remote.
Commit Message Format
Follow the project's existing pattern:
- First line: Brief summary starting with a verb (max 72 chars)
- Examples: "Add", "Fix", "Update", "Remove", "Eliminate"
- Blank line
- Body: Detailed bullet points explaining changes (if needed)
- Footer:
Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
Process
- Review changes: Run
git statusandgit diff --cachedto see what will be committed - Review recent commits: Run
git log --oneline -5to match the project's message style - Generate message:
- If argument provided: Use it as the first line
- If no argument: Analyze the diff and create appropriate message
- Add detailed body with bullet points for multiple changes
- Always add Co-Authored-By footer
- Create commit: Use heredoc format for multi-line messages:
bash
git commit -m "$(cat <<'EOF' First line summary - Detailed point 1 - Detailed point 2 Co-Authored-By: Claude Sonnet 4.5 <[email protected]> EOF )" - Verify: Run
git log -1 --statto confirm commit was created correctly - Push to remote: Run
git pushto push the commit to the remote repository
Examples from BetterPortal History
Good commit messages from this project:
Add configurable history limit and bookmark conversion featureEliminate redirect flash for same-directory navigationFix tenant switching to use correct GUID and preserve query parametersRemove token extraction and add privacy documentation for Chrome Web Store
Usage
# With message argument
/commit Add keyboard shortcut for search
# Without argument (analyze diff and generate message)
/commit
# Complex change (will generate detailed body)
/commit Refactor history pruning logic
Important Notes
- Always include Co-Authored-By footer for commits made with Claude
- Follow existing verb patterns: Add, Fix, Update, Remove, Eliminate, Refactor
- Be specific: "Fix tenant switching logic" not "Fix bug"
- No emoji unless explicitly requested
- Check staged changes first: Don't commit if nothing is staged
- Automatically pushes to remote: After committing, the changes will be pushed to the remote repository
- Bump the version: When committing feature or bug fix changes, bump the version in both
src/manifest.jsonandpackage.json(keep them in sync). Use patch version increments (e.g., 1.0.64 → 1.0.65). Include the version bump in the same commit as the changes.
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?