Skip to content

Updater: release builds check their channel and update themselves - #389

Merged
ItsAlphaNeon merged 7 commits into
mainfrom
updater
Nov 9, 2026
Merged

ItsAlphaNeon merged 7 commits into
mainfrom
updater

Conversation

@ItsAlphaNeon

@ItsAlphaNeon ItsAlphaNeon commented Nov 7, 2026 •

Copy link
Copy Markdown
Owner

Merge order: this one, then #370, then #393. Merging publishes nothing: the schedule stays off until the repository variable NIGHTLIES is on, and a run by hand refuses to start without the signing key.

What this adds

Builds made by the new release workflow update themselves on their own channel. Builds from source have no channel and never update.

  • tools/updater, lemonstudio-updater. It checks the channel's manifest, verifies its minisign signature, downloads the build and checks its SHA-256. Once Lemon Studio closes, it replaces the Windows .exe, the Linux AppImage ($APPIMAGE) or the macOS .app, then starts the new version. The app carries it inside itself (build.rs, LEMON_UPDATER) and writes it to <user folder>/Updates/<channel> to run it. HTTPS uses rustls with ring and the system's certificate store.
  • Versions (version.rs): nightlies use dated versions (YEAR.MONTH.DAY.N) and tagged releases use MAJOR.MINOR.PATCH. The two are never compared, and the updater never moves to an older version. The version shown everywhere follows the build: the app, diagnostics, the panic log, the "saved by" stamp and the Windows version resource.
  • Alphas: a tag with major version 0, like v0.1.0, is an alpha. alpha is not in the tag. The app, the diagnostics and the release's title say "alpha", where nightlies and builds from source say "pre-alpha". An alpha isn't a GitHub pre-release, because the updater finds it as GitHub's latest release, and it updates on to v1.0.0 like any newer version.
  • In the app (update.rs):
    • a check at start
    • an Install and restart / Skip this version / Later prompt, which waits until no dialog is open and nothing is recording
    • HELP ▸ Check for updates
    • the two General ▸ Updates checks, previously greyed out, now work
    • the About tab shows the channel and has a Check for updates button
    • OPENSTUDIO_NO_UPDATE_CHECK=1 turns off the check at start, and OPENSTUDIO_UPDATE_BASE points it at a test server
  • release.yml:
    • a nightly from main every night once turned on, skipped if main hasn't moved, keeping the newest 14
    • a tagged release from a vMAJOR.MINOR.PATCH tag that is on main and matches Cargo.toml
    • a dry run (Run workflow): builds, packages and signs, then keeps the files as the run's artifacts. It can rehearse a tag as well as a nightly
    • assets: LemonStudio.exe, LemonStudio.AppImage (built on Ubuntu 22.04), macOS .app (Apple silicon, signed ad hoc, not notarized; the release notes say how to open it), and the VST3/CLAP plugins as a zip per platform. The .exe and AppImage have no version in their names, and a nightly's are LemonStudioNightly: an update replaces the file in place, so shortcuts to it never break
  • Docs: docs/releasing.md, with the going-live steps in order, plus updates to the README, the alpha checklist and the regenerated THIRD-PARTY-NOTICES.txt.

After merging

The steps are under "Going live" in docs/releasing.md:

  • Repository secret MINISIGN_SECRET_KEY and variable MINISIGN_PUBLIC_KEY set
  • Dry runs of a nightly and a tag, and each platform's build opened
  • First nightly published, and NIGHTLIES set to on
  • Each platform updates itself once
  • For the first alpha: version in Cargo.toml set (it is still 0.0.1) and merged, then the tag pushed

Testing

  • cargo test --workspace on Windows, with Nightly builds: their own name, icon and splash (Moonrise) #370 and HELP menu: opens the website, and About works #393 merged in: 2523 passed, 0 failed.
  • tools/package/test.sh, which CI now runs: the release plan against a throwaway repository (nightly numbering, no nightly when main hasn't moved, a tag not matching Cargo.toml, off main or with alpha in it refused, rehearsals), and the manifest.
  • In a throwaway workflow, since deleted: actionlint on both workflows, and cargo check of the app and updater on Ubuntu 22.04.
  • From before this round, on Windows against a local server with a signed test manifest: a 2026.11.6.1 build checked at start, downloaded 2026.11.7.1 and showed the prompt, Skip this version was saved, the updater replaced lemonstudio.exe and relaunched it, and a tampered manifest was refused. Not repeated since the update folders became per channel.

Not run: the Release workflow itself, by request, so the AppImage and .app of a real build, and the Linux and macOS update and swap code outside CI's tests, are still untried. The tag path's releases/latest lookup can't be tried until a tagged release exists.

🤖 Generated with Claude Code

ItsAlphaNeon and others added 2 commits November 7, 2026 16:48
Nightly and stable builds made by the new release workflow carry
lemonstudio-updater (tools/updater), which checks the channel's signed
manifest, downloads the newer build and, once Lemon Studio closes,
replaces the .exe, the AppImage or the .app and starts it again.
Builds from source have no channel and never update.

- Versions: nightlies are dated (YEAR.MONTH.DAY.N), stable releases
  semantic; the app, diagnostics, panic log and the Windows version
  resource show the build's version (version.rs).
- In the app (update.rs): the check at start, the Install and restart /
  Skip this version / Later prompt, HELP > Check for updates, the
  General > Updates checks, and the About tab's channel line and
  Check for updates button.
- Release workflow: a nightly from main every night (if main moved),
  a stable release from a vMAJOR.MINOR.PATCH tag; Windows .exe, Linux
  AppImage, macOS .app (Apple silicon, not notarized: the release notes
  say how to open it) and the VST3/CLAP plugins as a zip per platform.
  Manifests are signed with minisign (MINISIGN_SECRET_KEY secret,
  MINISIGN_PUBLIC_KEY variable).
- docs/releasing.md, README, alpha checklist, third-party notices.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ItsAlphaNeon and others added 3 commits November 8, 2026 16:18
The schedule only runs with the repository variable NIGHTLIES set to "on", so
merging the workflow with the signing keys set publishes nothing by itself.

Run workflow gains a dry run: it builds, packages and signs, and keeps the files
as the run's artifacts. It can rehearse a tag as well as a nightly.

An alpha is a plain vMAJOR.MINOR.PATCH tag with major version 0. Builds say so
in the app, the diagnostics and the release's title, instead of "pre-alpha".

Also: a tag has to be on main; the first build on a channel doesn't list every
pull request ever merged; appimagetool is a fixed version with its checksum; a
nightly and an alpha on one computer keep their downloads in separate folders.
The plan moves to tools/package/plan.sh, tested with the manifest by
tools/package/test.sh in CI, and CI checks a nightly's and a tagged build's
settings compile.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
docs/releasing.md has the steps in order, from the signing key to the first
nightly, and says an alpha is a tag with major version 0. The README no longer
says no prebuilt binaries will be published.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ItsAlphaNeon and others added 2 commits November 8, 2026 17:16
LemonStudio.exe and LemonStudio.AppImage, and LemonStudioNightly for a nightly, so
a nightly and a tagged release can sit in one folder. An update replaces the file
in place, keeping its name, so a version in it went stale after the first update.
Now a shortcut never points at a misleading name, and never has to change.

The macOS zip keeps its version: it's only unpacked, and the app inside has a
fixed name already.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ItsAlphaNeon
ItsAlphaNeon marked this pull request as ready for review November 9, 2026 00:53
@ItsAlphaNeon
ItsAlphaNeon merged commit 03b28d3 into main Nov 9, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant