Skip to content
This repository was archived by the owner on Sep 29, 2025. It is now read-only.

Commit 7597272

Browse files
authored
Merge pull request #110 from bbc/philipn-document-release-process
Add a document describing the release process
2 parents 63978ec + 8db6421 commit 7597272

File tree

2 files changed

+77
-0
lines changed

2 files changed

+77
-0
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,8 @@ Source distributions, including dependencies, and binaries are made available in
244244

245245
Source and binary distributions are generally only created when a new feature is required for creating standard compliant sample files for example, or when a release hasn't been made for a long time.
246246

247+
The [release.md](./docs/release.md) document describes the release process.
248+
247249
### Conan
248250

249251
Additionally bmx (including MXF and MXF++) is available via the Conan package manager for C/C++: [bmx Conan recipe](https://conan.io/center/recipes/bmx). Conan Center Index offers precompiled packages for many target systems and otherwise allows to build locally according to a local conan build profile. Follow the code snippets and documentation on the linked page for integrating it.

docs/release.md

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
# Release Process
2+
3+
This describes the steps for making a release.
4+
5+
## Create a Release PR
6+
7+
* Create a branch that will contain changes for the release
8+
* Update the [CHANGELOG.md](../CHANGELOG.md) using the most recent version as a guide
9+
* Go through the PRs since the last release and add each PR and descriptive text to the `Breaking changes`, `Features`, `Bug fixes` or `Build changes` sections
10+
* Update the versions in the 3 main CMakeLists.txt files in the `project` blocks, where `VERSION` has the form `<major version>.<minor version>`
11+
* The files are [bmx CMakeLists.txt](../CMakeLists.txt), [libMXF CmakeLists.txt](../deps/libMXF/CMakeLists.txt) and [libMXFpp CmakeLists.txt](../deps/libMXFpp/CMakeLists.txt)
12+
* Run the [Build & Test](https://github.com/bbc/bmx/actions/workflows/build_and_test.yml) workflow in GitHub Actions using the release branch and fix any build errors and warnings
13+
* Check the [runner versions](https://docs.github.com/en/actions/using-github-hosted-runners/using-github-hosted-runners/about-github-hosted-runners) (e.g. `windows-2019` and `macos-13`) in the [release.yml](../.github/workflows/release.yml) workflow file are still available
14+
* Select the oldest macOS version available to help with compatibility
15+
* Run the [Release](https://github.com/bbc/bmx/actions/workflows/release.yml) workflow in GitHub Actions using the release branch to check it succeeds
16+
* Create and merge a PR for the release branch into `main`
17+
18+
## Create a Release Tag
19+
20+
* Checkout and fetch the `main` branch
21+
* Create a tag with form `v<major version>.<minor version>`. E.g. run the commands below, replacing `<major version>.<minor version>` (with no `v`)
22+
23+
```bash
24+
export BMX_VERSION=<major version>.<minor version>
25+
git checkout main
26+
git pull --rebase
27+
git tag -a v${BMX_VERSION} -m "Version ${BMX_VERSION}"`
28+
git push origin v${BMX_VERSION}
29+
```
30+
31+
## Create the Release Packages
32+
33+
* Run the [Release](https://github.com/bbc/bmx/actions/workflows/release.yml) workflow in GitHub Actions
34+
* Download the Artifacts and extract the individual source and binary zips for the release
35+
36+
## Create a GitHub Release
37+
38+
* Create a [new release](https://github.com/bbc/bmx/releases)
39+
* Copy the previous release's text as a starting point
40+
* Select the `v<major version>.<minor version>` tag
41+
* Change the CHANGELOG link
42+
* Update the zip filenames with the new version
43+
* Update the compiler versions used for the binaries
44+
* These can be found in the actions output in the `Win64 binary release` and `MacOS Universal binary release` build steps in the 2 jobs of the [Release](https://github.com/bbc/bmx/actions/workflows/release.yml) workflow in GitHub Actions
45+
* Upload the source and binary zips to the release
46+
47+
## Create a Docker Image for the GitHub Container Registry
48+
49+
* Acquire a Linux machine with Docker installed
50+
* Build the `bmxtools` image and tag using the commands below
51+
* `BMX_VERSION` should be set as before; note also the additional `.0` for the patch version.
52+
53+
```bash
54+
DOCKER_BUILDKIT=1 docker build -t bmxtools .
55+
docker tag bmxtools ghcr.io/bbc/bmxtools:${BMX_VERSION}.0
56+
docker tag bmxtools ghcr.io/bbc/bmxtools:latest
57+
```
58+
59+
* In your [GitHub settings](https://github.com/settings/tokens) to create tokens
60+
* Select "Generate New Token" and "Generate new token (classic)"
61+
* Change "Expiration" to 7 days
62+
* Select "write:packages" (which will select "read:packages" and all of "repo")
63+
* Select "Generate Token"
64+
* Copy the token which you'll need to pass in when logging into the GitHub Docker registry
65+
* Login into GHCR and push the image using the commands below
66+
* Replace `<username>` with your GitHub username
67+
* Pass in the token when docker login requests it
68+
* `BMX_VERSION` should be set as before; note also the additional `.0` for the patch version
69+
70+
```bash
71+
docker login ghcr.io --username <username>
72+
docker push ghcr.io/bbc/bmxtools:${BMX_VERSION}.0
73+
docker push ghcr.io/bbc/bmxtools:latest
74+
docker logout ghcr.io
75+
```

0 commit comments

Comments
 (0)