Skip to content

feat: in-app update checks and one-click install - #16

Merged
dialupdisaster merged 1 commit into
mainfrom
feat/updater-ui
Sep 11, 2026
Merged

dialupdisaster merged 1 commit into
mainfrom
feat/updater-ui

Conversation

@dialupdisaster

Copy link
Copy Markdown
Contributor

Summary

The updater plugin, signing key and update.json manifest were all in place, but nothing in the frontend ever called check() — so the "you'll see a notification in the app" promise was never true. This wires up the last mile.

What's included

  • updaterStore (src/lib/stores/updater.svelte.ts) — wraps check / downloadAndInstall / relaunch; exposes status, download progress, release notes. Background checks run 15s after launch and every 6h and are silent: only an available update changes the UI, so offline/private-cluster setups never see errors.
  • Settings → Updates card — current version, last checked, Check for updates automatically toggle (new autoCheckUpdates setting, default on), release notes, progress bar, Install & Restart.
  • Sidebar badge — green dot on the Settings icon while an update is pending.
  • updater_can_self_update (Rust) — Linux .deb/.rpm installs can't replace themselves; they get a link to Releases instead of an install button (detected via the APPIMAGE env var Tauri's updater itself uses).
  • Capability tightened from updater:default to updater:allow-check, updater:allow-download-and-install, plus process:allow-restart.
  • examples/updater_probe.rs — downloads and signature-verifies the latest release against the real manifest without installing anything.

Verification

  • With the app version temporarily set to 0.3.9, the running app's background check returned update available 0.3.9 -> 0.4.0 from the live gh-pages manifest.
  • cargo run --example updater_probe downloaded Kore_aarch64.app.tar.gz (5.5 MB) and the minisign signature verified against the embedded pubkey.
  • svelte-check, 11 unit, 85 E2E, 41 screenshot, 88 Rust tests, strict clippy — all green.

Caveats

  • macOS builds are ad-hoc signed (signingIdentity: "-"), so the replaced .app may hit the same Gatekeeper "Open Anyway" prompt as a fresh install. Notarization would fix that but needs an Apple Developer account.

The updater plugin, signing key and manifest were all wired up but
nothing in the frontend ever called check(), so the "you'll see a
notification" promise in the docs was never true.

- updaterStore wraps check / downloadAndInstall / relaunch with
  idle/checking/available/downloading/ready/error states and download
  progress. Background checks (15s after launch, then every 6h) are
  silent; only an available update changes the UI.
- Settings > Updates card: current version, last checked, "Check for
  updates automatically" toggle (new autoCheckUpdates setting, default
  on), release notes, progress bar, Install & Restart.
- Green dot on the sidebar Settings icon while an update is pending.
- updater_can_self_update (Rust) reports whether the install can replace
  itself; Linux .deb/.rpm get a link to Releases instead of a button.
- Tighten the desktop capability to updater:allow-check,
  updater:allow-download-and-install and process:allow-restart.
- examples/updater_probe.rs downloads and signature-verifies the latest
  release against the real manifest; verified against v0.4.0.
@github-actions

Copy link
Copy Markdown
Contributor

Rust Security Scan

  • cargo audit: PASS
  • cargo deny (advisories): PASS
  • cargo clippy security lints: PASS
cargo audit (tail)
�[0m�[0m�[1m�[32m    Fetching�[0m advisory database from `https://github.com/RustSec/advisory-db.git`
�[0m�[0m�[1m�[32m      Loaded�[0m 1243 security advisories (from /home/runner/.cargo/advisory-db)
�[0m�[0m�[1m�[32m    Updating�[0m crates.io index
�[0m�[0m�[1m�[32m    Scanning�[0m Cargo.lock for vulnerabilities (666 crate dependencies)
�[0m�[0m�[1m�[33mCrate:    �[0m paste
�[0m�[0m�[1m�[33mVersion:  �[0m 1.0.15
�[0m�[0m�[1m�[33mWarning:  �[0m unmaintained
�[0m�[0m�[1m�[33mTitle:    �[0m paste - no longer maintained
�[0m�[0m�[1m�[33mDate:     �[0m 2024-10-07
�[0m�[0m�[1m�[33mID:       �[0m RUSTSEC-2024-0436
�[0m�[0m�[1m�[33mURL:      �[0m https://rustsec.org/advisories/RUSTSEC-2024-0436

�[0m�[0m�[1m�[33mCrate:    �[0m proc-macro-error
�[0m�[0m�[1m�[33mVersion:  �[0m 1.0.4
�[0m�[0m�[1m�[33mWarning:  �[0m unmaintained
�[0m�[0m�[1m�[33mTitle:    �[0m proc-macro-error is unmaintained
�[0m�[0m�[1m�[33mDate:     �[0m 2024-09-01
�[0m�[0m�[1m�[33mID:       �[0m RUSTSEC-2024-0370
�[0m�[0m�[1m�[33mURL:      �[0m https://rustsec.org/advisories/RUSTSEC-2024-0370

�[0m�[0m�[1m�[33mCrate:    �[0m unic-char-property
�[0m�[0m�[1m�[33mVersion:  �[0m 0.9.0
�[0m�[0m�[1m�[33mWarning:  �[0m unmaintained
�[0m�[0m�[1m�[33mTitle:    �[0m `unic-char-property` is unmaintained
�[0m�[0m�[1m�[33mDate:     �[0m 2025-10-18
�[0m�[0m�[1m�[33mID:       �[0m RUSTSEC-2025-0081
�[0m�[0m�[1m�[33mURL:      �[0m https://rustsec.org/advisories/RUSTSEC-2025-0081

�[0m�[0m�[1m�[33mCrate:    �[0m unic-char-range
�[0m�[0m�[1m�[33mVersion:  �[0m 0.9.0
�[0m�[0m�[1m�[33mWarning:  �[0m unmaintained
�[0m�[0m�[1m�[33mTitle:    �[0m `unic-char-range` is unmaintained
�[0m�[0m�[1m�[33mDate:     �[0m 2025-10-18
�[0m�[0m�[1m�[33mID:       �[0m RUSTSEC-2025-0075
�[0m�[0m�[1m�[33mURL:      �[0m https://rustsec.org/advisories/RUSTSEC-2025-0075

�[0m�[0m�[1m�[33mCrate:    �[0m unic-common
�[0m�[0m�[1m�[33mVersion:  �[0m 0.9.0
�[0m�[0m�[1m�[33mWarning:  �[0m unmaintained
�[0m�[0m�[1m�[33mTitle:    �[0m `unic-common` is unmaintained
�[0m�[0m�[1m�[33mDate:     �[0m 2025-10-18
�[0m�[0m�[1m�[33mID:       �[0m RUSTSEC-2025-0080
�[0m�[0m�[1m�[33mURL:      �[0m https://rustsec.org/advisories/RUSTSEC-2025-0080

�[0m�[0m�[1m�[33mwarning:�[0m 5 allowed warnings found

cargo deny (tail)
━━━━━━━━━�[0m �[0m�[33mno crate matched advisory criteria�[0m

�[0m�[1m�[38;5;11mwarning[advisory-not-detected]�[0m�[1m: advisory was not encountered�[0m
   �[0m�[36m┌─�[0m /home/runner/work/kore/kore/src-tauri/deny.toml:33:6
   �[0m�[36m│�[0m
�[0m�[36m33�[0m �[0m�[36m│�[0m     "�[0m�[33mRUSTSEC-2024-0414�[0m",  # gtk-sys
   �[0m�[36m│�[0m      �[0m�[33m━━━━━━━━━━━━━━━━━�[0m �[0m�[33mno crate matched advisory criteria�[0m

�[0m�[1m�[38;5;11mwarning[advisory-not-detected]�[0m�[1m: advisory was not encountered�[0m
   �[0m�[36m┌─�[0m /home/runner/work/kore/kore/src-tauri/deny.toml:34:6
   �[0m�[36m│�[0m
�[0m�[36m34�[0m �[0m�[36m│�[0m     "�[0m�[33mRUSTSEC-2024-0415�[0m",  # gtk3-macros
   �[0m�[36m│�[0m      �[0m�[33m━━━━━━━━━━━━━━━━━�[0m �[0m�[33mno crate matched advisory criteria�[0m

�[0m�[1m�[38;5;11mwarning[advisory-not-detected]�[0m�[1m: advisory was not encountered�[0m
   �[0m�[36m┌─�[0m /home/runner/work/kore/kore/src-tauri/deny.toml:26:6
   �[0m�[36m│�[0m
�[0m�[36m26�[0m �[0m�[36m│�[0m     "�[0m�[33mRUSTSEC-2024-0416�[0m",  # atk-sys
   �[0m�[36m│�[0m      �[0m�[33m━━━━━━━━━━━━━━━━━�[0m �[0m�[33mno crate matched advisory criteria�[0m

�[0m�[1m�[38;5;11mwarning[advisory-not-detected]�[0m�[1m: advisory was not encountered�[0m
   �[0m�[36m┌─�[0m /home/runner/work/kore/kore/src-tauri/deny.toml:31:6
   �[0m�[36m│�[0m
�[0m�[36m31�[0m �[0m�[36m│�[0m     "�[0m�[33mRUSTSEC-2024-0417�[0m",  # gdkx11-sys
   �[0m�[36m│�[0m      �[0m�[33m━━━━━━━━━━━━━━━━━�[0m �[0m�[33mno crate matched advisory criteria�[0m

�[0m�[1m�[38;5;11mwarning[advisory-not-detected]�[0m�[1m: advisory was not encountered�[0m
   �[0m�[36m┌─�[0m /home/runner/work/kore/kore/src-tauri/deny.toml:28:6
   �[0m�[36m│�[0m
�[0m�[36m28�[0m �[0m�[36m│�[0m     "�[0m�[33mRUSTSEC-2024-0418�[0m",  # gdk-sys
   �[0m�[36m│�[0m      �[0m�[33m━━━━━━━━━━━━━━━━━�[0m �[0m�[33mno crate matched advisory criteria�[0m

�[0m�[1m�[38;5;11mwarning[advisory-not-detected]�[0m�[1m: advisory was not encountered�[0m
   �[0m�[36m┌─�[0m /home/runner/work/kore/kore/src-tauri/deny.toml:29:6
   �[0m�[36m│�[0m
�[0m�[36m29�[0m �[0m�[36m│�[0m     "�[0m�[33mRUSTSEC-2024-0419�[0m",  # gdkwayland-sys
   �[0m�[36m│�[0m      �[0m�[33m━━━━━━━━━━━━━━━━━�[0m �[0m�[33mno crate matched advisory criteria�[0m

�[0m�[1m�[38;5;11mwarning[advisory-not-detected]�[0m�[1m: advisory was not encountered�[0m
   �[0m�[36m┌─�[0m /home/runner/work/kore/kore/src-tauri/deny.toml:30:6
   �[0m�[36m│�[0m
�[0m�[36m30�[0m �[0m�[36m│�[0m     "�[0m�[33mRUSTSEC-2024-0420�[0m",  # gdkx11
   �[0m�[36m│�[0m      �[0m�[33m━━━━━━━━━━━━━━━━━�[0m �[0m�[33mno crate matched advisory criteria�[0m

�[0m�[1m�[38;5;11mwarning[advisory-not-detected]�[0m�[1m: advisory was not encountered�[0m
   �[0m�[36m┌─�[0m /home/runner/work/kore/kore/src-tauri/deny.toml:13:6
   �[0m�[36m│�[0m
�[0m�[36m13�[0m �[0m�[36m│�[0m     "�[0m�[33mRUSTSEC-2024-0429�[0m",
   �[0m�[36m│�[0m      �[0m�[33m━━━━━━━━━━━━━━━━━�[0m �[0m�[33mno crate matched advisory criteria�[0m

advisories �[32mok�[0m

cargo clippy (tail)
�[1m�[92m   Compiling�[0m tauri-plugin-process v2.3.1
�[1m�[92m   Compiling�[0m kore v0.4.0 (/home/runner/work/kore/kore/src-tauri)
�[1m�[92m    Finished�[0m `dev` profile [unoptimized + debuginfo] target(s) in 20.91s

@dialupdisaster
dialupdisaster merged commit e9c9f46 into main Sep 11, 2026
23 checks passed
@dialupdisaster
dialupdisaster deleted the feat/updater-ui branch September 11, 2026 04:17
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