Railyard side of PY1.2 (SC-E2, SP-F2). Acceptance: 1. packages/cli/src/scribase/env.mjs: in a Scribase project folder, `railyard deploy` reads the public URL and anon key `scribase init` wrote (.env, .env.local; NEXT_PUBLIC_/VITE_/EXPO_PUBLIC_/PUBLIC_ variants) into the build env and onto the Worker (--var), prints their names only, and leaves secrets out by name (service role key, SECRET/PASSWORD names, a service-role JWT under any name). `railyard link-scribase` reads a one-time claim from stdin (no flag takes it), exchanges it once and saves the token 0600; nothing is printed. 2. A git branch with Scribase branch settings (.scribase/branches/<branch>.env, written by the PS2.0 hook) deploys its <app>-<branch> preview against that branch (fixture test). 3. Bridge: deploy slot landed; proof is the latest successful deploy; new route POST /api/v1/bridge/scribase/deploys lists the bound org's deploys for the Scribase Deploy tab (org isolation test). Contract cases added. 4. Real Cloudflare end-to-end stays owner-run (tests use the fake wrangler). Tests: packages/cli 13/13, console bridge + deploys 15/15, tests/contract 3/3, tsc clean. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
18 lines
440 B
JavaScript
Executable File
18 lines
440 B
JavaScript
Executable File
#!/usr/bin/env node
|
|
import { main } from "../src/cli.mjs";
|
|
|
|
const code = await main(process.argv.slice(2), {
|
|
env: process.env,
|
|
cwd: process.cwd(),
|
|
out: (s) => process.stdout.write(`${s}\n`),
|
|
err: (s) => process.stderr.write(`${s}\n`),
|
|
now: () => Date.now(),
|
|
fetchImpl: fetch,
|
|
readStdin: async () => {
|
|
let text = "";
|
|
for await (const chunk of process.stdin) text += chunk;
|
|
return text;
|
|
},
|
|
});
|
|
process.exit(code);
|