Skip to main content

Module updater

Module updater 

Source
Expand description

Service-side update channel.

Checks GitHub Releases for newer service binaries and applies updates atomically to ~/.spool/bin/. Independent from the GUI version — users can update the service without reinstalling the desktop app.

§Update flow

  1. Fetch latest release metadata from GitHub Releases API
  2. Compare against BootstrapState.service.version
  3. If newer, download the platform-specific tarball
  4. Verify SHA256 (when checksum file present)
  5. Extract to ~/.spool/bin.new/
  6. Atomic rename: bin/bin.old/, bin.new/bin/
  7. Update version.json

§Concurrency

Uses blocking reqwest::blocking since updates are rare and the user triggers them manually from the settings page. Avoids needing a tokio runtime in the GUI process.

Structs§

UpdateApplyReport
Result of an apply-update call.
UpdateCheckReport
Result of a check-for-updates call.

Functions§

apply_update
Download and apply the latest update atomically.
check_for_update
Check GitHub for a newer service version. Pure read — no filesystem changes.