Loading...
Loading...
Creates git commits following Conventional Commits format with type/scope/subject. Use when user wants to commit changes, create commit, save work, or stage and commit. Handles regular branch commits (development) and merge commits (PR closure). Enforces project-specific conventions from CLAUDE.md.
npx skill4agent add fvadicamo/dev-agent-skills git-commit# 1. Check for project-specific commit conventions
cat .claude/CLAUDE.md 2>/dev/null | grep -A 20 -i "commit"
# 2. Stage changes
git add <files> # or: git add -A
# 3. Create commit (branch commit format)
git commit -m "type(scope): subject
Body explaining HOW and WHY.
Reference: Task X.Y, Req N"type(scope): subject| Type | Purpose |
|---|---|
| New feature or functionality |
| Bug fix or issue resolution |
| Code refactoring without behavior change |
| Performance improvements |
| Test additions or modifications |
| CI/CD configuration changes |
| Documentation updates |
| Maintenance, dependencies, tooling |
| Code formatting, linting (non-functional) |
| Security vulnerability fixes or hardening |
validationauthcookie-servicetemplateconfigtestsapicat .claude/CLAUDE.md 2>/dev/null | grep -A 30 -i "commit"
cat .kiro/steering/*.md 2>/dev/null | grep -A 20 -i "commit"git status
git diff --staged # if already staged
git diff # if not stagedgit add <specific-files> # preferred
# or
git add -A # all changes.envcredentials.jsonnode_modules/__pycache__/.venv/git commit -m "fix(auth): use hmac.compare_digest for secure comparison"git commit -m "$(cat <<'EOF'
feat(validation): add URLValidator with domain whitelist
Implement URLValidator class supporting:
- Domain whitelist enforcement (youtube.com, youtu.be)
- Dangerous scheme blocking (javascript, data, file)
- URL parsing with embedded credentials handling
Addresses Requirement 31: Input validation
Part of Task 5.1: Input Validation Utilities
EOF
)"git log -1 --format="%h %s"
git show --stat HEAD<blank line>
Explain HOW and WHY the change was made.
- Use bullet points for multiple items
- Wrap at 72 characters
Reference: Task X.Y
Addresses: Req N| Trailer | Purpose |
|---|---|
| Links and closes issue on merge |
| Same as Fixes |
| Credit co-contributors |
references/commit_examples.md!BREAKING CHANGE:feat(api)!: change response format to JSON:API
BREAKING CHANGE: Response envelope changed from `{ data }` to `{ data: { type, id, attributes } }`.gh pr create --title "feat(security): implement input validation (Task 5)" --body "$(cat <<'EOF'
## Summary
- Input validation utilities (URLValidator, FormatValidator)
- Secure template processor with path traversal prevention
- API key authentication middleware
## Task Breakdown
Task 5.1: Input Validation - URLValidator, FormatValidator
Task 5.2: Template Processing - Path traversal prevention
Task 5.3: API Key Auth - Multi-key support, excluded paths
Task 5.4: Security Tests - 102 path traversal tests
## Requirements Covered
Req 7, Req 9, Req 31, Req 33
## Test Coverage
- All 473 tests passing
- Coverage: 93%
- Pre-commit checks: passing
EOF
)"git commit -m "fix(scope): address review comment #ID
Brief explanation of what was wrong and how it's fixed.
Addresses review comment #123456789."feat(validation): add URLValidator with domain whitelist
fix(auth): use hmac.compare_digest for secure key comparison
refactor(template): consolidate filename sanitization logic
test(security): add 102 path traversal prevention testsupdate validation code # no type, no scope, vague
feat: add stuff # missing scope, too vague
fix(auth): fix bug # circular, not specific
chore: make changes # missing scope, vague
feat(security): improve things. # has period, vaguereferences/commit_examples.md