Skip to content

fix(release): restore desktop app-update.yml and keep V1 as the GitHub Latest release - #59529

Merged
Hona merged 1 commit into
anomalyco:devfrom
Hona:release-blockers
Oct 27, 2026
Merged

Hona merged 1 commit into
anomalyco:devfrom
Hona:release-blockers

Conversation

@Hona

@Hona Hona commented Oct 27, 2026 •

Copy link
Copy Markdown
Member

Two release blockers from the new release pipeline (#59046), found before the first stable run.

Desktop builds lose app-update.yml

pack.ts builds macOS and Windows with electron-builder --dir (the installer step uses --prepackaged). app-builder-lib only writes resources/app-update.yml for dmg/zip/nsis targets, and our updater (gui-plugins/src/updater/platform.ts) never calls setFeedURL, so it needs that file.

Build app-update.yml
Installed 2.1.4 (resources/) present
dev run 40455332094, build-desktop-darwin-arm64 missing
same run, build-desktop-windows-x64 missing

Anyone who updates to a build without it can never auto-update again.

pack.ts now writes the file into the app's resources before the tarball / unpacked copy, so it is signed with the app and the Windows installer step picks it up. Values come from the channel's publish config; for latest the output is byte-identical to the installed 2.1.4 file:

provider: generic
url: https://opencode.ai/update/api/latest/desktop/opencode/
channel: latest
updaterCacheDirName: '@opencodedesktop-updater'

V2 GitHub releases must not take Latest

publish-github-release.sh published the release without --latest=false, so v2.x would replace v1.19.4 as Latest. OpenCode 1's CLI upgrade (curl/yarn installs), electron-updater, Scoop and the GitHub Action all follow Latest, and the V2 release attaches CLI archives with the same opencode-<target>.zip names (see #54903).

-gh release create "$tag" --draft --verify-tag --title "$tag" --notes-file "$assets.md"
+gh release create "$tag" --draft --verify-tag --latest=false --title "$tag" --notes-file "$assets.md"
-gh release edit "$tag" --draft=false
+gh release edit "$tag" --draft=false --latest=false

Blocks v2.2.0.


Added by the opencode bot (AI-generated).

Related: #58105

@Hona
Hona requested review from a team and a balanced review from Copilot October 27, 2026 06:20
@Hona
Hona requested a review from Brendonovich as a code owner October 27, 2026 06:20

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@opencode-agent opencode-agent Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks correct to me. I checked writeUpdateConfig against app-builder-lib 26.15.7: its onAfterPack skips app-update.yml for --dir targets, and --prepackaged doesn't run afterPack, so the base really ships without the file. With this change the generated YAML is byte-identical to what electron-builder would write for the prod, beta and dev channels (same provider, url, channel and sanitised updaterCacheDirName; no publisherName, since verifyUpdateCodeSignature is false). tsc -b passes in packages/desktop. I couldn't run the macOS/Windows packaging or a real gh release here, so this is unverified end to end.

Public API: unchanged (release tooling only).

No blocking concerns.

Related: #58105

@Hona
Hona merged commit 54dcd34 into anomalyco:dev Oct 27, 2026
32 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.

2 participants