fix(update): enable allowPrerelease on the nightly channel (#2265)
Nightly builds publish as GitHub prereleases. configureFeed set channel and allowDowngrade but never allowPrerelease, which defaults to false, so electron-updater only inspected the latest NON-prerelease release (e.g. v0.10.0) and 404d looking for nightly-mac.yml there. The nightly channel therefore never resolved, regardless of whether a nightly was published. Set allowPrerelease = (channel === nightly): nightly scans prereleases and finds the nightly feed; stable stays on non-prereleases only. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
parent
965e388792
commit
6b56b1c245
|
|
@ -17,6 +17,11 @@ import {
|
|||
// checkForUpdates.
|
||||
function configureFeed(channel: UpdateChannel): void {
|
||||
autoUpdater.channel = channel; // "latest" | "nightly"
|
||||
// Nightly builds ship as GitHub *prereleases*. With allowPrerelease false
|
||||
// (the default) electron-updater only inspects the latest NON-prerelease
|
||||
// release and looks for nightly-mac.yml there, which 404s. Enable prerelease
|
||||
// scanning on the nightly channel only; stable must never pull prereleases.
|
||||
autoUpdater.allowPrerelease = channel === "nightly";
|
||||
autoUpdater.allowDowngrade = true; // permits a nightly -> stable channel switch
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue