Mobile App — Git Branching SOP
TL;DR
| Branch | Created from | Targets | Version bump |
|---|---|---|---|
feature/* | dev | dev | — |
release/x.y.0 | dev | main | Minor: 1.3.x → 1.4.0 |
patch/x.y.z | Last release tag | main | Patch: 1.5.0 → 1.5.1 |
mainanddevare protected — no direct pushes, PRs only.- Android and iOS use the same
X.Y.Zversion name but independent build numbers.
Branch Structure
main
└── dev ← active development (merged weekly into main)
├── feature/* → targets dev
├── release/* → targets main
└── patch/* → targets main
Release Flow
- Cut
release/x.y.0fromdev - Bump minor version automatically (e.g.
1.3.1→1.4.0) - Raise fix/feature PRs targeting the
releasebranch - On finalisation:
- Create tag (e.g.
v34-1.2.0) - Merge
release→main
- Create tag (e.g.
Major version bumps are done manually.
Patch Flow
- Cut
patch/x.y.zfrom the last release tag - Bump patch version automatically (e.g.
1.5.0→1.5.1) - Raise fix PRs targeting the
patchbranch - On finalisation:
- Create tag (e.g.
v45-1.5.2) - Merge
patch→main
- Create tag (e.g.
Versioning — Android & iOS
Both platforms use the same X.Y.Z version name format.
| Field | Android | iOS |
|---|---|---|
| Version name | versionName | CFBundleShortVersionString |
| Build number | versionCode | CFBundleVersion |
- Build numbers are independent unique integers per platform — not synced.
- Platforms may release at different cadences; version names can diverge over time.
Branch Protection
All rules apply to main, dev, and release/*:
| Rule |
|---|
| Require PR before merging |
| Require at least 1 approving review |
| Dismiss stale reviews on new push |
| Require CI status checks to pass |
| Disallow direct pushes (including admins) |
| Restrict branch deletion |