Releases and versions
A release is an annotated git tag named vMAJOR.MINOR.PATCH.
rmp deploy makes it after checking everything CI would check, pushes it, and CI
builds every enabled target from that commit and publishes them as one GitHub release. The tag is
also the only place the version lives: the version Android and iOS show, the Android version
code and the name of the release are all read from it.
A release is a tag#
rmp deploy 1.2.0That tags the commit you are on as v1.2.0 — the v is added when you
leave it out — and pushes the tag to origin. Nothing else is pushed: the commit has
to be on GitHub already, which is one of the things rmp deploy checks before it
tags anything. On success it prints:
== checking v1.2.0 the way CI will ==
ok v1.2.0 is release-ready
* [new tag] v1.2.0 -> v1.2.0
pushed v1.2.0. CI builds every target and attaches them to the release.
gh run watch
to undo, if you were quick enough:
git push --delete origin v1.2.0 && git tag -d v1.2.0The tag is annotated, with the message Release v1.2.0: a real git object with an
author and a date, which is what git describe and most release tooling expect. A
lightweight tag pushed by hand builds just the same; rmp deploy makes the annotated
kind.
The version comes from the tag#
There is deliberately no version key in raylib_multiplatform.toml.
The build reads the tag CI is building, and everything that carries a version gets it from
there:
| Tag | Version name | Android version code | GitHub release |
|---|---|---|---|
v1.2.3 | 1.2.3 | 1002003 | a release |
v1.2.3-rc1 | 1.2.3-rc1 | 1002003 | marked as a pre-release |
v1.2.3+7 | 1.2.3+7 | 1002003 | a release |
v0.9.0 | 0.9.0 | 9000 | a release |
v1.2 | refused: not vMAJOR.MINOR.PATCH | ||
v01.2.3 | refused: a leading zero, which would share the code of v1.2.3 | ||
v0.0.0 | refused: its code would be 0, and Android's is positive; the first release is v0.0.1 | ||
| no tag | 0.0.0-dev | 1 | none |
The version name is the Android versionName, the iOS MARKETING_VERSION,
and the version itch.io shows for the upload (there it keeps its v:
v1.2.3). Every build that is not a tag build, on your machine or on a push, is
0.0.0-dev with version code 1.
The tag has to be v, three numbers separated by dots, and optionally a
- or + suffix of letters, digits, dots and hyphens. Anything else that
starts with v is refused — there is no fallback, because a release named
0.0.0-dev would be worse than no release:
configure: error: tag 'v1.2' is not vMAJOR.MINOR.PATCH (optionally -rc1 / +build).
Releases take their version from the tag and there is no fallback that would not be a lie.
Delete the tag and re-tag: git tag -d v1.2 && git push origin :refs/tags/v1.2Pre-releases#
A hyphen in the tag marks the GitHub release as a pre-release: v1.2.0-rc1,
v1.2.0-beta.2. It is built and published like any other tag, and it is labelled so
nobody watching the repository mistakes a candidate for the real thing.
rmp deploy 1.2.0-rc1A + suffix is build metadata, not a pre-release: v1.2.0+7 is published
as a normal release.
The Android version code#
Google Play orders the builds of an app by an integer, the version code, and refuses an upload whose code is not higher than the last one it accepted. The framework packs the three numbers of the tag into that integer so that it rises whenever the version does:
versionCode = MAJOR * 1000000 + MINOR * 1000 + PATCHThat only works while MINOR and PATCH fit in three digits, so a tag
with either of them at 1000 or above is refused:
minor and patch must each stay below 1000 so the Android versionCode stays monotonic.
And Play refuses any code above 2100000000, so MAJOR stops at 2099:
major must stay at or below …. The highest version that fits is
v2099.999.999, code 2099999999.
Two things the arithmetic does not do for you:
- Nothing compares a tag with the previous one. The code rises only if your tags
do. Tag
v1.0.0afterv2.0.0and the build gets a lower code than the one Play already has, and Play refuses it. - A pre-release shares its version's code.
v1.2.3-rc1andv1.2.3are both1002003. Nothing uploads to Play automatically, so this costs nothing until you hand Play both: upload one of them, never the two.
What rmp deploy checks#
Each check catches a mistake that would otherwise surface on CI, and finding it twenty minutes
into a run, on a tag that is already public, is the expensive way. They run in this order, and
the first that fails stops rmp deploy before it tags anything:
Nothing uncommitted. CI builds the commit, so a change that is only in your working tree would not be in the release. Staged or not, a change to a tracked file stops it (files git does not track are not part of any commit, and do not count): FAIL: uncommitted changes. Commit or stash them first.
The tag is new here. FAIL: the tag v1.2.0 already exists here.
The tag is new on
origin. A version that has been pushed once is not cut again: FAIL: v1.2.0 is already on the remote. Releases are not re-cut; bump the version. Whenorigincannot be asked at all — no remote, no network — that stops it too, with what git said.Your branch is on
origin. CI checks the tag out from GitHub, so a tag on a commit that exists only on your machine builds nothing: FAIL: origin/main does not exist. Push the branch first:, followed byrmp push. The firstrmp pushof a branch with no upstream isgit push -u origin <branch>, which pushes it and ties it toorigin; with no remote at all, it stops and says how to add one.The commit is the one
originhas.HEADmust be exactly whatorigin/<branch>points at, as of your last fetch: FAIL: HEAD is not what origin/main points at (as of your last fetch). It suggestsrmp push, which pushes unlessghreports a CI run in flight.The configuration, the way CI will read it.
tools/configure.pyruns with the tag set the way CI sets it, so the whole.tomlis validated, the tag is parsed into a version name and code, and — in a game, not in the framework's own repository — the ids are checked for placeholders. That last check is what stops a first release from going out undercom.example.:== checking v1.2.0 the way CI will == configure: error: refusing to build a release with placeholder identifiers: [android] application_id is still the example value 'com.example.my_game' [ios] bundle_id is still the example value 'com.example.my-game' A Google Play application id is PERMANENT: once published you can never change it. Set real values in raylib_multiplatform.toml before tagging.An id is checked only when its platform is a target: with
iosswitched off in[targets], the iOS bundle id is not looked at.Tag and push.
git tag -a v1.2.0 -m "Release v1.2.0", thengit push origin v1.2.0.
Every refusal exits with status 1, and leaves no tag behind.
A tag pushed by hand#
Tagging with git directly skips the checks on your machine, not the ones on CI. In a game, the
first job of a tag run validates the configuration with the same placeholder check, and stops the
run if it fails. A tag that is not vMAJOR.MINOR.PATCH fails every job that builds,
at the step that generates its build files. Either way nothing is published, and the tag is left on GitHub to be
deleted — see Undoing a tag.
Only tags that start with v start a release run at all.
What CI does with a tag#
A tag runs the full matrix: every target [targets] enables, each built, checked and,
where CI can, booted (Continuous integration says what each one
gets). A push to the branch while a tag run is going does not cancel it: superseded branch runs
are cancelled, tag runs never are.
Then a release job collects what every target uploaded and publishes it. It runs
only when:
- the
lintjob passed — in a game, that is the workflows, the configuration, the pinned versions, the licences and a frame drawn in software; - and no platform job failed or was cancelled. A platform you switched off in
[targets]is skipped, and a skipped one does not hold the release back — otherwise turning a platform off would turn releases off with it.
In the framework's own repository the release also waits for the jobs only it has: its
examples, the game it makes with rmp new, and this documentation, checked against the
commit being released.
When the release is published, the itch.io job pushes the builds to itch.io, if it is configured. Firebase Test Lab, if configured, runs alongside and does not hold the release back.
What the release holds#
The release is named after the tag, its notes are generated by GitHub from what changed since the previous one, and these are its files. A target your game does not build has no file:
| File | What it is |
|---|---|
linux-x64-glibc-build.ziplinux-arm64-glibc-build.ziplinux-riscv64-glibc-build.ziplinux-x64-musl-build.ziplinux-x64-glibc-drm-build.ziplinux-arm64-glibc-drm-build.zip | Linux: the executable, its assets and LICENSES.txt. Desktop and BSD archives |
windows-x64-build.zipwindows-arm64-build.zip | Windows: the .exe, its assets and LICENSES.txt. |
macos-build.zip | macOS: one universal executable for Apple silicon and Intel, its assets and LICENSES.txt. |
bsd-freebsd-x86-64-build.zipbsd-freebsd-arm64-build.zipbsd-openbsd-x86-64-build.zipbsd-openbsd-arm64-build.zipbsd-netbsd-x86-64-build.zip | FreeBSD, OpenBSD and NetBSD, built in their own virtual machines. |
web-build.zip | The browser build. The web build |
the debug .apk | The Android debug build: installable on a phone, not what Play takes. It shows Google's test ads, whatever ids the .toml carries. |
the release .aab | The App Bundle signed with your upload key. Only there when the Android signing secrets are set. Google Play |
ios-raylib-xcframework.zip | The iOS engine, raylib.xcframework, for device and simulator. |
ios-app-simulator.zip | The game built for the iOS simulator: unsigned, and not installable on a device. The App Store |
THIRD_PARTY_LICENSES.md | Every vendored component, its licence, and whether the copy is modified. |
SHA256SUMS | The SHA-256 of every zip, APK and AAB above. |
One file never reaches a release: the App Bundle CI signs with a throwaway key when your
signing secrets are not set. It is uploaded to the run under its own artifact name,
android-unsigned-aab, with -NOT-FOR-PLAY in its file name. The release
job downloads every artifact of the run, that one included, and then leaves it out by name: it is
not in SHA256SUMS and not in the list of files the release attaches — so a bundle
Play would accept is the only kind a release can carry.
Checking a download#
SHA256SUMS lists every archive by its file name, as the release has it. With the
files downloaded next to it:
sha256sum -c SHA256SUMS # every file it lists
sha256sum -c --ignore-missing SHA256SUMS # only the ones you downloadedThe licence notices#
Every desktop and BSD archive carries LICENSES.txt beside the executable,
web-build.zip beside the page, the APK and the App Bundle among their assets, and the
iOS app in its bundle. Each is generated from the components block of
THIRD_PARTY_LICENSES.md for what that build contains: the full notice of every
component in it, with a line saying which copies are modified. So the web's notice names none of the
desktop-only pieces — GLFW, RGFW, glad, the Windows shims — that a .wasm does not
contain, and only the Android one credits raymob. It is the only third-party notice the game
ships, so turning it off needs a reason on record — where the credits are instead:
[deploy]
licenses = false raylib_multiplatform.toml:2: licenses = false
^^^^^^^^^^^^^^^^
configure: error: [deploy] licenses = false removes LICENSES.txt from every package, and it is the only third-party notice the game ships.
Say where the credits are instead: credits_note = "the Credits scene, from the main menu". If there is no such scene, leave licenses = true.[deploy]
licenses = false
credits_note = "the Credits scene, from the main menu"Undoing a tag#
Before CI has published anything — the run is still going, or it failed — the
tag can simply go, from GitHub and from your machine. It is what rmp deploy prints
when it pushes:
git push --delete origin v1.2.0 && git tag -d v1.2.0Deleting the tag does not stop a run that has already started, so cancel the run as well,
from its page or with gh run cancel.
After the release is published, deleting the tag leaves the release where it is. Delete both at once:
gh release delete v1.2.0 --cleanup-tagThen cut the next version rather than the same one again. rmp deploy refuses a
version that is still on origin, and anything you already uploaded to Google Play has
spent its version code for good.
A tag run that went red for a reason that was not yours — a BSD package mirror having a bad day is the usual one — does not need a new tag. Re-run the failed jobs of that run; the release job, which was skipped, is evaluated again with them:
gh run rerun <run-id> --failed