Files
openprose__prose/packages/reactor-cli/tsconfig.json
irl-dan 08f41ac3f2 feat(reactor-cli): Phase 0 — package skeleton, offline-safe entrypoint, doctor
Add @openprose/reactor-cli: a Commander-based CLI (reactor --help/--version)
with a `doctor` command and an offline-safe entrypoint.

- package.json: bin reactor -> dist/cli.js; @openprose/reactor as a peer;
  @openai/agents + zod as OPTIONAL peers (peerDependenciesMeta optional:true,
  not optionalDependencies). test:runtime mirrors the SDK's
  `node --test $(find dist -name '*.test.js' ...)` (node:test, not vitest).
- tsconfig + tsconfig.build.json mirror the SDK (CommonJS); build compiles
  tests so dist/**/*.test.js exists for the runtime suite.
- cli.ts static-imports only keyless modules. env.ts reimplements
  isOfflineForced/hasOpenRouterKey locally so the model-bearing
  agent-render/provider.ts never lands on the offline path; it reads
  OPENROUTER_API_KEY from env then walks up for a .env (no dev-only abs path).
- doctor reports node version (floor 20, matching SDK engines), SDK
  resolvability+version (require.resolve, no barrel execution), live-key
  presence, optional live-dep presence (probed lazily, never static-imported),
  and offline mode. Exit 0 = healthy-for-offline.
- Tests (node:test): arg parsing, doctor behavior, and a spawn-based offline
  boundary test asserting @openai/agents and zod are NOT in require.cache after
  loading the compiled entrypoint, plus zero-env doctor/--version/--help.

CLI offline: 18/0/0. SDK test:offline unchanged at 411/0/7 (418 total).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-05-31 14:12:16 -07:00

21 lines
477 B
JSON

{
"compilerOptions": {
"target": "ES2021",
"module": "CommonJS",
"moduleResolution": "Node",
"lib": ["ES2021"],
"declaration": true,
"declarationMap": true,
"sourceMap": true,
"outDir": "./dist",
"rootDir": "./src",
"strict": true,
"esModuleInterop": true,
"skipLibCheck": true,
"forceConsistentCasingInFileNames": true,
"resolveJsonModule": true
},
"include": ["src/**/*"],
"exclude": ["node_modules", "dist"]
}