Moved from wayBetter for X (distribution.rs + desktop_store.rs) so every wayBetter app gets the Store; the app keeps its Tauri command wrappers and a `StoreConfig`. - store::catalog (pure): `StoreConfig` (app id in the shared catalog, product, user agent, link scheme, store URL, public keys, allowed hosts), `AllowedHost` (raw-files-only rule for a code host; DEFAULT_HOSTS = waybetter.fyi, cdn1.crt.fyi, git.crt.fyi raw), install-link parsing, download allow-list, theme validation, catalog format 2: every item names its `apps`; the whole catalog is verified (Ed25519 over the exact bytes with any listed key, so keys rotate; strict schema; ids/files unique per app) and each app gets only its own items (another app's item is shape-checked but not held to this app's hosts); per-item sha256/size, install records, versions. - store::install: `Store` (pending links, staged installs with TTL/bound, MIN_REVIEW before a commit, commit writes exactly the staged bytes after re-validation via PluginStore::install, plugin remove, records file, verified catalog + offline copy verified again when read back, StoreView). Plugin start/stop scripts run through a function the app passes. - store::net (`net` feature): no-redirect, no-cookie reqwest fetch with caps; stage_link, stage_item, catalog(refresh). - Tests: links, per-app allow-lists and schemes, themes, signatures incl. tampering and key rotation, multi-app filtering, bad items, staging/commit/remove/records/offline copy on disk, fetch refuses anything off the allow-list. test:rust and check:tauri build with `net`.
32 lines
1.4 KiB
JSON
32 lines
1.4 KiB
JSON
{
|
|
"name": "waybetter",
|
|
"version": "0.1.0",
|
|
"private": true,
|
|
"license": "GPL-3.0-or-later",
|
|
"type": "module",
|
|
"description": "wayBetter: a framework for desktop apps that extend one website in place (tabs, splits, accounts, plugins, themes).",
|
|
"packageManager": "bun@1.4.2",
|
|
"workspaces": [
|
|
"packages/*"
|
|
],
|
|
"scripts": {
|
|
"typecheck": "tsc -p tsconfig.json && tsc -p packages/create-waybetter/tsconfig.json",
|
|
"test": "bun run test:ts && bun run test:rust && bun run test:create",
|
|
"test:ts": "node --test packages/runtime/tests/*.test.ts packages/shell/tests/*.test.ts",
|
|
"test:create": "node --test packages/create-waybetter/tests/*.test.mjs",
|
|
"test:rust": "cargo test --manifest-path crates/waybetter-host/Cargo.toml --locked --features net",
|
|
"check:tauri": "cargo check --manifest-path crates/waybetter-host/Cargo.toml --features tauri,net",
|
|
"build": "bun run typecheck && cargo build --manifest-path crates/waybetter-host/Cargo.toml --locked",
|
|
"build:packages": "cd packages/waybetter && npm run build",
|
|
"pack:check": "bun run build:packages && npm pack ./packages/waybetter --dry-run && npm pack ./packages/create-waybetter --dry-run",
|
|
"check": "bun run typecheck && bun run build:packages && bun run test"
|
|
},
|
|
"devDependencies": {
|
|
"@types/node": "^24.0.0",
|
|
"typescript": "^5.9.0"
|
|
},
|
|
"engines": {
|
|
"node": ">=24.0.0",
|
|
"bun": ">=1.4.2"
|
|
}
|
|
}
|