Skip to content

feat(settings): auto-check-for-updates toggle on every host (#58 slice) - #65

Merged
turinglambdaai merged 2 commits into
mainfrom
feat/auto-check-toggle
Oct 23, 2026
Merged

turinglambdaai merged 2 commits into
mainfrom
feat/auto-check-toggle

Conversation

@turinglambdaai

Copy link
Copy Markdown
Owner

Refs #58. Third confirmed Raycast-study slice (更新行为显性化).

What

Settings menu gains a checkable Automatically Check for Updates on all three hosts (config auto-check-updates, default on):

  • silent launch + 4-hour checks skip when off; the manual Check for Updates… item always runs (UPDATE.md contract updated; DATA-FORMAT §7 lists the key);
  • macOS: Settings-menu Toggle → AppModel.autoCheckUpdates, bootstrap reads before the silent check;
  • Windows: ToggleMenuFlyoutItem → member + RunSilentUpdateCheck gate, loaded via the backend get_setting RPC on backend-up;
  • Linux: stateful win.auto-check-updates Gio action (popover renders the checkmark), gate in on_update_auto_check, synced when startup settings land.

Backend contract

set_setting whitelists the key ("0"/"1") and the config writer's key list now carries it — the writer's hardcoded list was silently dropping unknown-but-whitelisted keys; pinned by a backend-test round-trip case.

Verification

  • Backend tests: 14 passed (new round-trip + validation cases).
  • macOS leg live: menu toggle renders ✓-state, click-off writes auto-check-updates = 0 to config.ini, RPC dispatch visible in diagnostics; raco rivet build clean.
  • Windows/Linux compile + packaged acceptance: CI.

The silent launch + 4-hour update checks were invisible to the user;
the Raycast study called that out (updates behavior belongs in the
open). PRODUCT-SPEC §8's Settings menu gains a checkable
Automatically Check for Updates item (config `auto-check-updates`,
default "1"): silent checks skip when off, the manual Check for
Updates… item always runs and ignores the throttle too.

- macOS: Settings-menu Toggle bound to AppModel.autoCheckUpdates;
  bootstrap reads the setting before the silent check; persists via
  set_setting.
- Windows: ToggleMenuFlyoutItem + auto_check_updates_ member, loaded
  over the backend get_setting RPC when the backend comes up, gated at
  the top of RunSilentUpdateCheck, persisted via SaveSettingAsync.
- Linux: stateful win.auto-check-updates Gio action (popover menus
  render the checkmark), gate at the top of on_update_auto_check,
  persisted through save_setting, initial state synced when the
  startup get_settings lands.

Backend: set_setting's grammar whitelists the key ("0"/"1") and — the
actual persistence bug this slice caught — the config writer's key
list now carries it too; set_setting round-trips are pinned by a
backend-test case. UPDATE.md documents the toggle; DATA-FORMAT §7
lists the key.
The two appended functions landed after the
winrt::RivetHost::implementation closing brace, where MainWindow is
just a name — CI caught the scope error.
@turinglambdaai
turinglambdaai merged commit 757e7e9 into main Oct 23, 2026
12 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.

1 participant