This repo follows Git Flow with automated releases.
| Branch | Purpose | Protected |
|---|---|---|
main |
Production. Only release merges land here; every commit is a released version. | yes |
develop |
Integration branch (the default). All features merge here. | yes |
feature/* |
New work. Branch off develop, PR back into develop. |
: |
hotfix/* |
Urgent production fix. Branch off main, PR into main, then back-merge to develop. |
: |
release/* |
Optional. A stabilization branch off develop before a release (not required: see Releases). |
: |
feature/x ─┐
feature/y ─┼─▶ develop ─────▶ main ─▶ (Release + npm publish)
hotfix/z ──────────────────▶ main ─┘ └─▶ back-merge to develop
- Branch off
develop:git switch develop && git pull git switch -c feature/my-thing - Commit using Conventional Commits (
feat:,fix:,perf:,docs:,chore:,test:,ci:,refactor:): this drives the changelog and version. - Open a PR into
develop. CI (lint+test, incl. the native ASan/UBSan fuzz) must pass before merge. - Hotfixes branch off
main, PR intomain, and are back-merged intodevelop.
Releases are cut from main by release-please:
- When
developis ready, open a PRdevelop → mainand merge it. - release-please opens a "release" PR on
mainthat bumps the version and updatesCHANGELOG.mdfrom the Conventional Commits. Review and merge it. - Merging tags a GitHub Release, which triggers
release.ymlto run the test suite and publish@klaappinc/react-native-nitro-protobufto npm.
(A manual release/* branch is an alternative if you need to stabilize before
merging to main, but it is not required: release-please handles versioning.)
bun install
bun run test # unit + native fuzz (when protoc/nanopb/clang present)
bun run lint-ci # eslint
bun run format:check # prettier
bun run ios # run the example app