Welcome to the official commit convention guide for UnifiedBits!
We follow the Conventional Commits specification to ensure clarity, traceability, and automation in our development process.
- 🧠 Clear project history
- 🚀 Easy changelog generation
- 🤖 Enables automation (versioning, deployments)
- 🤝 Improves team collaboration and onboarding
A commit message must be structured as follows:
<type>(optional scope): <short summary>
[optional body]
[optional footer]
feat(auth): add login with OTP support
This introduces OTP-based authentication using Twilio.
Also updates the user model to include phone verification.
Fixes #24
Type | Description |
---|---|
feat |
A new feature |
fix |
A bug fix |
docs |
Documentation only changes |
style |
Code style changes (formatting, missing semicolons, etc.) |
refactor |
Code change that neither fixes a bug nor adds a feature |
perf |
Performance improvements |
test |
Adding or updating tests |
chore |
Maintenance tasks (configs, deps, CI/CD) |
Use scopes to specify which part of the codebase is affected.
Example: feat(api)
, fix(ui)
, docs(readme)
Scope Examples |
---|
auth |
ui |
api |
core |
docs |
deps |
- ✅ Use the imperative mood: "fix bug" not "fixed bug"
- ✅ Keep subject line under 72 characters
- ✅ Use body to explain why, not just what
- ✅ Separate the subject, body, and footer with blank lines
- ✅ Reference issues or PRs in the footer (e.g.,
Fixes #12
)
Here are realistic examples categorized by type:
feat(auth): add login with OTP support
feat(dashboard): implement user analytics charts
feat(api): add endpoint for bulk file processing
fix(ui): resolve button misalignment on mobile view
fix(api): correct 500 error on invalid input
fix(auth): prevent token from expiring prematurely
docs(readme): update installation instructions
docs(api): add usage examples to user routes
docs(contributing): explain branching strategy
style(ui): unify font sizes across components
style(css): apply consistent padding and margins
style(auth): fix lint warnings and spacing issues
refactor(core): extract utility functions from controller
refactor(api): simplify query logic in search route
refactor(auth): remove unused middleware
perf(api): optimize DB query for loading dashboard
perf(ui): lazy load images for faster initial load
test(api): add test cases for file upload
test(auth): increase test coverage for login flow
test(ui): snapshot tests for new components
chore(ci): add GitHub Actions workflow for testing
chore(deps): upgrade dependencies to latest versions
chore(project): rename folders for clarity
- 🛡️ Commitlint – Lint commit messages
- 🤖 Commitizen – Generate commits via CLI prompts
- 📦 Semantic Release – Automate changelog and versioning
Following a convention for commit messages ensures every contributor understands the codebase history clearly, automates release processes, and scales the team with confidence.
“Quality is never an accident; it is always the result of intelligent effort.” – John Ruskin
Happy committing! 🚀
— Team UnifiedBits