Update channel preference (Stable/Beta) missing from General Settings
Problem
There is no user-facing toggle or picker to choose between the stable and beta Sparkle update channels. Phase 16 spec §12 requires a Stable/Beta channel preference. Currently there is no updates.betaChannel UserDefaults key, no UI to set it, and UpdateController.feedURLString(for:) (once Sparkle is added — see #205) won't know which channel to return.
Required changes
1. Register default
In BocanApp.registerDefaults():
"updates.betaChannel": false,
2. Add to General Settings
In Modules/UI/Sources/UI/Settings/GeneralSettingsView.swift, add a new section:
Section("Software Updates") {
Toggle(isOn: Binding(
get: { UserDefaults.standard.bool(forKey: "updates.betaChannel") },
set: { UserDefaults.standard.set($0, forKey: "updates.betaChannel") }
)) {
VStack(alignment: .leading, spacing: 2) {
Text("Receive beta updates")
Text("Opt in to early-access releases. Betas may have bugs.")
.font(.caption)
.foregroundStyle(.secondary)
}
}
.help("When enabled, Bòcan will offer beta (pre-release) versions in addition to stable releases.")
}
3. Wire in UpdateController
UpdateController.feedURLString(for:) (see #205) already reads UserDefaults.standard.bool(forKey: "updates.betaChannel"). No additional wiring needed once Sparkle is integrated.
4. Localization
Add the new strings to Modules/UI/Sources/UI/Resources/Localizable.xcstrings:
"Software Updates" (settings section header)
"Receive beta updates" (toggle label)
"Opt in to early-access releases. Betas may have bugs." (caption)
Acceptance criteria
Dependencies
Blocked by #205 (Sparkle not yet integrated).
Update channel preference (Stable/Beta) missing from General Settings
Problem
There is no user-facing toggle or picker to choose between the stable and beta Sparkle update channels. Phase 16 spec §12 requires a Stable/Beta channel preference. Currently there is no
updates.betaChannelUserDefaults key, no UI to set it, andUpdateController.feedURLString(for:)(once Sparkle is added — see #205) won't know which channel to return.Required changes
1. Register default
In
BocanApp.registerDefaults():2. Add to General Settings
In
Modules/UI/Sources/UI/Settings/GeneralSettingsView.swift, add a new section:3. Wire in
UpdateControllerUpdateController.feedURLString(for:)(see #205) already readsUserDefaults.standard.bool(forKey: "updates.betaChannel"). No additional wiring needed once Sparkle is integrated.4. Localization
Add the new strings to
Modules/UI/Sources/UI/Resources/Localizable.xcstrings:"Software Updates"(settings section header)"Receive beta updates"(toggle label)"Opt in to early-access releases. Betas may have bugs."(caption)Acceptance criteria
false)UpdateControllerto returnhttps://bocan.app/appcast-beta.xmlas the feed URLhttps://bocan.app/appcast.xml.help()modifierLocalizable.xcstringsDependencies
Blocked by #205 (Sparkle not yet integrated).