@voltro/cli 0.44.1 → 0.45.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +104 -1
- package/dist/{apiBuild-DvWreIQP.js → apiBuild-CDQBNRDx.js} +1 -1
- package/dist/apiBuild-yJCqJYQ8.js +2 -0
- package/dist/bin.d.ts +16 -0
- package/dist/bin.js +46 -11
- package/dist/{build-Ckc-FA7d.js → build-yvsLG77U.js} +7 -7
- package/dist/{checkCommand-BNfEs4KG.js → checkCommand-Boxov8lr.js} +11 -11
- package/dist/{checkCommand-AlbawIal.js → checkCommand-lrzwOzV1.js} +1 -1
- package/dist/codegen-DcE2li1i.js +2 -0
- package/dist/{codegen-CbpGCWLG.js → codegen-sbN1Y8PB.js} +37 -37
- package/dist/codegenCommand-CQOLytL-.js +144 -0
- package/dist/{codemodRunner-BKTnaGOz.js → codemodRunner-5ZhDH3rB.js} +41 -0
- package/dist/{commands-CYkHTox2.js → commands-CEkVoFM5.js} +19 -19
- package/dist/{dashboardCommand-DHDmlo9A.js → dashboardCommand-0ahyp-zA.js} +1 -1
- package/dist/{dataCommand-WFn8CM11.js → dataCommand-D4IlZcih.js} +275 -211
- package/dist/{dev-D-JZ6CGQ.js → dev-DAM5CnAa.js} +1856 -1801
- package/dist/{dev-BZO5aLdr.js → dev-P4HyeY9W.js} +1 -1
- package/dist/devActivity.d.ts +16 -0
- package/dist/doctorCommand-2K1dIzYk.js +2 -0
- package/dist/{doctorCommand-BlUyESpD.js → doctorCommand-DW2cwAvC.js} +244 -223
- package/dist/doctorSourceRelations-CPjSwYuZ.js +83 -0
- package/dist/{dormancyCommand-lQxdrU8C.js → dormancyCommand-BqQz7lbM.js} +1 -1
- package/dist/{embeddingsCommand-ByBTju6X.js → embeddingsCommand-DJyArpU4.js} +1 -1
- package/dist/{envCommand-CpCbYAgR.js → envCommand-CviRZx1L.js} +1 -1
- package/dist/{evolveCommand-CBV3-TtK.js → evolveCommand-qdlP-R9G.js} +2 -2
- package/dist/index.d.ts +16 -0
- package/dist/index.js +1 -1
- package/dist/{infoCommand-DJoA9cKD.js → infoCommand-CNWPSUcW.js} +1 -1
- package/dist/inspectState.d.ts +16 -0
- package/dist/{runtimeTrace-DJ9tPhrc.js → runtimeTrace-BDZSt9W_.js} +1 -1
- package/dist/{sdkgen-7dr8-Onw.js → sdkgen-sNaD3oZB.js} +1 -1
- package/dist/{serveCommand-BlnAlNQg.js → serveCommand-BBhT2U94.js} +731 -737
- package/dist/serveCommand-DY2jLy0o.js +2 -0
- package/dist/serveEntry.d.ts +16 -0
- package/dist/serveEntry.js +1 -1
- package/dist/startEntry.d.ts +16 -0
- package/dist/startup.d.ts +16 -0
- package/dist/{test-CLYXrZ2F.js → test-CHb7UwvE.js} +1 -1
- package/dist/updateCommand-BH6EGuCc.js +2 -0
- package/dist/{updateCommand-BvRidHp6.js → updateCommand-rCnhaj84.js} +1 -1
- package/dist/{webhooksCommand-BfO_JF2b.js → webhooksCommand-C0iZZfaI.js} +1 -1
- package/package.json +23 -17
- package/templates/AGENTS.md +1 -1
- package/templates/agent-docs/_index.md +1 -1
- package/templates/agent-docs/cli.md +41 -1
- package/templates/agent-docs/data.md +33 -3
- package/templates/agent-docs/plugins/versioning.md +2 -0
- package/templates/agent-docs/whats-new.md +93 -6
- package/templates/apps/api-ai/package.json +7 -7
- package/templates/apps/api-auth/package.json +8 -8
- package/templates/apps/api-backend/package.json +7 -7
- package/templates/apps/api-backend-deactivation/package.json +7 -7
- package/templates/apps/api-backend-mail/package.json +8 -8
- package/templates/apps/api-backend-mariadb/package.json +9 -9
- package/templates/apps/api-backend-sqlite/package.json +8 -8
- package/templates/apps/api-backend-storage/package.json +8 -8
- package/templates/apps/api-cms/package.json +10 -10
- package/templates/apps/api-collab/package.json +8 -8
- package/templates/apps/api-data-advanced/package.json +8 -8
- package/templates/apps/api-durable/package.json +8 -8
- package/templates/apps/api-feature-flags/package.json +9 -9
- package/templates/apps/api-governance/package.json +8 -8
- package/templates/apps/api-kv/package.json +8 -8
- package/templates/apps/api-moderation/package.json +8 -8
- package/templates/apps/api-observability/package.json +8 -8
- package/templates/apps/api-ratelimit/package.json +8 -8
- package/templates/apps/api-rbac/package.json +8 -8
- package/templates/apps/api-rest/package.json +7 -7
- package/templates/apps/api-saas/package.json +11 -11
- package/templates/apps/api-saas-starter/package.json +10 -10
- package/templates/apps/api-search/package.json +8 -8
- package/templates/apps/api-status/package.json +8 -8
- package/templates/apps/api-versioning/package.json +8 -8
- package/templates/apps/api-webhooks/package.json +9 -9
- package/templates/apps/changelog/package.json +6 -6
- package/templates/apps/edge-functions/package.json +2 -2
- package/templates/apps/frontend-admin/package.json +8 -8
- package/templates/apps/frontend-app/package.json +9 -9
- package/templates/apps/frontend-auth/package.json +8 -8
- package/templates/apps/frontend-blank/package.json +7 -7
- package/templates/apps/frontend-cms/package.json +9 -9
- package/templates/apps/frontend-collab/package.json +10 -10
- package/templates/apps/frontend-contact/package.json +7 -7
- package/templates/apps/frontend-dashboard/package.json +7 -7
- package/templates/apps/frontend-docs/package.json +7 -7
- package/templates/apps/frontend-i18n/package.json +6 -6
- package/templates/apps/frontend-landing/package.json +7 -7
- package/templates/apps/frontend-portal/package.json +8 -8
- package/templates/apps/frontend-saas/package.json +8 -8
- package/templates/apps/frontend-spa/package.json +7 -7
- package/templates/apps/frontend-ssr/package.json +7 -7
- package/templates/apps/frontend-ssr-api/package.json +8 -8
- package/templates/apps/frontend-static-blog/package.json +6 -6
- package/templates/apps/frontend-status/package.json +8 -8
- package/templates/apps/mobile-app/package.json +4 -4
- package/dist/apiBuild-XaW40W8x.js +0 -2
- package/dist/codegen-i8QGcHsi.js +0 -2
- package/dist/codegenCommand-iClXoRCW.js +0 -129
- package/dist/doctorCommand-BeLOwq7S.js +0 -2
- package/dist/serveCommand-Dg_E1ev4.js +0 -2
- package/dist/updateCommand-DcKVmLVN.js +0 -2
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
import { bn as e, l as t, u as n, xn as r, z as i } from "./dev-DAM5CnAa.js";
|
|
2
|
+
import { dt as a } from "./webDev-101csg6Q.js";
|
|
3
|
+
import { r as o, u as s } from "./frameworkTableAssembly-oMPBKqlE.js";
|
|
4
|
+
import { i as c, r as l } from "./codegen-sbN1Y8PB.js";
|
|
5
|
+
import { basename as u, join as d, relative as f, resolve as p } from "node:path";
|
|
6
|
+
import { promises as m } from "node:fs";
|
|
7
|
+
import { pathToFileURL as h } from "node:url";
|
|
8
|
+
//#region src/mobileCodegen.ts
|
|
9
|
+
var g = "voltro.mobile.ts", _ = d(".framework", "mobileApis.generated.ts"), v = (e) => e.replace(/[^a-zA-Z0-9]/g, "_"), y = async (e) => {
|
|
10
|
+
let t = d(e, g);
|
|
11
|
+
try {
|
|
12
|
+
await m.stat(t);
|
|
13
|
+
} catch {
|
|
14
|
+
return { present: !1 };
|
|
15
|
+
}
|
|
16
|
+
try {
|
|
17
|
+
let e = (await import(`${h(t).href}?t=${Date.now()}`)).default;
|
|
18
|
+
return e === void 0 || typeof e != "object" || e.apis === void 0 ? {
|
|
19
|
+
present: !0,
|
|
20
|
+
error: /* @__PURE__ */ Error(`${g} has no default export with an \`apis\` map`)
|
|
21
|
+
} : {
|
|
22
|
+
present: !0,
|
|
23
|
+
binding: e
|
|
24
|
+
};
|
|
25
|
+
} catch (e) {
|
|
26
|
+
return {
|
|
27
|
+
present: !0,
|
|
28
|
+
error: e instanceof Error ? e : Error(String(e))
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
}, b = (e, t) => {
|
|
32
|
+
let n = t.filter(([, e]) => e.package !== void 0).map(([e, t]) => {
|
|
33
|
+
let n = `${v(e)}Group`, r = `${v(e)}Descriptors`;
|
|
34
|
+
return `import { ${n === "appGroup" ? "appGroup" : `appGroup as ${n}`}, ${r === "appDescriptors" ? "appDescriptors" : `appDescriptors as ${r}`} } from '${t.package}/rpcGroup'`;
|
|
35
|
+
}), r = t.map(([e, t]) => t.package === void 0 ? ` // ${JSON.stringify(e)}: declared with \`url\` only — no local rpc surface to import.\n // Add \`package: '<the api package>'\` to ${g} to get typed hooks for it.` : ` { ${[
|
|
36
|
+
`name: ${JSON.stringify(e)}`,
|
|
37
|
+
`group: ${v(e)}Group`,
|
|
38
|
+
`descriptors: ${v(e)}Descriptors`,
|
|
39
|
+
`wsUrl: wsUrl(${JSON.stringify(e)})`
|
|
40
|
+
].join(", ")} },`), i = t.filter(([, e]) => e.url !== void 0).map(([e, t]) => ` ${JSON.stringify(e)}: ${JSON.stringify(t.url)},`);
|
|
41
|
+
return [
|
|
42
|
+
"// GENERATED BY `voltro codegen` — do not edit; regenerate with `voltro codegen`.",
|
|
43
|
+
"//",
|
|
44
|
+
`// The api bindings declared in ${g}. Only the BINDING is`,
|
|
45
|
+
"// generated: the procedure types ride the imports below, so a schema change",
|
|
46
|
+
"// in an api needs no regeneration here.",
|
|
47
|
+
"",
|
|
48
|
+
...n,
|
|
49
|
+
"import type { MobileApiBinding } from '@voltro/react-native'",
|
|
50
|
+
"",
|
|
51
|
+
"/** Every api this app talks to, bound to a runtime-resolved ws URL.",
|
|
52
|
+
" *",
|
|
53
|
+
" * The URL is a parameter because it differs per environment and `localhost`",
|
|
54
|
+
" * on a device is the DEVICE — see `resolveDevWsUrl` in @voltro/react-native. */",
|
|
55
|
+
"export const mobileApis = (",
|
|
56
|
+
" wsUrl: (apiName: string) => string,",
|
|
57
|
+
"): ReadonlyArray<MobileApiBinding> => [",
|
|
58
|
+
...r,
|
|
59
|
+
"]",
|
|
60
|
+
"",
|
|
61
|
+
"/** Api names in declaration order — the keys the hooks bind to. */",
|
|
62
|
+
`export const MOBILE_API_NAMES = [${t.map(([e]) => JSON.stringify(e)).join(", ")}] as const`,
|
|
63
|
+
...i.length > 0 ? [
|
|
64
|
+
"",
|
|
65
|
+
`/** URLs declared in ${g} for apis this app does not build. */`,
|
|
66
|
+
"export const MOBILE_API_URLS: Readonly<Record<string, string>> = {",
|
|
67
|
+
...i,
|
|
68
|
+
"}"
|
|
69
|
+
] : [],
|
|
70
|
+
""
|
|
71
|
+
].join("\n");
|
|
72
|
+
}, x = async (e) => {
|
|
73
|
+
let t = p(e), n = await y(t);
|
|
74
|
+
if (!n.present) return { kind: "not-a-mobile-app" };
|
|
75
|
+
if ("error" in n) return {
|
|
76
|
+
kind: "refused",
|
|
77
|
+
reason: `${g} could not be loaded — ${n.error.message}`
|
|
78
|
+
};
|
|
79
|
+
let r = Object.entries(n.binding.apis);
|
|
80
|
+
if (r.length === 0) return {
|
|
81
|
+
kind: "refused",
|
|
82
|
+
reason: `${g} declares no apis`
|
|
83
|
+
};
|
|
84
|
+
for (let [e, t] of r) if (t.package === void 0 && t.url === void 0) return {
|
|
85
|
+
kind: "refused",
|
|
86
|
+
reason: `api ${JSON.stringify(e)} declares neither \`package\` nor \`url\``
|
|
87
|
+
};
|
|
88
|
+
for (let [e, n] of r) if (n.package !== void 0 && await a(t, n.package) === null) return {
|
|
89
|
+
kind: "refused",
|
|
90
|
+
reason: `api ${JSON.stringify(e)}: ${n.package} is not a workspace dependency of this app. Add it to the app's package.json (\`"${n.package}": "workspace:*"\`) and install.`
|
|
91
|
+
};
|
|
92
|
+
let i = d(t, _), o = b(t, r);
|
|
93
|
+
await m.mkdir(d(t, ".framework"), { recursive: !0 });
|
|
94
|
+
let s = null;
|
|
95
|
+
try {
|
|
96
|
+
s = await m.readFile(i, "utf8");
|
|
97
|
+
} catch {}
|
|
98
|
+
return s !== o && await m.writeFile(i, o, "utf8"), {
|
|
99
|
+
kind: "wrote",
|
|
100
|
+
file: i,
|
|
101
|
+
apis: r.map(([e]) => e)
|
|
102
|
+
};
|
|
103
|
+
}, S = (e, t) => t.kind === "wrote" ? `voltro codegen: wrote ${f(e, t.file)} (apis ${t.apis.join(", ")})` : t.kind === "refused" ? `voltro codegen: ${t.reason} — refusing to write.` : `voltro codegen: no ${g} here — not a mobile app.`, C = async (e) => {
|
|
104
|
+
let { config: n, present: a, error: o } = await t(e);
|
|
105
|
+
if (a && n === null) return {
|
|
106
|
+
kind: "refused",
|
|
107
|
+
reason: "app.config.ts exists but could not be loaded" + (o === void 0 ? "" : ` — ${o instanceof Error ? o.message : String(o)}`)
|
|
108
|
+
};
|
|
109
|
+
let s = n?.plugins ?? [], { pluginContributions: c, pluginErrorImports: d, pluginRpcImports: f } = await i(s, n?.name ?? u(e), e), p = await l({
|
|
110
|
+
root: e,
|
|
111
|
+
...c.length > 0 ? { pluginContributions: c } : {},
|
|
112
|
+
...d.length > 0 ? { pluginErrorImports: d } : {},
|
|
113
|
+
...f.length > 0 ? { pluginRpcImports: f } : {},
|
|
114
|
+
...n?.name === void 0 ? {} : { apiName: n.name }
|
|
115
|
+
});
|
|
116
|
+
if (!p) return { kind: "nothing-to-write" };
|
|
117
|
+
let m = await w(e, n), h = await r(p, m);
|
|
118
|
+
return {
|
|
119
|
+
kind: "wrote",
|
|
120
|
+
file: p,
|
|
121
|
+
plugins: s.length,
|
|
122
|
+
errorSchemas: d.length,
|
|
123
|
+
routes: f.length,
|
|
124
|
+
tables: m.size,
|
|
125
|
+
dts: h
|
|
126
|
+
};
|
|
127
|
+
}, w = async (t, r) => {
|
|
128
|
+
let i = await c(t), { tables: a, featureMix: l } = await n(i), u = s({
|
|
129
|
+
nodeEnv: process.env.NODE_ENV,
|
|
130
|
+
declared: r?.schema
|
|
131
|
+
}), d = o({
|
|
132
|
+
mix: l,
|
|
133
|
+
plugins: r?.plugins ?? [],
|
|
134
|
+
gates: u
|
|
135
|
+
});
|
|
136
|
+
return e(a, d, r?.analytics?.tables ?? []);
|
|
137
|
+
}, T = async (e) => {
|
|
138
|
+
let t = p(e.find((e) => !e.startsWith("-")) ?? process.cwd()), n = await x(t);
|
|
139
|
+
if (n.kind !== "not-a-mobile-app") return console.log(S(t, n)), n.kind === "wrote" ? 0 : 1;
|
|
140
|
+
let r = await C(t);
|
|
141
|
+
return r.kind === "refused" ? (console.error(`voltro codegen: ${r.reason} — refusing to write.`), console.error(" The generated file would omit every plugin's error union and client routes, and would typecheck, so the omission would only surface as a missing error tag at runtime."), 1) : r.kind === "nothing-to-write" ? (console.log("voltro codegen: no rpc primitives found — nothing to write."), 0) : (console.log(`voltro codegen: wrote ${f(t, r.file)} (plugins ${r.plugins}, error schemas ${r.errorSchemas}, plugin routes ${r.routes})`), console.log(r.dts.action === "removed" ? ` removed ${f(t, r.dts.path)} — no tables declared, so \`source:\` is \`string\` again` : r.dts.action === "skipped" ? " no tables declared — `source:` stays `string`" : ` ${r.dts.action} ${f(t, r.dts.path)} (${r.tables} table name(s) typed for \`source:\`)`), r.plugins > 0 && r.errorSchemas === 0 && console.log(" note: no plugin contributed a cross-cutting error schema, so the wire error union carries only each procedure's own `error:`. Expected if none of your plugins declare `errorSchemas` — but `guards:` needs @voltro/plugin-rbac for its ScopeError to decode typed."), 0);
|
|
142
|
+
};
|
|
143
|
+
//#endregion
|
|
144
|
+
export { C as regenerateRpcGroup, T as runCodegenCommand };
|
|
@@ -5640,6 +5640,47 @@ var b = (e, t, n) => {
|
|
|
5640
5640
|
"emptied of its old rows and holding part of the new ones. If you relied on per-table resume for a replace,",
|
|
5641
5641
|
"that is the non-atomic path."
|
|
5642
5642
|
].join("\n")
|
|
5643
|
+
}),
|
|
5644
|
+
S({
|
|
5645
|
+
version: "0.45.0",
|
|
5646
|
+
id: "0.45.0/01_typed-source-table-name",
|
|
5647
|
+
title: "`source:` is typechecked against the app’s tables, from the next `voltro dev`",
|
|
5648
|
+
kind: "manual",
|
|
5649
|
+
appliesTo: ({ project: e }) => e.getSourceFiles().some((e) => /\bsource\s*:/.test(e.getFullText())),
|
|
5650
|
+
note: [
|
|
5651
|
+
"`source:` on a query or stream is now typed against your app’s own tables.",
|
|
5652
|
+
"A name no table carries is a COMPILE error instead of a subscription that",
|
|
5653
|
+
"silently never updates.",
|
|
5654
|
+
"",
|
|
5655
|
+
"WHEN IT STARTS APPLYING",
|
|
5656
|
+
"",
|
|
5657
|
+
"Not now — at your next `voltro dev` (or `voltro codegen`). Those write",
|
|
5658
|
+
"`voltro-tables.generated.d.ts` beside the generated rpc group, and that file",
|
|
5659
|
+
"is what narrows the type. Until it exists, `source:` is `string`, exactly as",
|
|
5660
|
+
"it is today. This note exists because the error appears one command later",
|
|
5661
|
+
"than the upgrade that caused it.",
|
|
5662
|
+
"",
|
|
5663
|
+
"WHAT TO DO",
|
|
5664
|
+
"",
|
|
5665
|
+
"Boot once, then read what `tsc` flags. Each site is one of two things:",
|
|
5666
|
+
"",
|
|
5667
|
+
" • a name that is misspelled, or was renamed away — a REAL defect this",
|
|
5668
|
+
" just surfaced. That query’s view was never updating. Fix the name.",
|
|
5669
|
+
"",
|
|
5670
|
+
" • a source computed at runtime — correct as written. Annotate it",
|
|
5671
|
+
" `ReactivitySourceValue` (exported from `@voltro/protocol`), which is the",
|
|
5672
|
+
" wide `string | ReactivityChannel` shape.",
|
|
5673
|
+
"",
|
|
5674
|
+
"Reach for the second only when the value genuinely is not a literal. Widening",
|
|
5675
|
+
"a name you could have spelled turns a found defect back into a quiet one.",
|
|
5676
|
+
"",
|
|
5677
|
+
"Eager-loaded relations are a common source of the first kind: a query that",
|
|
5678
|
+
"loads a relation must also declare that relation’s table (and, for a",
|
|
5679
|
+
"many-to-many, the junction). `voltro doctor` reports those.",
|
|
5680
|
+
"",
|
|
5681
|
+
"To opt out entirely, delete `voltro-tables.generated.d.ts` and exclude it",
|
|
5682
|
+
"from your tsconfig; `source:` widens back to `string`."
|
|
5683
|
+
].join("\n")
|
|
5643
5684
|
})
|
|
5644
5685
|
], Y = /* @__PURE__ */ new Set([
|
|
5645
5686
|
"node_modules",
|
|
@@ -91,7 +91,7 @@ var c = () => {
|
|
|
91
91
|
name: "dev",
|
|
92
92
|
summary: "Start the local development server (auto-discovers routes / mutations).",
|
|
93
93
|
status: "wired",
|
|
94
|
-
run: (e) => import("./dev-
|
|
94
|
+
run: (e) => import("./dev-P4HyeY9W.js").then((t) => t.runDev(e)),
|
|
95
95
|
help: {
|
|
96
96
|
usage: "[app]",
|
|
97
97
|
examples: [["voltro dev", "boot the app in the current directory"], ["voltro dev apps/acme/api", "boot a specific app"]],
|
|
@@ -109,7 +109,7 @@ var c = () => {
|
|
|
109
109
|
name: "dashboard",
|
|
110
110
|
summary: "Serve the DevTools dashboard standalone (from @voltro/dashboard). Targets via VOLTRO_DASHBOARD_APPS; --port to override.",
|
|
111
111
|
status: "wired",
|
|
112
|
-
run: (e) => import("./dashboardCommand-
|
|
112
|
+
run: (e) => import("./dashboardCommand-0ahyp-zA.js").then((t) => t.runDashboardCommand(e)),
|
|
113
113
|
help: {
|
|
114
114
|
usage: "[--port <n>]",
|
|
115
115
|
flags: [["--port <n>", "port to serve the dashboard on"]],
|
|
@@ -121,7 +121,7 @@ var c = () => {
|
|
|
121
121
|
name: "check",
|
|
122
122
|
summary: "Verify the app graph (blast-radius checks) against a running api; LLM-shaped --json diagnostics. Flags: --json, --process <p>, --diff removeTable:<name>.",
|
|
123
123
|
status: "wired",
|
|
124
|
-
run: (e) => import("./checkCommand-
|
|
124
|
+
run: (e) => import("./checkCommand-lrzwOzV1.js").then((t) => t.runCheckCommand(e)),
|
|
125
125
|
help: {
|
|
126
126
|
usage: "[--json] [--offline] [--process <name>] [--diff removeTable:<name>]",
|
|
127
127
|
flags: [
|
|
@@ -155,7 +155,7 @@ var c = () => {
|
|
|
155
155
|
name: "webhooks",
|
|
156
156
|
summary: "Outbound-webhook artefacts. `consumer` generates the ZERO-DEPENDENCY Standard-Webhooks verification package a subscriber installs, from this app's own declared events; `events` lists the events a subscriber can register for. Usage: voltro webhooks <consumer|events> [path] [--out <dir>] [--name <pkg>] [--json].",
|
|
157
157
|
status: "wired",
|
|
158
|
-
run: (e) => import("./webhooksCommand-
|
|
158
|
+
run: (e) => import("./webhooksCommand-C0iZZfaI.js").then((t) => t.runWebhooksCommand(e)),
|
|
159
159
|
help: {
|
|
160
160
|
usage: "<consumer|events> [path] [--out <dir>] [--name <pkg>] [--json]",
|
|
161
161
|
flags: [
|
|
@@ -171,7 +171,7 @@ var c = () => {
|
|
|
171
171
|
name: "evolve",
|
|
172
172
|
summary: "Schema-evolution copilot: propose an observed-graph-driven codemod + a branch-verified backfill for a schema change (rename/retype/split/drop a column, rename a table). Dry-run by default; --write applies. Usage: voltro evolve rename-column <table>.<col> --to <newName> [--write] [--json].",
|
|
173
173
|
status: "wired",
|
|
174
|
-
run: (e) => import("./evolveCommand-
|
|
174
|
+
run: (e) => import("./evolveCommand-qdlP-R9G.js").then((t) => t.runEvolveCommand(e)),
|
|
175
175
|
help: {
|
|
176
176
|
usage: "<rename-column|rename-table|retype-column|split-column|drop-column> <target> [--to <new>] [--write]",
|
|
177
177
|
flags: [
|
|
@@ -188,7 +188,7 @@ var c = () => {
|
|
|
188
188
|
name: "codegen",
|
|
189
189
|
summary: "Emit rpcGroup.generated.ts from discovered route / mutation descriptors.",
|
|
190
190
|
status: "wired",
|
|
191
|
-
run: (e) => import("./codegenCommand-
|
|
191
|
+
run: (e) => import("./codegenCommand-CQOLytL-.js").then((t) => t.runCodegenCommand(e)),
|
|
192
192
|
help: {
|
|
193
193
|
usage: "[app]",
|
|
194
194
|
examples: [["voltro codegen", "regenerate rpcGroup.generated.ts for the app in the cwd"]],
|
|
@@ -211,7 +211,7 @@ var c = () => {
|
|
|
211
211
|
name: "test",
|
|
212
212
|
summary: "Run vitest against the app at the cwd (auto-discovers *.test.ts/tsx).",
|
|
213
213
|
status: "wired",
|
|
214
|
-
run: (e) => import("./test-
|
|
214
|
+
run: (e) => import("./test-CHb7UwvE.js").then((t) => t.runTestCommand(e)),
|
|
215
215
|
help: {
|
|
216
216
|
usage: "[dir] [filter…] [--watch] [-t <pattern>]",
|
|
217
217
|
flags: [
|
|
@@ -259,7 +259,7 @@ var c = () => {
|
|
|
259
259
|
name: "info",
|
|
260
260
|
summary: "Report versions (CLI, node, every installed @voltro/* — flags lockstep skew), package manager, and dialect. --json for CI. Exits 1 on version skew.",
|
|
261
261
|
status: "wired",
|
|
262
|
-
run: (e) => import("./infoCommand-
|
|
262
|
+
run: (e) => import("./infoCommand-CNWPSUcW.js").then((t) => t.runInfoCommand(e)),
|
|
263
263
|
help: {
|
|
264
264
|
usage: "[--json]",
|
|
265
265
|
flags: [["--json", "machine-readable report"]],
|
|
@@ -280,7 +280,7 @@ var c = () => {
|
|
|
280
280
|
name: "env",
|
|
281
281
|
summary: "Inspect/sync the typed-env manifest. Subcommands: check (default), sync (.env.example), types (env.generated.d.ts for CI tsc), turbo.",
|
|
282
282
|
status: "wired",
|
|
283
|
-
run: (e) => import("./envCommand-
|
|
283
|
+
run: (e) => import("./envCommand-CviRZx1L.js").then((t) => t.runEnvCommand(e)),
|
|
284
284
|
help: {
|
|
285
285
|
usage: "[check|sync|types|turbo] [--force]",
|
|
286
286
|
flags: [["--force", "overwrite the generated file instead of refusing on a conflict"]],
|
|
@@ -309,12 +309,12 @@ var c = () => {
|
|
|
309
309
|
run: async (e) => {
|
|
310
310
|
let t = e.find((e) => !e.startsWith("-")) ?? process.cwd();
|
|
311
311
|
if (e.includes("--preflight")) {
|
|
312
|
-
let { runServePreflight: e } = await import("./doctorCommand-
|
|
312
|
+
let { runServePreflight: e } = await import("./doctorCommand-2K1dIzYk.js");
|
|
313
313
|
return e(a(t), !0);
|
|
314
314
|
}
|
|
315
315
|
let { tryRunWebServe: n } = await import("./webDev-BLKBO34K.js"), r = await n(a(t));
|
|
316
316
|
if (!r.ran) {
|
|
317
|
-
let { runServeDispatch: t } = await import("./serveCommand-
|
|
317
|
+
let { runServeDispatch: t } = await import("./serveCommand-DY2jLy0o.js");
|
|
318
318
|
return t(e);
|
|
319
319
|
}
|
|
320
320
|
return r.exitCode;
|
|
@@ -342,13 +342,13 @@ var c = () => {
|
|
|
342
342
|
handlesHelp: !0,
|
|
343
343
|
summary: "Preflight an app for production: the precompiled serve bundle, hand-rolled primitives (naming the shipped one), @voltro/* version skew, executors with no access check, `.serverOnly()` leaks, and junction-FK gaps.",
|
|
344
344
|
status: "wired",
|
|
345
|
-
run: (e) => import("./doctorCommand-
|
|
345
|
+
run: (e) => import("./doctorCommand-2K1dIzYk.js").then((t) => t.runDoctorCommand(e))
|
|
346
346
|
},
|
|
347
347
|
{
|
|
348
348
|
name: "build",
|
|
349
349
|
summary: "Production build for a web app (vite build + per-page SSG pre-render).",
|
|
350
350
|
status: "wired",
|
|
351
|
-
run: (e) => import("./build-
|
|
351
|
+
run: (e) => import("./build-yvsLG77U.js").then((t) => t.runBuildCommand(e)),
|
|
352
352
|
help: {
|
|
353
353
|
usage: "[app] [--target <t>]",
|
|
354
354
|
flags: [["--target <t>", "build target"]],
|
|
@@ -364,7 +364,7 @@ var c = () => {
|
|
|
364
364
|
name: "prune-runtime",
|
|
365
365
|
summary: "Trim a deployed web tree’s node_modules to the reachable runtime set (standalone image slimming).",
|
|
366
366
|
status: "wired",
|
|
367
|
-
run: (e) => import("./runtimeTrace-
|
|
367
|
+
run: (e) => import("./runtimeTrace-BDZSt9W_.js").then((t) => t.runPruneRuntimeCommand(e)),
|
|
368
368
|
hidden: !0
|
|
369
369
|
},
|
|
370
370
|
{
|
|
@@ -382,7 +382,7 @@ var c = () => {
|
|
|
382
382
|
name: "dormancy",
|
|
383
383
|
summary: "Single-node scale-to-zero: front the API with a wake-orchestrator that stops the app when idle and brings it back on a request or a due wakeup (cron/workflow). Needs a SQL store. Flags: --port, --app-port, --idle-grace-ms, --tick-ms.",
|
|
384
384
|
status: "wired",
|
|
385
|
-
run: (e) => import("./dormancyCommand-
|
|
385
|
+
run: (e) => import("./dormancyCommand-BqQz7lbM.js").then((t) => t.runDormancyCommand(e)),
|
|
386
386
|
help: {
|
|
387
387
|
usage: "[app] [--port <n>] [--app-port <n>] [--idle-grace-ms <n>] [--tick-ms <n>]",
|
|
388
388
|
flags: [
|
|
@@ -469,7 +469,7 @@ var c = () => {
|
|
|
469
469
|
name: "data",
|
|
470
470
|
summary: "Export/import + backup/restore of app data. Logical (rows + optional assets): export <dir> [--tenant <id>|--tables a,b] [--assets] [--compression zstd|gzip|none] [--consistency live|snapshot]; import <dir> [--assets] [--no-verify]. Native (rows ONLY — no blobs): backup <dir> / restore <dir> (pg_dump/mariadb-dump/…). Resumable; typed-NDJSON; content-addressed assets on the logical path.",
|
|
471
471
|
status: "wired",
|
|
472
|
-
run: (e) => import("./dataCommand-
|
|
472
|
+
run: (e) => import("./dataCommand-D4IlZcih.js").then((t) => t.runDataCommand(e)),
|
|
473
473
|
help: {
|
|
474
474
|
usage: "<export|import|backup|restore> <dir> [options]",
|
|
475
475
|
flags: [
|
|
@@ -524,20 +524,20 @@ var c = () => {
|
|
|
524
524
|
handlesHelp: !0,
|
|
525
525
|
summary: "Upgrade the app to the latest framework: bump every @voltro/* dependency (across ALL workspace members, install once at the workspace root), then run the codemods shipped with the target version. Flags: --to <version>, --from <version>, --codemods-only, --dry-run, --force, --exact, --help. After: run `voltro db apply`.",
|
|
526
526
|
status: "wired",
|
|
527
|
-
run: (e) => import("./updateCommand-
|
|
527
|
+
run: (e) => import("./updateCommand-BH6EGuCc.js").then((t) => t.runUpdateCommand(e))
|
|
528
528
|
},
|
|
529
529
|
{
|
|
530
530
|
name: "_apply-codemods",
|
|
531
531
|
summary: "Internal: apply shipped codemods for a framework version jump (re-exec target of `voltro update`).",
|
|
532
532
|
status: "wired",
|
|
533
533
|
hidden: !0,
|
|
534
|
-
run: (e) => import("./updateCommand-
|
|
534
|
+
run: (e) => import("./updateCommand-BH6EGuCc.js").then((t) => t.runApplyCodemods(e))
|
|
535
535
|
},
|
|
536
536
|
{
|
|
537
537
|
name: "embeddings",
|
|
538
538
|
summary: "Embeddings tooling. Subcommand: backfill <table> --text <field> --vector <field> [--model <m>] [--model-field <f>] [--batch <n>] [--dry-run] — (re)embed rows the vectorEmbedding() mixin missed.",
|
|
539
539
|
status: "wired",
|
|
540
|
-
run: (e) => import("./embeddingsCommand-
|
|
540
|
+
run: (e) => import("./embeddingsCommand-DJyArpU4.js").then((t) => t.runEmbeddingsCommand(e)),
|
|
541
541
|
help: {
|
|
542
542
|
usage: "backfill <table> --text <field> --vector <field> [--model <m>] [--batch <n>] [--dry-run]",
|
|
543
543
|
flags: [
|