Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Releasing

Releases are cut from GitHub Actions; nothing needs to run locally.

Cutting a release

main only takes changes through pull requests, so a release is two of them.

  1. The release pull request is always open while there's something to release. Every push to main that adds a feat, fix or perf commit since the last tag (yours or a contributor's) rebuilds chore(release): vX.Y.Z on the release/next branch from the new main: the version in Cargo.toml and Cargo.lock, and CHANGELOG.md. Its description shows the release notes.
    • git-cliff works out the version from the Conventional Commits since the last tag. In 0.x, a feat or a breaking change (fix!:, feat!:) bumps the minor version and a fix the patch version; 1.0 is set by hand. docs, test, ci and chore commits don't open one.
    • Each update replaces the branch, so fix the notes through cliff.toml on main (for example a { sha = "…", skip = true } parser for a commit to leave out), not by editing the pull request.
  2. Merge the pull request when you want to release. That's the release: the push to main builds, smoke-tests, tags and publishes it.
  3. The publish job then opens and merges a second pull request, chore(release): update the AUR, Nix and OBS packages for vX.Y.Z, which points the packages at the new tarball. It merges as the riptide GitHub App (on the "Protect main" ruleset's bypass list) only if the pull request changes nothing outside packaging/ and its AUR and Nix checksums are the released tarball's; otherwise it fails and leaves the pull request for you.

Actions → release → Run workflow on main does step 1 on demand:

  • With Dry run ticked (the default), it builds and tests everything, then keeps the packages and release notes as a release-dry-run artifact for a day, without pushing or publishing. Do this before merging a release with packaging changes.
  • With Version set, such as 0.3.0 or 0.3.0-rc.1 (anything with a - is published as a pre-release), and Dry run unticked, it sets the release pull request to that version. The next push to main goes back to the worked-out version, so merge it first.

If Actions isn't allowed to create pull requests (Settings → Actions → General → Allow GitHub Actions to create and approve pull requests), the run's summary has a link to open each one instead. Pull requests opened by the workflow don't trigger CI; the release build runs the smoke tests after the merge anyway.

.github/workflows/release.yml:

JobDoes
planFrom Actions: prepares the release pull request, or for a dry run, the version to build. On every push to main: releases the commit if Cargo.toml's version has no tag yet (a merged release pull request). Otherwise it updates the release pull request, or closes it if nothing since the last tag would be in the changelog.
buildRuns build-release.yml on the release commit (below).
publishWrites SHA256SUMS, records build provenance for every package, and creates the GitHub release, which tags the commit, with that version's section of the changelog. Then scripts/update-packages.sh points the AUR, Nix and OBS packages at the new release, in a pull request that it then merges, tells the openSUSE Build Service to rebuild, and asks the Homebrew tap to update its cask. Pre-releases leave the packages alone, and a dry run only prints the change.

Because a new version in Cargo.toml is what triggers a release, change it only through the release pull request.

Notifications

scripts/notify.sh sends a push notification through ntfy.sh to the topic in the NTFY_TOPIC secret, with the access token in NTFY_ACCESS_TOKEN; subscribe to that topic in the ntfy app. It notifies when:

  • the release pull request opens or its version changes (not on every commit added to it), and when a release is published;
  • cef-update opens a CEF upgrade or a lag issue, and cef-automerge merges one or leaves it for review;
  • the release, aur, cef update or cef automerge workflow fails, or the checks on a CEF upgrade do (notify.yml).

Running Actions → notify → Run workflow sends a test notification. Without the secrets nothing is sent, and a failed send never fails a job. The topic isn't reserved (ntfy.sh's free plan can't), so keep its name long, random and secret.

What gets built

build-release.yml is shared by releases and nightlies:

  • Linux (x86_64 and aarch64): cargo build --release in an ubuntu:22.04 container, on GitHub's ubuntu-24.04 and ubuntu-24.04-arm runners, then scripts/package-linux.sh packs the stripped binary and CEF runtime into riptide-<version>-linux-<arch>.tar.gz, an AppImage, riptide_<version>_<amd64|arm64>.deb and riptide-<version>-1.<arch>.rpm. The .rpm requires a font (dejavu-fonts on openSUSE, font(dejavusans) elsewhere), because minimal openSUSE installs have none and Chromium aborts without one. Each architecture uses CEF's own build for it (linux64 or linuxarm64), which ./task setup picks from the host. For each architecture, the whole smoke test then runs on an Ubuntu 24.04 runner against the unpacked tarball, the extracted AppImage, and the .deb installed with apt (with its setuid sandbox). It runs again against the packages installed in ubuntu:22.04, debian:12, fedora:44 and opensuse/tumbleweed containers with their own package managers, so a broken package never ships. The containers are privileged, since the setuid chrome-sandbox needs to make namespaces, and the test runs as a user because Chromium won't sandbox root. ./task package, ./task appimage, ./task deb and ./task rpm build the same files locally.
    • The build runs on Ubuntu 22.04, not the runner's 24.04, so the binary needs glibc 2.35 at most. A build on 24.04 needs glibc 2.38 or later (C23's __isoc23_strtol).
    • The .deb's Depends: comes from dpkg-shlibdeps, so it names the libraries of the distribution it's built on. 22.04's names (libasound2) are still provided by the t64 packages of Ubuntu 24.04 and Debian 13 (libasound2t64), so one .deb suits Ubuntu 22.04+ and Debian 12+.
    • The .rpm is built from the same files with rpmbuild from Ubuntu's rpm package. Its requirements are found from the binaries' sonames (libnss3.so()(64bit)), which every RPM distribution names the same way. The bundled libcef.so, libvulkan.so.1 and libvk_swiftshader.so are neither required nor provided, so the package never stands in for the system's Vulkan loader.
  • macOS and Windows: scripts/package-macos-windows.sh builds riptide.app with scripts/bundle-macos.sh and packs it in a .dmg (macOS, on an Apple silicon and an Intel runner), or packs the binary with CEF's runtime files (Windows, .zip). The CEF is CEF_PATH's, or else the download in the build directory that scripts/cef-dir.sh finds for the version Cargo.lock pins, since a restored build cache can also hold older versions. The app holds the framework and five helper apps under Contents/Frameworks, which run riptide-helper (riptide's renderer code without the browser's, a fifth of the size) and is signed ad hoc (Apple silicon runs only signed code); the release build mounts the .dmg, verifies the signatures and runs --version. Notarizing it needs an Apple Developer account. On Windows it also builds an installer with Inno Setup from packaging/windows/riptide.iss, which the release build installs, starts with --version and uninstalls. Both start (CI checks it); the maintainer uses the Apple silicon build day to day and tries each release's .dmg by hand, and the Intel and Windows builds are untested by hand. If either fails to build, the release goes ahead without it, since the free macOS runners are sometimes unavailable.

Nightly builds

.github/workflows/nightly.yml runs at 07:00 UTC. If main changed since the last nightly, it builds it the same way and replaces the rolling nightly pre-release, with files named riptide-nightly-<date>-<commit>-…. Debian versions must start with a digit, so the .deb inside says <crate version>+nightly<date>.<commit> (for example 0.3.0+nightly20261020.c7c2679). That sorts after the last release and before the next one. RPM versions can't hold a hyphen either, so the .rpm keeps the crate version and puts the nightly in its release: 0.3.0-1.nightly20261020.c7c2679. Running it by hand builds even if nothing changed. It never becomes the "latest" release.

Verifying a download

Every published package has a SHA256SUMS entry and a signed build provenance attestation that ties it to the workflow run and commit that built it:

sha256sum -c SHA256SUMS --ignore-missing
gh attestation verify riptide-0.2.0-linux-x86_64.tar.gz --repo joshzcold/riptide

After a release

Packages:

  • The AUR PKGBUILDs (packaging/aur/<package>/) and the Nix package (packaging/nix/package.nix, used by the root flake.nix) are updated by the publish job's pull request. If that step fails, run scripts/update-packages.sh X.Y.Z riptide-X.Y.Z-linux-x86_64.tar.gz with the released tarball and open a pull request with the result.
  • The openSUSE Build Service builds the apt, dnf and zypper repositories in home:joshzcold/riptide from packaging/obs/, which repackages the release tarballs without compiling anything:
    • The OBS package holds only packaging/obs/_service, uploaded by hand. When the publish job calls OBS's trigger API with the OPENSUSE_BUILD_SERVICE_TOKEN secret (a service token limited to that package), obs_scm takes packaging/obs/ from main, which by then has the new version, and download_files fetches the tarballs riptide.spec names.
    • riptide.spec builds the RPMs for x86_64 and aarch64, choosing the tarball by architecture. On openSUSE chrome-sandbox isn't setuid, because openSUSE only allows setuid files its permissions packages list, so the sandbox there relies on user namespaces. riptide-rpmlintrc lets openSUSE's rpmlint accept the $ORIGIN runpath and /opt.
    • riptide.dsc and the debian.* files build the .debs. OBS turns the .dsc's one tarball into the source package, so Debian and Ubuntu get amd64 only; arm64 would need a second OBS package.
    • The build targets (distribution versions) are set in the OBS project's Repositories tab, not in this repository.
    • The package must not use OBS's git sync (scmsync in its settings): that replaces its files with this repository's top level, which has no spec, so every target shows as excluded.
  • Merging that pull request publishes both to the AUR (aur.yml): riptide-browser-bin, from the release tarball, and riptide-browser, built from the release tag against the CEF build its Cargo.lock pins (update-packages.sh looks up that build's checksum in the CEF index). It checks the sources' checksums, builds riptide-browser (a package that doesn't build isn't published), writes .SRCINFO and pushes over SSH with the RIPTIDE_AUR_SSH_PRIVATE_KEY secret, whose public half (RIPTIDE_AUR_SSH_PUBLIC_KEY) is on the maintainer's AUR account. Run it by hand (a dry run by default) to check the key or to publish again.
  • The Homebrew cask (Casks/riptide.rb in joshzcold/homebrew-riptide) is rewritten by that repository's update workflow from the latest release's macOS disk images and SHA256SUMS. The publish job starts it as the riptide GitHub App, which needs access to the tap; without it, or if that fails, the workflow's six-hourly run catches up.
  • To check the Nix packages, run nix build .#riptide (the release tarball) or nix build .#riptide-source (built from the checkout), then BIN=result/bin/riptide scripts/smoke-test.sh. riptide-source needs no update at a release; it reads the version and dependencies from the checkout.

In the browser:

In the browser, :changelog shows the changelog it was built with, and the first start after an update says so in the status bar (and opens it, as changelog_after_upgrade decides). The documentation site isn't tied to releases: it's rebuilt from main on every push.