theseus/package.json
Local Dev cc563b0037 Theseus 0.0.4: cheap in-app update-check chip
Bumps version so the chip actually surfaces itself on 0.0.3 installs
(the version-newer check requires a strict semver bump — same-version
rebuilds don't trigger the chip). From this release on, whenever the
manifest names a newer Theseus, users get a one-click download.

Mechanism
- main.js checkForUpdate() fetches https://dl.silentmode.st/releases-
  manifest.json on startup (5s timeout, cache: no-store) + every 6h.
  Finds the theseus-navigator release, compares version to
  app.getVersion() with a numeric a.b.c comparator that handles
  "0.10.0 > 0.9.9" correctly.
- On a match → stores { version, setupUrl, portableUrl, setupHash,
  portableHash, date } and emits update-available to chrome. Cleared
  after the user upgrades + relaunches (same-version → null).
- Re-emits on chrome's did-finish-load in case the fetch beats the
  chrome view.

Chip UI (chrome.html)
- Acid-yellow pill between the downloads button and the Tor toggle:
  "↓ Update to X.Y.Z" + a ✕. Main body opens setupUrl in the system
  browser via shell.openExternal (origin-validated to
  https://dl.silentmode.st/ or https://silentmode.st/). ✕ dismisses
  for the current session — you'll see it again next launch if still
  behind.

Trust anchor
- No signing / no cryptographic verification of the download in this
  phase. releases.silentmode.bch publishes the SAME manifest URL, so
  users who want to verify can cross-check the manifest hash against
  what BCNR returns. The proper auto-updater with signature checks is
  the follow-on to this cheap version.

Non-goals in phase 1
- No delta downloads; the user clicks and gets a full installer.
- No auto-install; download → user runs the installer themselves.
- No "check now" button in Settings; the periodic timer suffices.
- No portable-vs-installed detection; the chip prefers setupUrl (the
  installer upgrades in place). Right-click for portable is future work.
2026-08-28 20:21:44 +02:00

76 lines
2.2 KiB
JSON

{
"name": "theseus-navigator",
"version": "0.0.4",
"description": "Theseus Navigator — a browser that follows the thread. By Silent Mode, a Deviant project.",
"author": "Silent Mode",
"main": "main.js",
"type": "commonjs",
"scripts": {
"start": "electron .",
"resolve-test": "node resolve-test.mjs",
"dist": "electron-builder --win nsis portable"
},
"dependencies": {
"fetch-socks": "^1.3.3",
"nostr-tools": "^2.10.4",
"socks-proxy-agent": "^10.1.0",
"ws": "^8.18.0"
},
"devDependencies": {
"electron": "^33.0.0",
"electron-builder": "^25.1.8"
},
"build": {
"appId": "st.silentmode.theseus",
"productName": "Theseus Navigator",
"artifactName": "TheseusNavigator-${version}-${arch}.${ext}",
"directories": { "output": "dist-public" },
"asar": true,
"files": [
"main.js",
"preload.js",
"chrome.html",
"home.html",
"settings.html",
"settings-preload.js",
"popover.html",
"popover-preload.js",
"engine-picker.html",
"engine-picker-preload.js",
"downloads.html",
"downloads-preload.js",
"address-picker.html",
"address-picker-preload.js",
"pw-fill.html",
"pw-fill-preload.js",
"home-preload.js",
"collision.html",
"collision-preload.js",
"messages.html",
"messages-preload.js",
"lib/**/*",
"package.json",
"node_modules/**/*",
"!**/*.md",
"!**/*.map",
"!tor${/*}",
"!dist-public${/*}",
"!resolve-test.mjs",
"!*PROMPT.md"
],
"extraResources": [
{ "from": "tor", "to": "tor" },
{ "from": "../Argus/src/lib/resolver-web.js", "to": "resolver-web.mjs" },
{ "from": "../Argus/src/lib/password-vault.js", "to": "password-vault.mjs" },
{ "from": "lib/hermes.js", "to": "lib/hermes.mjs" }
],
"win": { "target": ["nsis", "portable"] },
"nsis": {
"oneClick": false,
"perMachine": false,
"allowToChangeInstallationDirectory": true,
"artifactName": "TheseusNavigator-Setup-${version}.${ext}"
},
"portable": { "artifactName": "TheseusNavigator-${version}-portable.${ext}" }
}
}