πΏ Git Workflow β
Version control practices for clean history and smooth collaboration.
Branching strategy β
GitHub Flow (recommended for most teams) β
main βββββββββββββββββββββββββββββββΊ
βββ feature/add-auth βββΊ PR βββΊ merge
βββ fix/login-bug βββΊ PR βββΊ mergeGit Flow (for versioned releases) β
main βββββββββββββββββββββββββββββΊ
develop βββββββββββββββββββββββββββΊ
βββ feature/x βββΊ merge to develop
βββ release/1.0 βββΊ merge to main + tagBranch naming β
feature/short-description
fix/bug-description
chore/task-description
refactor/what-changed
docs/what-documentedCommit messages β
Conventional Commits format β
type(scope): description
feat(auth): add JWT refresh token support
fix(api): handle null response from payment provider
docs(readme): update installation instructions
refactor(db): extract query builder into separate module
test(auth): add unit tests for token validationTypes β
feat, fix, docs, style, refactor, test, chore, perf, ci
PR workflow β
- Create a branch from
main - Make small, focused commits
- Push and open a PR with clear description
- Request review from 1-2 team members
- Address feedback, push updates
- Squash merge (or merge commit per team convention)
- Delete the branch after merge
Best practices β
- Commit often, push regularly
- Never commit directly to
main - Rebase feature branches on
mainbefore merging - Write meaningful commit messages (not "fix stuff")
- Don't commit secrets, env files, or build artifacts
- Use
.gitignoreproperly