Releases are semi-automated via GitHub Actions. When a PR with the release and a version bump label is merged to main, the release workflow is triggered. You can also trigger the Release workflow manually from GitHub Actions and choose the bump type.
You'll need an approval from a PostHog engineer. If you're an employee, you can see the request in the #approvals-client-libraries channel.
- Either:
- Create your PR with the changes you want to release, add the
releaselabel, add exactly one version bump label (bump-patch,bump-minor, orbump-major), and merge the PR tomain, or - open the
Releaseworkflow in GitHub Actions, click Run workflow, and choosepatch,minor, ormajor
- Create your PR with the changes you want to release, add the
Once the workflow is triggered, the following happens automatically:
- A Slack notification is sent to the client libraries channel requesting approval
- A maintainer approves the release in the GitHub
Releaseenvironment - The version is bumped in
lib/PostHog.phpandcomposer.jsonbased on the version label (patch,minor, ormajor, extracted from the label) - The
CHANGELOG.mdis updated with a link to the full changelog - Changes are committed and pushed to
main - A git tag is created (e.g.,
v1.8.0) - A GitHub release is created with the changelog content
- Slack is notified of the successful release
Releases are installed directly from GitHub.