Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 20 additions & 3 deletions .github/workflows/beta-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,27 @@ jobs:
git tag "$TAG"
git push origin "$TAG"

# The `-beta.N` suffix is what makes electron-builder emit beta.yml
# rather than latest.yml — the whole isolation guarantee rests on it.
# The channel must be named explicitly. electron-builder takes its output
# channel from publish.channel (default "latest") and does NOT derive it
# from the version's prerelease tag — even though electron-updater derives
# its *read* channel exactly that way. Without this the build writes
# latest.yml, no beta feed is ever produced, and beta installs have
# nothing to update from. (v3.8.1-beta.1 shipped that way.)
- name: Build the Windows installer
run: npx electron-builder --win --publish never
run: npx electron-builder --win --publish never -c.publish.channel=beta

# The upload action only *warns* on a glob that matches nothing, so the
# first beta published as a green run with no update feed at all. A
# release missing its channel file is broken — fail loudly instead.
- name: Verify the beta update feed was generated
shell: bash
run: |
if [ ! -f dist/beta.yml ]; then
echo "::error::dist/beta.yml was not generated — beta installs would have no update feed."
echo "dist/ contains:"; ls -la dist/
exit 1
fi
echo "beta.yml:"; cat dist/beta.yml

- name: Publish the prerelease
uses: softprops/action-gh-release@v3
Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,19 @@ jobs:
- name: Build the Windows installer
run: npx electron-builder --win --publish never

# The upload action only warns on a glob that matches nothing, so a
# release missing latest.yml would publish as a green run and silently
# strand every existing install on its current version. Fail loudly.
- name: Verify the update feed was generated
shell: bash
run: |
if [ ! -f dist/latest.yml ]; then
echo "::error::dist/latest.yml was not generated — existing installs would never see this release."
echo "dist/ contains:"; ls -la dist/
exit 1
fi
echo "latest.yml:"; cat dist/latest.yml

# The install header stays ABOVE the generated notes (the API
# prepends `body`); the "What's Changed" changelog below it is
# shaped by .github/release.yml.
Expand Down
7 changes: 7 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,13 @@ the last beta. Leaving the channel is deliberate: Settings → App → *Which bu
to* → **Stable only** (`app.updateChannel`), which is also the only path allowed to step the
version down.

> The beta build must pass `-c.publish.channel=beta` to electron-builder. Its output channel
> comes from `publish.channel` (default `latest`) and is **not** derived from the version's
> prerelease tag — even though electron-updater derives its *read* channel exactly that way.
> Both workflows assert their channel file exists before publishing, because the upload
> action only warns on a glob that matches nothing: `v3.8.1-beta.1` shipped as a green run
> with no update feed at all.

> Beta tags are excluded wherever the next stable version is computed. They sort *above*
> the release they precede, and `3.8.0-beta.1` split on `.` puts `0-beta.1` where a number
> belongs — which is a fatal arithmetic error, not a wrong answer. Keep the
Expand Down