Skip to content

Disable electron-updater self-updater in flatpak - #47

Open
develop7 wants to merge 1 commit into
flathub:masterfrom
develop7:push-ykylltxyzxkr
Open

Disable electron-updater self-updater in flatpak#47
develop7 wants to merge 1 commit into
flathub:masterfrom
develop7:push-ykylltxyzxkr

Conversation

@develop7

Copy link
Copy Markdown
Collaborator

The desktop app's auto-updater (electron-updater + GitHub provider) is gated on UPDATER_ENABLED = app.isPackaged && CHANNEL !== dev, which is true inside a flatpak. It polls GitHub every 10 min, auto-downloads the .deb into the sandbox, and then fails to install (read-only /app).

Patch app.asar in place (same-byte-length text replacement, so the asar layout and app.asar.unpacked entries are preserved) to set UPDATER_ENABLED = false. Updates come through the OS updater (GNOME Software / KDE Discover / flatpak update) instead.

Upstream issue for a permanent fix: anomalyco/opencode#39670

@flathubbot

Copy link
Copy Markdown
Contributor

🚧 Test build enqueued.

@flathubbot

Copy link
Copy Markdown
Contributor

🚧 Started test build.

@flathubbot

Copy link
Copy Markdown
Contributor

Test build succeeded. To test this build, install it from the testing repository:

flatpak install --user https://dl.flathub.org/build-repo/307169/ai.opencode.opencode.flatpakref

Built for aarch64 and x86_64 architectures.

@develop7
develop7 marked this pull request as ready for review August 1, 2026 13:22
@develop7
develop7 requested a review from NN708 August 1, 2026 13:22
@develop7

develop7 commented Aug 1, 2026

Copy link
Copy Markdown
Collaborator Author

Verified "check updates" button is disabled:

image

@NN708 NN708 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM

The desktop app's auto-updater (electron-updater + GitHub provider) is
gated on UPDATER_ENABLED = app.isPackaged && CHANNEL !== dev, which
is true inside a flatpak. It polls GitHub every 10 min, auto-downloads
the .deb into the sandbox, and then fails to install (read-only /app).

Patch app.asar in place (same-byte-length text replacement, so the
asar layout and app.asar.unpacked entries are preserved) to set
UPDATER_ENABLED = false. Updates come through the OS updater (GNOME
Software / KDE Discover / flatpak update) instead.

Upstream issue for a permanent fix: anomalyco/opencode#39670
@develop7
develop7 force-pushed the push-ykylltxyzxkr branch from be39432 to bb3fa67 Compare August 2, 2026 13:52
@flathubbot

Copy link
Copy Markdown
Contributor

🚧 Test build enqueued.

@flathubbot

Copy link
Copy Markdown
Contributor

🚧 Started test build.

@flathubbot

Copy link
Copy Markdown
Contributor

Test build succeeded. To test this build, install it from the testing repository:

flatpak install --user https://dl.flathub.org/build-repo/307578/ai.opencode.opencode.flatpakref

Built for aarch64 and x86_64 architectures.

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.

[FEATURE]: Flatpak integration — gate auto-updater on FLATPAK_ID + use Flatpak UpdateMonitor portal

3 participants