Agent skill
git-commit
Stage all changes, create a helpful commit message, and push to remote. Use this when the user wants to quickly commit and push their changes without manually staging files or writing a commit message.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/git-commit-kjdragan-universal-agent
SKILL.md
Git Commit Skill
Quickly stage all changes, create a helpful commit message, and push to remote.
Usage
When user invokes this skill, execute the following steps:
- Check git status - See what files have changed
- Stage all changes - Add all modified/new files
- Write a helpful commit message - Based on the actual changes
- Push to remote - Push to the current branch's upstream
Commands
# Check current status and changes
git status
git diff --staged
git diff
# Stage all changes
git add -A
# Commit with helpful message (use HEREDOC for multi-line)
git commit -m "$(cat <<'EOF'
<summary line>
<optional detailed description>
Co-Authored-By: Claude <[email protected]>
EOF
)"
# Push to remote (uses current branch's upstream)
git push
Commit Message Guidelines
- Summary line: 50 chars or less, describes what changed and why
- Imperative mood: "Add feature" not "Added feature" or "Adds feature"
- Focus on the why: Explain the reason for changes, not just the mechanics
Examples
feat: Add slash command for quick git commits
Implements a new skill that stages all changes, generates
a helpful commit message based on git diff, and pushes
to remote repository.
Co-Authored-By: Claude <[email protected]>
fix: Resolve Pydantic V2 deprecation warnings
Updated model definitions to use Pydantic V2 syntax
and removed deprecated field() calls.
Co-Authored-By: Claude <[email protected]>
Safety Checks
Before committing, verify:
- No sensitive files (
.env, credentials, secrets) - No generated binaries or large artifacts accidentally staged
- Branch is correct for the changes being made
If any issues are found, warn the user and ask before proceeding.
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?