From ai-dev-team
Create well-structured git commits with meaningful messages that maintain a clean, traceable project history.
npx claudepluginhub marcel-Ngan/ai-dev-team --plugin ai-dev-teamThis skill uses the workspace's default tool permissions.
Create well-structured git commits with meaningful messages that maintain a clean, traceable project history.
Provides Ktor server patterns for routing DSL, plugins (auth, CORS, serialization), Koin DI, WebSockets, services, and testApplication testing.
Conducts multi-source web research with firecrawl and exa MCPs: searches, scrapes pages, synthesizes cited reports. For deep dives, competitive analysis, tech evaluations, or due diligence.
Provides demand forecasting, safety stock optimization, replenishment planning, and promotional lift estimation for multi-location retailers managing 300-800 SKUs.
Create well-structured git commits with meaningful messages that maintain a clean, traceable project history.
git CLI commandsgh CLI (GitHub CLI){
"owner": "{{github.owner}}",
"repo": "{{github.repo}}",
"defaultBranch": "{{github.defaultBranch}}"
}
<type>(<scope>): <subject>
<body>
<footer>
| Type | Description | Example |
|---|---|---|
feat | New feature | feat(auth): add password reset |
fix | Bug fix | fix(api): handle null response |
docs | Documentation | docs: update API readme |
style | Formatting | style: fix indentation |
refactor | Code restructure | refactor(db): simplify queries |
test | Adding tests | test: add auth unit tests |
chore | Maintenance | chore: update dependencies |
perf | Performance | perf(query): add index |
ci | CI/CD changes | ci: add lint workflow |
build | Build system | build: upgrade webpack |
revert | Revert commit | revert: feat(auth)... |
feat(auth): authentication module
feat(api/users): users API endpoint
fix(ui/button): button component
docs(readme): README file
## Good Commit Messages
✅ feat(auth): add JWT token refresh endpoint
✅ fix(cart): prevent negative quantities in cart
✅ docs(api): document rate limiting behavior
✅ refactor(user-service): extract validation logic
## Bad Commit Messages
❌ fixed stuff
❌ WIP
❌ updates
❌ feat: changes to the authentication system including login logout and password reset functionality
# Check status
git status
# Stage specific files
git add path/to/file.ts
# Stage all changes
git add .
# Stage interactively
git add -p
# Commit with message
git commit -m "feat(scope): add feature"
# Commit with body
git commit -m "feat(scope): add feature" -m "Detailed description of the changes."
# Amend last commit (unpushed only)
git commit --amend -m "feat(scope): corrected message"
# Amend without changing message
git commit --amend --no-edit
# View commit log
git log --oneline -10
# View with graph
git log --oneline --graph --all
# View specific file history
git log --oneline -- path/to/file.ts
# View commit details
git show <commit-hash>
# View diff between commits
git diff <commit1> <commit2>
# Undo last commit (keep changes staged)
git reset --soft HEAD~1
# Undo last commit (keep changes unstaged)
git reset HEAD~1
# Undo last commit (discard changes) - DANGEROUS
git reset --hard HEAD~1
# Revert a pushed commit (creates new commit)
git revert <commit-hash>
# Cherry-pick commit from another branch
git cherry-pick <commit-hash>
feat({{scope}}): {{brief description}}
- Add {{functionality}}
- Implement {{behavior}}
- Update {{related component}}
Closes #{{issueNumber}}
fix({{scope}}): {{brief description}}
**Problem:**
{{description of the bug}}
**Solution:**
{{how it was fixed}}
Fixes #{{issueNumber}}
feat({{scope}})!: {{brief description}}
BREAKING CHANGE: {{description of breaking change}}
**Migration:**
{{steps to migrate}}
Closes #{{issueNumber}}
| Principle | Description |
|---|---|
| Single Purpose | One logical change per commit |
| Complete | Commit should not break the build |
| Self-Contained | Can be understood in isolation |
| Testable | Changes can be verified |
## Feature: User Authentication
Instead of one large commit:
❌ "feat: add user authentication"
Break into atomic commits:
✅ "feat(auth): add user model and migration"
✅ "feat(auth): implement password hashing utility"
✅ "feat(auth): add login endpoint"
✅ "feat(auth): add logout endpoint"
✅ "test(auth): add authentication unit tests"
✅ "docs(auth): document auth API endpoints"
# Reference in commit message
git commit -m "feat(auth): add login endpoint
Implements MDDEV-123"
# Reference with action
git commit -m "fix(cart): handle empty cart
Fixes MDDEV-456"
# Multiple references
git commit -m "refactor(api): consolidate endpoints
Related to MDDEV-100, MDDEV-101"
# Transition issue
git commit -m "MDDEV-123 #done feat(auth): complete login"
# Log time
git commit -m "MDDEV-123 #time 2h feat(auth): implement login"
# Add comment
git commit -m "MDDEV-123 #comment Code complete, ready for review"
#!/bin/sh
# .git/hooks/pre-commit
# Run linter
npm run lint
# Run tests
npm test
# Check commit message format
# (use commitlint for this)
// commitlint.config.js
module.exports = {
extends: ['@commitlint/config-conventional'],
rules: {
'scope-enum': [2, 'always', ['auth', 'api', 'ui', 'db', 'ci']],
'subject-case': [2, 'always', 'lower-case'],
'body-max-line-length': [2, 'always', 100],
},
};
✅ Write in imperative mood ("Add feature" not "Added feature")
✅ Keep subject line under 50 characters
✅ Wrap body at 72 characters
✅ Explain what and why, not how
✅ Reference relevant issues/tickets
✅ Make commits atomic and focused
✅ Test before committing
❌ Commit broken code
❌ Mix unrelated changes
❌ Write vague messages ("fix bug", "update")
❌ Include generated files (build output, node_modules)
❌ Commit secrets or credentials
❌ Use --force without understanding impact
❌ Amend published commits
| Error | Cause | Resolution |
|---|---|---|
| Pre-commit hook failed | Lint/test errors | Fix issues, try again |
| Nothing to commit | No staged changes | git add files first |
| Detached HEAD | Not on a branch | git checkout <branch> |
| Merge conflict | Concurrent changes | Resolve conflicts, commit |