CLI runs on Node 20+: npx storebound (bunx keeps working)
- cli/lib/rt.ts: the runtime layer on node: modules (spawn / spawnSync with Bun's defaults, exit codes and "Executable not found", which with PATHEXT, sleep, serve, Glob, hasher, gunzip, stdin, SQLite, packageRoot, config imports with a type-stripping fallback for Node 20); every Bun.* use in cli/ goes through it - tools/gen-embedded.ts -> cli/lib/embedded.ts: templates/, cli/shots/*.html and Play's Data safety form embedded (replaces Bun text imports; the bundle and the compiled sidecar carry them), checked fresh by bun run ci - package.json: bin dist/storebound.mjs (Node ESM bundle, tools/build-node.ts, prepack), engines node >=20 - bun run ci: node bundle + node smoke (real node: --version, help, check same as Bun, scan, release plan --help, init, MCP handshake + tool call); Forgejo CI sets up Node 20; tests/node-compat.test.ts guards cli/ - install writes npx MCP commands when run with Node; bin/storebound falls back to Node - docs: npx storebound init (Node 20+) or bunx storebound init
This commit is contained in:
parent
614c32bcba
commit
36a8bf9625
73 changed files with 1195 additions and 251 deletions
|
|
@ -9,7 +9,7 @@
|
|||
// App content > Data safety > Export to CSV with nothing answered, saved over that file unchanged (docs/pitfalls.md 21).
|
||||
import type { AccountsConfig, DataSafety, PlayPurpose } from './config';
|
||||
import { csvCell, parseCsv } from './csv';
|
||||
import FORM_TEXT from '../data/play-data-safety-form.csv' with { type: 'text' };
|
||||
import { PLAY_DATA_SAFETY_FORM as FORM_TEXT } from './embedded';
|
||||
|
||||
export { csvCell };
|
||||
|
||||
|
|
@ -25,7 +25,7 @@ const pairKey = (q: string, r: string) => `${q}\u0000${r}`;
|
|||
export function playForm(): Map<string, PlayFormRow> {
|
||||
if (formCache) return formCache;
|
||||
const m = new Map<string, PlayFormRow>();
|
||||
for (const r of parseCsv(FORM_TEXT as unknown as string).slice(1)) {
|
||||
for (const r of parseCsv(FORM_TEXT).slice(1)) {
|
||||
const [question = '', response = '', , requirement = '', label = ''] = r;
|
||||
m.set(pairKey(question, response), { question, response, requirement, label: label.trim() });
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue