@voltro/cli 0.33.0 → 0.34.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 +1801 -0
- package/bin/nodeEnvironment.d.mts +30 -0
- package/bin/nodeEnvironment.mjs +158 -0
- package/bin/voltro.mjs +69 -5
- package/dist/addCommand-BNeoeSxe.js +124 -0
- package/dist/addCommand-aXSQveak.js +2 -0
- package/dist/agentsMd-BTchIZku.js +2 -0
- package/dist/agentsMd-mhQMF1bx.js +254 -0
- package/dist/apiBuild-BICVGnEC.js +2 -0
- package/dist/{apiBuild-h9VHtnlw.js → apiBuild-DZF_f0_I.js} +46 -46
- package/dist/appPort-B_HpJ_ck.js +48 -0
- package/dist/baselineCommand-C2ClWZN3.js +2 -0
- package/dist/baselineCommand-DIttzO8A.js +227 -0
- package/dist/bin.js +71 -28
- package/dist/build-CE7Ca9gm.js +711 -0
- package/dist/cacheCommand-DA4OH9xt.js +42 -0
- package/dist/capabilitiesCommand-nq_pz5xd.js +123 -0
- package/dist/checkCommand-Dv8r9tGO.js +231 -0
- package/dist/checkCommand-YZDmkAGd.js +2 -0
- package/dist/{cliArgs-qdZSElM3.js → cliArgs-D4p8n7EE.js} +12 -1
- package/dist/cliError-BmdYnghb.js +10 -0
- package/dist/cliOutput-D1tSBoRM.js +15 -0
- package/dist/{cliRuntime-Oh517vCV.js → cliRuntime-Dh7UDinH.js} +20 -20
- package/dist/cloudClient-DWL-Hw_T.js +67 -0
- package/dist/cloudCmd-Cvv5HGaZ.js +364 -0
- package/dist/clusterCmd-CNXKlcvD.js +54 -0
- package/dist/codegen-CYM3Zqrf.js +605 -0
- package/dist/codegen-ChBi_hVa.js +2 -0
- package/dist/codegenCommand-DC6w2tNZ.js +30 -0
- package/dist/codemodRunner-DRRqXR74.js +5243 -0
- package/dist/commandRunner-BLAEFLjp.js +47 -0
- package/dist/commands-gutsz-Ac.js +808 -0
- package/dist/connectionConfig-UFlIEiys.js +66 -0
- package/dist/dashboardCommand-3YG8p-UA.js +25 -0
- package/dist/dataCommand-qL0r7fPO.js +535 -0
- package/dist/dataProfile-dW-PsfLB.js +15 -0
- package/dist/{dbCommand-DTLKAfbA.js → dbCommand-B6X0FZbq.js} +551 -401
- package/dist/dbCommand-CpdKLeQq.js +2 -0
- package/dist/{dev-C_P8FLSx.js → dev-CerMd0mW.js} +3122 -3129
- package/dist/dev-CoG-ZPx8.js +3 -0
- package/dist/devActivity-Dx_3nnGv.js +100 -0
- package/dist/devActivity.js +1 -1
- package/dist/dialectDriver-CgXnDfec.js +39 -0
- package/dist/discover-C9XKJDco.js +25 -0
- package/dist/doctorCommand-BvqGBwNG.js +2 -0
- package/dist/{checkCommand-xGhRFFg2.js → doctorCommand-CnDXQxfa.js} +520 -1278
- package/dist/dormancyCommand-Dszo57d6.js +69 -0
- package/dist/e2eCmd-BRabZww-.js +147 -0
- package/dist/embeddingsCommand-C0sKVRo1.js +73 -0
- package/dist/envCommand-DPgdV1Bq.js +60 -0
- package/dist/evalCommand-6RUfPen4.js +118 -0
- package/dist/evolveCommand-DHpkgjgH.js +281 -0
- package/dist/fileTaxonomy-CJfgOllU.js +457 -0
- package/dist/frameworkTableAssembly-BGHmck-x.js +2 -0
- package/dist/{frameworkTableAssembly-BwIrO5nv.js → frameworkTableAssembly-DkkP6BgC.js} +184 -148
- package/dist/generateCommand-oibemh97.js +147 -0
- package/dist/index.d.ts +45 -0
- package/dist/index.js +4 -3
- package/dist/infoCommand-BJw9nLUR.js +60 -0
- package/dist/{inspect-BUUjt773.js → inspect-CBqFtAKA.js} +82 -40
- package/dist/inspect-C_T_WGvl.js +2 -0
- package/dist/inspectCmd-Bppy-GGw.js +224 -0
- package/dist/inspectFetch-Cm8_wVvp.js +151 -0
- package/dist/inspectMetrics-CfdKLh6t.js +72 -0
- package/dist/loadEnv-D9nEOClM.js +44 -0
- package/dist/logFileSink-C_D2wRN1.js +105 -0
- package/dist/logsCmd-CCca3KRZ.js +260 -0
- package/dist/manifestBuild-ChsKAhmn.js +2 -0
- package/dist/{manifestBuild-BLrVuSlM.js → manifestBuild-sxpwdKY1.js} +1 -1
- package/dist/metaCommands-7MJfZ5cf.js +196 -0
- package/dist/migrate-CBwOt_iV.js +83 -0
- package/dist/mssqlClusterPatch-_4cE_nun.js +44 -0
- package/dist/newCommand-COWOJ1_E.js +156 -0
- package/dist/nodeEnvironment-cGFAj1J8.js +28 -0
- package/dist/packageCommand-Cug_3Ogl.js +271 -0
- package/dist/pageConvention-cEiRxdab.js +5 -0
- package/dist/privacyCommand-C-Df56U_.js +146 -0
- package/dist/projectScaffold-DmzEKHib.js +2 -0
- package/dist/projectScaffold-LMMtaavR.js +814 -0
- package/dist/renderModeScan-D7J1B7Kw.js +105 -0
- package/dist/renderProfile-1OWWAAtx.js +81 -0
- package/dist/runtimeRegistry-DMeKfTHP.js +81 -0
- package/dist/runtimeTrace-CRxalXTs.js +91 -0
- package/dist/scheduleCmd--jksTrf6.js +69 -0
- package/dist/scheduleManifestCmd-D2x0CTTY.js +249 -0
- package/dist/schemaIr-UJybUUZW.js +103 -0
- package/dist/{sdkgen-C81QIkiL.js → sdkgen-CYJscZC7.js} +111 -209
- package/dist/seedRunner-TFHHiToI.js +329 -0
- package/dist/serveCommand-B_isw7q4.js +1647 -0
- package/dist/serveCommand-DOvbgRnQ.js +2 -0
- package/dist/serveEntry.js +5 -5
- package/dist/serverlessCommand-CfJZy6dS.js +482 -0
- package/dist/start-9LiUOfES.js +1087 -0
- package/dist/start-B-9Nsp-S.js +3 -0
- package/dist/startEntry.js +2 -2
- package/dist/staticCommand-Dr2M6tpU.js +304 -0
- package/dist/storageCommand-Co6NfLqN.js +42 -0
- package/dist/templates-De8IR5-c.js +102 -0
- package/dist/test-CI6iDsYc.js +115 -0
- package/dist/tracesCmd-CkEZQrtt.js +232 -0
- package/dist/tsconfigPaths-BWXBWgcl.js +107 -0
- package/dist/tsxLoader-EuXmSJ1K.js +51 -0
- package/dist/typecheckCommand-BlsWiCNq.js +61 -0
- package/dist/updateCommand-Bkptutss.js +585 -0
- package/dist/updateCommand-us1_hdIC.js +2 -0
- package/dist/{inspectMetrics-1xzTKAFx.js → webDev-CBYvPqQr.js} +975 -1559
- package/dist/webDev-Cg-fFiyd2.js +2 -0
- package/dist/webhookDiscovery-CrGAfhIG.js +2 -0
- package/dist/webhookDiscovery-D7VaeMlz.js +51 -0
- package/dist/webhooksCommand-CID96Rga.js +267 -0
- package/dist/workflowsCmd-D1VTmLMY.js +608 -0
- package/package.json +179 -17
- package/templates/AGENTS.core.md +58 -3
- package/templates/AGENTS.md +64 -7
- package/templates/agent-docs/_index.md +6 -4
- package/templates/agent-docs/_manifest.json +22 -5
- package/templates/agent-docs/ai.md +370 -0
- package/templates/agent-docs/authentication.md +265 -31
- package/templates/agent-docs/caching.md +6 -0
- package/templates/agent-docs/cli.md +794 -50
- package/templates/agent-docs/data.md +550 -11
- package/templates/agent-docs/database/migrations.md +174 -25
- package/templates/agent-docs/database/misc.md +156 -40
- package/templates/agent-docs/database/querying.md +19 -1
- package/templates/agent-docs/database/scaling.md +60 -0
- package/templates/agent-docs/database/schema.md +1 -0
- package/templates/agent-docs/database/seedsdialects.md +208 -19
- package/templates/agent-docs/database/transactions.md +68 -0
- package/templates/agent-docs/deployment.md +69 -3
- package/templates/agent-docs/introduction.md +87 -16
- package/templates/agent-docs/local-first-mobile.md +79 -4
- package/templates/agent-docs/multi-tenancy.md +95 -20
- package/templates/agent-docs/observability.md +58 -3
- package/templates/agent-docs/plugins/ai-flows.md +161 -2
- package/templates/agent-docs/plugins/analytics-postgres.md +1 -1
- package/templates/agent-docs/plugins/audit.md +37 -1
- package/templates/agent-docs/plugins/auth-social.md +143 -0
- package/templates/agent-docs/plugins/auth-workos.md +4 -2
- package/templates/agent-docs/plugins/auth.md +131 -6
- package/templates/agent-docs/plugins/billing.md +132 -15
- package/templates/agent-docs/plugins/cdc-out.md +46 -7
- package/templates/agent-docs/plugins/clickhouse.md +1 -1
- package/templates/agent-docs/plugins/duckdb.md +1 -1
- package/templates/agent-docs/plugins/flags.md +132 -0
- package/templates/agent-docs/plugins/governance.md +105 -7
- package/templates/agent-docs/plugins/multitenancy.md +9 -4
- package/templates/agent-docs/plugins/presence.md +13 -2
- package/templates/agent-docs/plugins/ratelimit.md +9 -0
- package/templates/agent-docs/plugins/search.md +157 -6
- package/templates/agent-docs/plugins/sso-saml.md +47 -8
- package/templates/agent-docs/plugins/webhooks.md +105 -0
- package/templates/agent-docs/plugins.md +150 -18
- package/templates/agent-docs/reference.md +60 -3
- package/templates/agent-docs/releases.md +1117 -0
- package/templates/agent-docs/routing.md +43 -25
- package/templates/agent-docs/scheduling.md +10 -0
- package/templates/agent-docs/schema-driven-ui.md +92 -12
- package/templates/agent-docs/security.md +426 -0
- package/templates/agent-docs/templates/apibackends.md +87 -18
- package/templates/agent-docs/templates/appshells.md +32 -14
- package/templates/agent-docs/templates/overview.md +13 -8
- package/templates/agent-docs/testing.md +211 -14
- package/templates/agent-docs/whats-new.md +1700 -104
- package/templates/agent-docs/workflows.md +130 -14
- package/templates/apps/api-ai/actions/summarize.action.ts +11 -0
- package/templates/apps/api-ai/package.json +8 -7
- package/templates/apps/api-auth/actions/me.action.ts +13 -0
- package/templates/apps/api-auth/package.json +9 -8
- package/templates/apps/api-backend/mutations/notes.create.mutation.ts +9 -0
- package/templates/apps/api-backend/package.json +12 -8
- package/templates/apps/api-backend/queries/notes.query.ts +30 -8
- package/templates/apps/api-backend-deactivation/actions/users.get.action.ts +14 -0
- package/templates/apps/api-backend-deactivation/mutations/users.create.mutation.ts +8 -0
- package/templates/apps/api-backend-deactivation/mutations/users.deactivate.mutation.ts +10 -0
- package/templates/apps/api-backend-deactivation/package.json +8 -7
- package/templates/apps/api-backend-mail/actions/sendWelcome.action.ts +17 -0
- package/templates/apps/api-backend-mail/mutations/notes.create.mutation.ts +9 -0
- package/templates/apps/api-backend-mail/package.json +9 -8
- package/templates/apps/api-backend-mail/queries/notes.query.ts +30 -8
- package/templates/apps/api-backend-mariadb/.env.example +14 -0
- package/templates/apps/api-backend-mariadb/mutations/notes.create.mutation.ts +9 -0
- package/templates/apps/api-backend-mariadb/package.json +10 -9
- package/templates/apps/api-backend-mariadb/queries/notes.query.ts +30 -8
- package/templates/apps/api-backend-sqlite/.env.example +14 -0
- package/templates/apps/api-backend-sqlite/mutations/notes.create.mutation.ts +9 -0
- package/templates/apps/api-backend-sqlite/package.json +9 -8
- package/templates/apps/api-backend-sqlite/queries/notes.query.ts +30 -8
- package/templates/apps/api-backend-storage/actions/uploadAvatar.action.ts +13 -0
- package/templates/apps/api-backend-storage/actions/uploadDocument.action.ts +12 -0
- package/templates/apps/api-backend-storage/mutations/notes.create.mutation.ts +9 -0
- package/templates/apps/api-backend-storage/package.json +9 -8
- package/templates/apps/api-backend-storage/queries/notes.query.ts +30 -8
- package/templates/apps/api-cms/actions/content.get.action.ts +7 -0
- package/templates/apps/api-cms/actions/content.types.action.ts +6 -0
- package/templates/apps/api-cms/actions/me.action.ts +13 -0
- package/templates/apps/api-cms/app.config.ts +19 -0
- package/templates/apps/api-cms/authz.ts +63 -0
- package/templates/apps/api-cms/mutations/content.publish.mutation.ts +10 -0
- package/templates/apps/api-cms/mutations/content.saveDraft.mutation.ts +10 -0
- package/templates/apps/api-cms/mutations/content.unpublish.mutation.ts +5 -0
- package/templates/apps/api-cms/package.json +11 -10
- package/templates/apps/api-cms/queries/content.list.query.ts +23 -7
- package/templates/apps/api-cms/tests/accessDecisions.test.ts +121 -0
- package/templates/apps/api-cms/tests/content.descriptors.test.ts +8 -4
- package/templates/apps/api-collab/mutations/documents.create.mutation.ts +8 -0
- package/templates/apps/api-collab/mutations/documents.setBody.mutation.ts +13 -0
- package/templates/apps/api-collab/package.json +9 -8
- package/templates/apps/api-collab/queries/documents.query.ts +19 -7
- package/templates/apps/api-data-advanced/package.json +9 -8
- package/templates/apps/api-data-advanced/queries/authors.withBooks.query.ts +12 -0
- package/templates/apps/api-data-advanced/queries/books.search.query.ts +9 -0
- package/templates/apps/api-durable/mutations/orders.approve.mutation.ts +17 -0
- package/templates/apps/api-durable/mutations/orders.place.mutation.ts +9 -0
- package/templates/apps/api-durable/package.json +9 -8
- package/templates/apps/api-feature-flags/actions/notes.export.action.ts +16 -0
- package/templates/apps/api-feature-flags/mutations/notes.create.mutation.ts +12 -0
- package/templates/apps/api-feature-flags/package.json +10 -9
- package/templates/apps/api-governance/README.md +30 -8
- package/templates/apps/api-governance/actions/profiles.get.action.server.ts +17 -1
- package/templates/apps/api-governance/actions/profiles.get.action.ts +29 -4
- package/templates/apps/api-governance/database/schema.ts +16 -4
- package/templates/apps/api-governance/mutations/profiles.create.mutation.ts +12 -0
- package/templates/apps/api-governance/package.json +9 -8
- package/templates/apps/api-kv/actions/sync.pull.action.ts +15 -0
- package/templates/apps/api-kv/actions/sync.reset.action.ts +13 -0
- package/templates/apps/api-kv/actions/sync.status.action.ts +7 -0
- package/templates/apps/api-kv/package.json +9 -8
- package/templates/apps/api-kv/queries/events.list.query.ts +19 -8
- package/templates/apps/api-moderation/mutations/comments.create.mutation.ts +11 -0
- package/templates/apps/api-moderation/mutations/posts.create.mutation.ts +13 -0
- package/templates/apps/api-moderation/package.json +9 -8
- package/templates/apps/api-observability/mutations/notes.create.mutation.ts +8 -0
- package/templates/apps/api-observability/package.json +9 -8
- package/templates/apps/api-observability/queries/notes.list.query.ts +13 -0
- package/templates/apps/api-ratelimit/mutations/notes.create.mutation.ts +14 -0
- package/templates/apps/api-ratelimit/package.json +9 -8
- package/templates/apps/api-rbac/package.json +9 -8
- package/templates/apps/api-rest/package.json +8 -7
- package/templates/apps/api-saas/mutations/projects.create.mutation.ts +13 -0
- package/templates/apps/api-saas/package.json +12 -11
- package/templates/apps/api-saas/queries/projects.list.query.ts +11 -0
- package/templates/apps/api-saas-starter/actions/me.action.ts +13 -0
- package/templates/apps/api-saas-starter/app.config.ts +19 -0
- package/templates/apps/api-saas-starter/authz.ts +75 -0
- package/templates/apps/api-saas-starter/mutations/invites.create.mutation.ts +10 -0
- package/templates/apps/api-saas-starter/mutations/projects.create.mutation.ts +9 -0
- package/templates/apps/api-saas-starter/package.json +15 -11
- package/templates/apps/api-saas-starter/queries/invites.list.query.ts +19 -8
- package/templates/apps/api-saas-starter/queries/projects.list.query.ts +18 -7
- package/templates/apps/api-saas-starter/tests/accessDecisions.test.ts +135 -0
- package/templates/apps/api-search/mutations/articles.create.mutation.ts +14 -0
- package/templates/apps/api-search/package.json +9 -8
- package/templates/apps/api-search/queries/articles.list.query.ts +21 -8
- package/templates/apps/api-status/README.md +10 -3
- package/templates/apps/api-status/app.config.ts +8 -3
- package/templates/apps/api-status/authz.ts +5 -3
- package/templates/apps/api-status/package.json +9 -8
- package/templates/apps/api-status/queries/components.list.query.ts +14 -6
- package/templates/apps/api-status/queries/incidents.live.query.ts +23 -10
- package/templates/apps/api-status/queries/updates.list.query.ts +16 -9
- package/templates/apps/api-status/tests/status.test.ts +9 -1
- package/templates/apps/api-versioning/actions/documents.asOf.action.ts +12 -0
- package/templates/apps/api-versioning/actions/documents.history.action.ts +13 -0
- package/templates/apps/api-versioning/mutations/documents.create.mutation.ts +9 -0
- package/templates/apps/api-versioning/mutations/documents.update.mutation.ts +12 -0
- package/templates/apps/api-versioning/package.json +9 -8
- package/templates/apps/api-webhooks/mutations/orders.fulfill.mutation.ts +16 -0
- package/templates/apps/api-webhooks/package.json +10 -9
- package/templates/apps/api-webhooks/queries/orders.list.query.ts +10 -0
- package/templates/apps/changelog/package.json +8 -6
- package/templates/apps/edge-functions/package.json +2 -2
- package/templates/apps/frontend-admin/package.json +10 -8
- package/templates/apps/frontend-admin/src/lib/admin.ts +20 -9
- package/templates/apps/frontend-admin/src/locales/de.ts +11 -1
- package/templates/apps/frontend-admin/src/locales/en.ts +13 -1
- package/templates/apps/frontend-admin/src/pages/admin/[entity]/page.tsx +65 -22
- package/templates/apps/frontend-admin/src/pages/admin/entity.test.tsx +130 -23
- package/templates/apps/frontend-admin/src/pages/admin/layout.tsx +3 -2
- package/templates/apps/frontend-admin/src/pages/admin/page.test.tsx +19 -2
- package/templates/apps/frontend-admin/src/pages/admin/page.tsx +9 -4
- package/templates/apps/frontend-app/app.config.ts +4 -3
- package/templates/apps/frontend-app/package.json +11 -8
- package/templates/apps/frontend-app/src/lib/api.ts +25 -0
- package/templates/apps/frontend-app/src/pages/page.test.tsx +130 -82
- package/templates/apps/frontend-app/src/pages/page.tsx +14 -18
- package/templates/apps/frontend-auth/package.json +10 -8
- package/templates/apps/frontend-blank/package.json +9 -7
- package/templates/apps/frontend-cms/package.json +11 -9
- package/templates/apps/frontend-collab/package.json +12 -9
- package/templates/apps/frontend-collab/src/pages/page.test.tsx +122 -78
- package/templates/apps/frontend-contact/package.json +9 -7
- package/templates/apps/frontend-dashboard/package.json +9 -7
- package/templates/apps/frontend-docs/package.json +9 -7
- package/templates/apps/frontend-i18n/package.json +8 -6
- package/templates/apps/frontend-landing/package.json +9 -7
- package/templates/apps/frontend-portal/package.json +10 -8
- package/templates/apps/frontend-saas/app.config.ts +10 -6
- package/templates/apps/frontend-saas/package.json +10 -8
- package/templates/apps/frontend-saas/src/lib/api.ts +27 -32
- package/templates/apps/frontend-saas/src/pages/dashboard/billing/page.tsx +7 -8
- package/templates/apps/frontend-saas/src/pages/dashboard/page.test.tsx +27 -3
- package/templates/apps/frontend-saas/src/pages/dashboard/page.tsx +4 -4
- package/templates/apps/frontend-saas/src/pages/dashboard/team/page.tsx +3 -4
- package/templates/apps/frontend-spa/package.json +9 -7
- package/templates/apps/frontend-ssr/package.json +9 -7
- package/templates/apps/frontend-ssr-api/package.json +10 -8
- package/templates/apps/frontend-static-blog/package.json +8 -6
- package/templates/apps/frontend-status/package.json +10 -8
- package/templates/apps/mobile-app/README.md +1 -0
- package/templates/apps/mobile-app/package.json +4 -2
- package/templates/apps/mobile-app/src/app/index.tsx +22 -12
- package/templates/apps/mobile-app/src/app/orders/[id].tsx +1 -1
- package/templates/apps/mobile-app/src/lib/api.ts +34 -0
- package/templates/apps/mobile-app/voltro.mobile.ts +4 -2
- package/templates/baselines/bare/.env.example +14 -0
- package/templates/baselines/bare/baseline.json +4 -4
- package/templates/baselines/compose/.env.example +14 -0
- package/templates/baselines/compose/README.md +1 -1
- package/templates/baselines/compose/baseline.json +5 -5
- package/templates/baselines/compose-mariadb/.env.example +14 -0
- package/templates/baselines/compose-mariadb/README.md +1 -1
- package/templates/baselines/compose-mariadb/baseline.json +5 -5
- package/templates/baselines/helm/.env.example +14 -0
- package/templates/baselines/helm/baseline.json +4 -4
- package/dist/apiBuild-C-x9YacA.js +0 -2
- package/dist/checkCommand-DRovTKza.js +0 -2
- package/dist/commands-CJfepbm4.js +0 -11541
- package/dist/dbCommand-b1gum4td.js +0 -2
- package/dist/dev-iiMtlkfs.js +0 -3
- package/dist/devActivity-BhIu6ncs.js +0 -159
- package/dist/frameworkTableAssembly-D-EebUQX.js +0 -2
- package/dist/inspect-mmBuRXmy.js +0 -2
- package/dist/manifestBuild-Dj8Jjoto.js +0 -2
- package/dist/seedRunner-Bqxgp7HZ.js +0 -230
- package/dist/serveCommand-DdaM4Hup.js +0 -1608
- package/dist/start-C0koT0UO.js +0 -1084
- /package/templates/apps/api-ai/actions/{summarize.action.server.tsx → summarize.action.server.ts} +0 -0
|
@@ -0,0 +1,808 @@
|
|
|
1
|
+
import { dirname as e, join as t, resolve as n } from "node:path";
|
|
2
|
+
import { readFileSync as r } from "node:fs";
|
|
3
|
+
import { fileURLToPath as i } from "node:url";
|
|
4
|
+
//#region src/commands.ts
|
|
5
|
+
var a = () => {
|
|
6
|
+
try {
|
|
7
|
+
let n = t(e(i(import.meta.url)), "..", "package.json");
|
|
8
|
+
return JSON.parse(r(n, "utf8")).version ?? "0.0.0";
|
|
9
|
+
} catch {
|
|
10
|
+
return "0.0.0";
|
|
11
|
+
}
|
|
12
|
+
}, o = [
|
|
13
|
+
{
|
|
14
|
+
name: "list-templates",
|
|
15
|
+
summary: "List available app templates (kind, summary, tags).",
|
|
16
|
+
status: "wired",
|
|
17
|
+
run: (e) => import("./projectScaffold-DmzEKHib.js").then((t) => t.runListTemplates(e)),
|
|
18
|
+
help: {
|
|
19
|
+
usage: "",
|
|
20
|
+
examples: [["voltro list-templates", "every template `create-project` / `add-app` can scaffold"]]
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
name: "create-project",
|
|
25
|
+
summary: "Scaffold a new project under apps/<name>/ from one or more templates (creates the workspace root when there is none).",
|
|
26
|
+
status: "wired",
|
|
27
|
+
run: (e) => import("./projectScaffold-DmzEKHib.js").then((t) => t.runCreateProject(e)),
|
|
28
|
+
help: {
|
|
29
|
+
usage: "<name> [--api <templateId>] [--web <templateId>] [--mobile[=<templateId>]] [--no-register]",
|
|
30
|
+
flags: [
|
|
31
|
+
["--api <templateId>", "api template to scaffold (see `voltro list-templates`)"],
|
|
32
|
+
["--web <templateId>", "web template to scaffold alongside the api"],
|
|
33
|
+
["--mobile[=<templateId>]", "also scaffold an Expo app (defaults to `mobile-app`)"],
|
|
34
|
+
["--no-register", "do NOT contact the cloud control plane (offline / CI / evaluating)"]
|
|
35
|
+
],
|
|
36
|
+
examples: [["voltro create-project acme", "the default api + web pair"], ["voltro create-project acme --api api-basic --no-register", "api only, no network call"]],
|
|
37
|
+
notes: [
|
|
38
|
+
"When there is no workspace root above the cwd this creates one (pnpm-workspace.yaml,",
|
|
39
|
+
"root package.json scripts, tsconfig.base.json, .gitignore, `git init`).",
|
|
40
|
+
"Registration only happens when you are LOGGED IN (`voltro cloud login`); logged out it",
|
|
41
|
+
"makes no network call at all. See `voltro create-project --help` output at scaffold time."
|
|
42
|
+
]
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
name: "package",
|
|
47
|
+
handlesHelp: !0,
|
|
48
|
+
summary: "Scaffold/convert workspace packages. Subcommands: create <name> [--publishable], publishable <name>, private <name>, status.",
|
|
49
|
+
status: "wired",
|
|
50
|
+
run: (e) => import("./packageCommand-Cug_3Ogl.js").then((t) => t.runPackageCommand(e))
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
name: "create-package",
|
|
54
|
+
summary: "Scaffold a new workspace package (alias of `package create`). Use --publishable for npm-ready setup.",
|
|
55
|
+
status: "wired",
|
|
56
|
+
run: (e) => import("./packageCommand-Cug_3Ogl.js").then((t) => t.runCreatePackage(e)),
|
|
57
|
+
help: {
|
|
58
|
+
usage: "<name> [--publishable]",
|
|
59
|
+
flags: [["--publishable", "npm-ready setup (build + exports + publishConfig) instead of a private package"]],
|
|
60
|
+
examples: [["voltro create-package shared", "a private workspace package"], ["voltro create-package sdk --publishable", "an npm-publishable one"]]
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
name: "add-app",
|
|
65
|
+
summary: "Add a new app to an existing project from a template. Usage: voltro add-app <appName> --template <id> [--to <projectName>].",
|
|
66
|
+
status: "wired",
|
|
67
|
+
run: (e) => import("./projectScaffold-DmzEKHib.js").then((t) => t.runAddApp(e)),
|
|
68
|
+
help: {
|
|
69
|
+
usage: "<appName> --template <templateId> [--to <projectName>] [--no-register]",
|
|
70
|
+
flags: [
|
|
71
|
+
["--template <id>", "which template to scaffold (see `voltro list-templates`)"],
|
|
72
|
+
["--to <projectName>", "the project to add it to (default: the workspace's single project)"],
|
|
73
|
+
["--no-register", "do NOT contact the cloud control plane (offline / CI / evaluating)"]
|
|
74
|
+
],
|
|
75
|
+
examples: [["voltro add-app admin --template web-dashboard", "add a dashboard app"]]
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
name: "init",
|
|
80
|
+
summary: "Initialise the current directory as a Voltro workspace root (pnpm-workspace.yaml, root scripts, .gitignore, git init). Idempotent; takes no arguments.",
|
|
81
|
+
status: "wired",
|
|
82
|
+
run: (e) => import("./metaCommands-7MJfZ5cf.js").then((t) => t.runInit(e)),
|
|
83
|
+
help: {
|
|
84
|
+
usage: "",
|
|
85
|
+
examples: [["voltro init", "make the current directory a workspace root, then `voltro create-project <name>`"]],
|
|
86
|
+
notes: ["Idempotent — safe to re-run; it only writes what is missing."]
|
|
87
|
+
}
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
name: "dev",
|
|
91
|
+
summary: "Start the local development server (auto-discovers routes / mutations).",
|
|
92
|
+
status: "wired",
|
|
93
|
+
run: (e) => import("./dev-CoG-ZPx8.js").then((t) => t.runDev(e)),
|
|
94
|
+
help: {
|
|
95
|
+
usage: "[app]",
|
|
96
|
+
examples: [["voltro dev", "boot the app in the current directory"], ["voltro dev apps/acme/api", "boot a specific app"]],
|
|
97
|
+
env: [
|
|
98
|
+
["PORT", "override the port from app.config.ts"],
|
|
99
|
+
["WATCH=0", "run the server directly, with no file-watching supervisor"],
|
|
100
|
+
["WATCH_POLL=1", "poll instead of using native FS events (bind-mounts: k8s hostPath / Docker)"],
|
|
101
|
+
["WATCH_DEBUG=1", "log every watcher event"],
|
|
102
|
+
["VOLTRO_DEV_HEALTH_PORT", "the boot-health probe port (default: app port + 1; 0 disables)"]
|
|
103
|
+
],
|
|
104
|
+
notes: ["A web app (app.config.ts `type: 'web'`) gets the Vite dev server instead; an api gets the", "rpc/ws server plus a supervisor that restarts it when a source file changes."]
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
name: "dashboard",
|
|
109
|
+
summary: "Serve the DevTools dashboard standalone (from @voltro/dashboard). Targets via VOLTRO_DASHBOARD_APPS; --port to override.",
|
|
110
|
+
status: "wired",
|
|
111
|
+
run: (e) => import("./dashboardCommand-3YG8p-UA.js").then((t) => t.runDashboardCommand(e)),
|
|
112
|
+
help: {
|
|
113
|
+
usage: "[--port <n>]",
|
|
114
|
+
flags: [["--port <n>", "port to serve the dashboard on"]],
|
|
115
|
+
env: [["VOLTRO_DASHBOARD_APPS", "comma-separated app roots the dashboard should target"]],
|
|
116
|
+
examples: [["voltro dashboard --port 4321", "serve the DevTools dashboard"]]
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
name: "check",
|
|
121
|
+
summary: "Verify the app graph (blast-radius checks) against a running api; LLM-shaped --json diagnostics. Flags: --json, --process <p>, --diff removeTable:<name>.",
|
|
122
|
+
status: "wired",
|
|
123
|
+
run: (e) => import("./checkCommand-YZDmkAGd.js").then((t) => t.runCheckCommand(e)),
|
|
124
|
+
help: {
|
|
125
|
+
usage: "[--json] [--offline] [--process <name>] [--diff removeTable:<name>]",
|
|
126
|
+
flags: [
|
|
127
|
+
["--json", "LLM/CI-shaped diagnostics on stdout"],
|
|
128
|
+
["--offline", "check from static discovery instead of a running api"],
|
|
129
|
+
["--process <name>", "which running api to query"],
|
|
130
|
+
["--url <url>", "query an api at an explicit url"],
|
|
131
|
+
["--diff removeTable:<name>", "blast radius of a hypothetical change"],
|
|
132
|
+
["--format <fmt>", "output format"]
|
|
133
|
+
],
|
|
134
|
+
examples: [["voltro check --json", "machine-readable diagnostics for an agent or CI"], ["voltro check --diff removeTable:notes", "what would break if `notes` went away"]]
|
|
135
|
+
}
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
name: "eval",
|
|
139
|
+
summary: "Replay recorded agent/AI runs (*.eval.ts) against the current model, judge with assertions + an optional LLM judge, and gate the deploy (exit 1 on regression). Flags: --json, --branch [--pr <n>], --threshold <0..1>.",
|
|
140
|
+
status: "wired",
|
|
141
|
+
run: (e) => import("./evalCommand-6RUfPen4.js").then((t) => t.runEvalCommand(e)),
|
|
142
|
+
help: {
|
|
143
|
+
usage: "[--json] [--branch [--pr <n>]] [--threshold <0..1>]",
|
|
144
|
+
flags: [
|
|
145
|
+
["--json", "machine-readable results"],
|
|
146
|
+
["--branch", "compare against the base branch instead of an absolute floor"],
|
|
147
|
+
["--pr <n>", "the PR number to annotate (with --branch)"],
|
|
148
|
+
["--threshold <0..1>", "minimum pass rate before the command fails"]
|
|
149
|
+
],
|
|
150
|
+
examples: [["voltro eval --branch --threshold 0.9", "gate a deploy on the recorded agent runs"]]
|
|
151
|
+
}
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
name: "webhooks",
|
|
155
|
+
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].",
|
|
156
|
+
status: "wired",
|
|
157
|
+
run: (e) => import("./webhooksCommand-CID96Rga.js").then((t) => t.runWebhooksCommand(e)),
|
|
158
|
+
help: {
|
|
159
|
+
usage: "<consumer|events> [path] [--out <dir>] [--name <pkg>] [--json]",
|
|
160
|
+
flags: [
|
|
161
|
+
["--out <dir>", "where to write the generated package (default `<root>/webhook-consumer`)"],
|
|
162
|
+
["--name <pkg>", "npm package name for the generated package (default `<app>-webhooks`)"],
|
|
163
|
+
["--json", "machine-readable event list (`events` only)"]
|
|
164
|
+
],
|
|
165
|
+
examples: [["voltro webhooks consumer --out ../partner-sdk", "generate the package your subscribers install"], ["voltro webhooks events --json", "list the outbound events a subscriber can register for"]],
|
|
166
|
+
notes: ["The generated package has NO runtime dependencies — it imports `node:crypto` and nothing else, because it runs in the subscriber's service rather than in a Voltro app.", "Payload types are generated from each event's Schema and are TYPES ONLY; no decoder ships. The signature is what proves a delivery is genuine."]
|
|
167
|
+
}
|
|
168
|
+
},
|
|
169
|
+
{
|
|
170
|
+
name: "evolve",
|
|
171
|
+
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].",
|
|
172
|
+
status: "wired",
|
|
173
|
+
run: (e) => import("./evolveCommand-DHpkgjgH.js").then((t) => t.runEvolveCommand(e)),
|
|
174
|
+
help: {
|
|
175
|
+
usage: "<rename-column|rename-table|retype-column|split-column|drop-column> <target> [--to <new>] [--write]",
|
|
176
|
+
flags: [
|
|
177
|
+
["--to <new>", "the new name / type"],
|
|
178
|
+
["--into <a,b>", "target columns for `split-column`"],
|
|
179
|
+
["--write", "apply the proposal (dry-run is the default)"],
|
|
180
|
+
["--json", "machine-readable proposal"],
|
|
181
|
+
["--threshold <0..1>", "confidence floor for the observed-graph proposal"]
|
|
182
|
+
],
|
|
183
|
+
examples: [["voltro evolve rename-column notes.body --to content", "propose the codemod + backfill"], ["voltro evolve rename-column notes.body --to content --write", "apply it"]]
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
name: "codegen",
|
|
188
|
+
summary: "Emit rpcGroup.generated.ts from discovered route / mutation descriptors.",
|
|
189
|
+
status: "wired",
|
|
190
|
+
run: (e) => import("./codegenCommand-DC6w2tNZ.js").then((t) => t.runCodegenCommand(e)),
|
|
191
|
+
help: {
|
|
192
|
+
usage: "[app]",
|
|
193
|
+
examples: [["voltro codegen", "regenerate rpcGroup.generated.ts for the app in the cwd"]],
|
|
194
|
+
notes: ["`voltro dev` and `voltro build` regenerate it themselves; run this by hand when a", "`voltro test` / typecheck reports the generated group is stale."]
|
|
195
|
+
}
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
name: "migrate",
|
|
199
|
+
summary: "Apply the declared schema to the database (alias of `db apply` — diffs declared vs live and emits the ALTERs). `--create-only` for the bootstrap-only CREATE TABLE IF NOT EXISTS path.",
|
|
200
|
+
status: "wired",
|
|
201
|
+
run: (e) => import("./migrate-CBwOt_iV.js").then((t) => t.runMigrateCommand(e)),
|
|
202
|
+
help: {
|
|
203
|
+
usage: "[app] [--create-only]",
|
|
204
|
+
flags: [["--create-only", "only CREATE TABLE IF NOT EXISTS — never ALTER (bootstrap)"]],
|
|
205
|
+
examples: [["voltro migrate", "diff declared vs live and apply the ALTERs"]],
|
|
206
|
+
notes: ["Alias of `voltro db apply`. `voltro db plan` shows the same diff without applying it."]
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
name: "test",
|
|
211
|
+
summary: "Run vitest against the app at the cwd (auto-discovers *.test.ts/tsx).",
|
|
212
|
+
status: "wired",
|
|
213
|
+
run: (e) => import("./test-CI6iDsYc.js").then((t) => t.runTestCommand(e)),
|
|
214
|
+
help: {
|
|
215
|
+
usage: "[dir] [filter…] [--watch] [-t <pattern>]",
|
|
216
|
+
flags: [
|
|
217
|
+
["--watch", "re-run on change"],
|
|
218
|
+
["-t <pattern>", "only tests whose name matches (alias: --testNamePattern)"],
|
|
219
|
+
["--exclude <glob>", "replace the default exclude set"]
|
|
220
|
+
],
|
|
221
|
+
examples: [
|
|
222
|
+
["voltro test", "every test under the current directory"],
|
|
223
|
+
["voltro test apps/acme/api", "a DIRECTORY selects the root"],
|
|
224
|
+
["voltro test notes", "anything else is a filter — matches file names + test names"]
|
|
225
|
+
],
|
|
226
|
+
notes: [
|
|
227
|
+
"A positional is a root only when it is an existing directory; everything else filters.",
|
|
228
|
+
"A filter that matches nothing FAILS (exit 1) rather than passing with no tests.",
|
|
229
|
+
"`e2e/**/*.spec.ts` is excluded — those belong to `voltro e2e`.",
|
|
230
|
+
"This TRANSPILES without type-checking; run `voltro typecheck` too."
|
|
231
|
+
]
|
|
232
|
+
}
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
name: "typecheck",
|
|
236
|
+
summary: "Type-check the app with tsc --noEmit, using the TypeScript it pins. Optional [app] path and --project <tsconfig>; any other flags pass straight through to tsc.",
|
|
237
|
+
status: "wired",
|
|
238
|
+
run: (e) => import("./typecheckCommand-BlsWiCNq.js").then((t) => t.runTypecheckCommand(e)),
|
|
239
|
+
help: {
|
|
240
|
+
usage: "[app] [--project <tsconfig>] [… tsc flags]",
|
|
241
|
+
flags: [["--project <tsconfig>", "the tsconfig to use (alias: -p)"]],
|
|
242
|
+
examples: [["voltro typecheck", "type-check the app in the cwd"], ["voltro typecheck apps/acme/api --project tsconfig.build.json", "a specific project"]],
|
|
243
|
+
notes: ["Any flag this does not recognise is forwarded verbatim to `tsc`."]
|
|
244
|
+
}
|
|
245
|
+
},
|
|
246
|
+
{
|
|
247
|
+
name: "new",
|
|
248
|
+
summary: "Scaffold a primitive with the right file convention(s). Usage: voltro new <query|mutation|action|workflow|page> <name> [--dir <path>] [--force].",
|
|
249
|
+
status: "wired",
|
|
250
|
+
run: (e) => import("./newCommand-COWOJ1_E.js").then((t) => t.runNewCommand(e)),
|
|
251
|
+
help: {
|
|
252
|
+
usage: "<query|mutation|action|workflow|page> <name> [--dir <path>] [--force]",
|
|
253
|
+
flags: [["--dir <path>", "where to write it (default: the convention directory for that kind)"], ["--force", "overwrite an existing file"]],
|
|
254
|
+
examples: [["voltro new query notes.list", "a descriptor + its `.server.ts` executor"], ["voltro new workflow onboarding", "the descriptor / executor workflow pair"]]
|
|
255
|
+
}
|
|
256
|
+
},
|
|
257
|
+
{
|
|
258
|
+
name: "info",
|
|
259
|
+
summary: "Report versions (CLI, node, every installed @voltro/* — flags lockstep skew), package manager, and dialect. --json for CI. Exits 1 on version skew.",
|
|
260
|
+
status: "wired",
|
|
261
|
+
run: (e) => import("./infoCommand-BJw9nLUR.js").then((t) => t.runInfoCommand(e)),
|
|
262
|
+
help: {
|
|
263
|
+
usage: "[--json]",
|
|
264
|
+
flags: [["--json", "machine-readable report"]],
|
|
265
|
+
examples: [["voltro info", "versions + package manager + dialect; exits 1 on lockstep skew"]]
|
|
266
|
+
}
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
name: "cache",
|
|
270
|
+
summary: "Inspect/operate the cache backend. Subcommands: status, flush, invalidate <tag>.",
|
|
271
|
+
status: "wired",
|
|
272
|
+
run: (e) => import("./cacheCommand-DA4OH9xt.js").then((t) => t.runCacheCommand(e)),
|
|
273
|
+
help: {
|
|
274
|
+
usage: "<status|flush|invalidate <tag>>",
|
|
275
|
+
examples: [["voltro cache status", "which backend is live, and whether it is reachable"], ["voltro cache invalidate notes", "drop every entry carrying that tag"]]
|
|
276
|
+
}
|
|
277
|
+
},
|
|
278
|
+
{
|
|
279
|
+
name: "env",
|
|
280
|
+
summary: "Inspect/sync the typed-env manifest. Subcommands: check (default), sync (.env.example), types (env.generated.d.ts for CI tsc), turbo.",
|
|
281
|
+
status: "wired",
|
|
282
|
+
run: (e) => import("./envCommand-DPgdV1Bq.js").then((t) => t.runEnvCommand(e)),
|
|
283
|
+
help: {
|
|
284
|
+
usage: "[check|sync|types|turbo] [--force]",
|
|
285
|
+
flags: [["--force", "overwrite the generated file instead of refusing on a conflict"]],
|
|
286
|
+
examples: [
|
|
287
|
+
["voltro env", "validate the declared env against the process + .env files"],
|
|
288
|
+
["voltro env sync", "refresh .env.example from the declared manifest"],
|
|
289
|
+
["voltro env types", "emit env.generated.d.ts so CI `tsc` sees the typed accessors"]
|
|
290
|
+
]
|
|
291
|
+
}
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
name: "e2e",
|
|
295
|
+
summary: "For a web app: boot the api + web siblings, run each e2e/**/*.spec.ts as a plain tsx script (WEB_URL/API_URL in env), tear down.",
|
|
296
|
+
status: "wired",
|
|
297
|
+
run: (e) => import("./e2eCmd-BRabZww-.js").then((t) => t.runE2eCommand(e)),
|
|
298
|
+
help: {
|
|
299
|
+
usage: "[app]",
|
|
300
|
+
examples: [["voltro e2e", "boot api + web, run every e2e/**/*.spec.ts, tear down"]],
|
|
301
|
+
notes: ["Each spec runs as a plain tsx script with WEB_URL / API_URL in the environment —", "there is no bundled browser runner, so drive the browser with whatever your app depends on."]
|
|
302
|
+
}
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
name: "serve",
|
|
306
|
+
summary: "Production server: web app (vite preview) OR API (rpc + tenant scope + audit atomicity), auto-detected.",
|
|
307
|
+
status: "wired",
|
|
308
|
+
run: async (e) => {
|
|
309
|
+
let t = e.find((e) => !e.startsWith("-")) ?? process.cwd();
|
|
310
|
+
if (e.includes("--preflight")) {
|
|
311
|
+
let { runServePreflight: e } = await import("./doctorCommand-BvqGBwNG.js");
|
|
312
|
+
return e(n(t), !0);
|
|
313
|
+
}
|
|
314
|
+
let { tryRunWebServe: r } = await import("./webDev-Cg-fFiyd2.js"), i = await r(n(t));
|
|
315
|
+
if (!i.ran) {
|
|
316
|
+
let { runServeDispatch: t } = await import("./serveCommand-DOvbgRnQ.js");
|
|
317
|
+
return t(e);
|
|
318
|
+
}
|
|
319
|
+
return i.exitCode;
|
|
320
|
+
},
|
|
321
|
+
help: {
|
|
322
|
+
usage: "[app] [--preflight]",
|
|
323
|
+
flags: [["--preflight", "check serve-bundle readiness and exit 1 if it is missing — never boots"]],
|
|
324
|
+
examples: [["voltro serve", "production server for the app in the cwd (api or web, auto-detected)"], ["voltro serve . --preflight", "a Dockerfile/CI gate that catches \"prod serve, no build\""]],
|
|
325
|
+
notes: ["In production a precompiled bundle is MANDATORY — run `voltro build` first."]
|
|
326
|
+
}
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
name: "capabilities",
|
|
330
|
+
summary: "The framework's export surface, read from the installed @voltro packages (--json for the machine-readable form).",
|
|
331
|
+
status: "wired",
|
|
332
|
+
run: (e) => import("./capabilitiesCommand-nq_pz5xd.js").then((t) => t.runCapabilitiesCommand(e)),
|
|
333
|
+
help: {
|
|
334
|
+
usage: "[--json]",
|
|
335
|
+
flags: [["--json", "machine-readable export surface"]],
|
|
336
|
+
examples: [["voltro capabilities --json", "what this installed framework version can do"]]
|
|
337
|
+
}
|
|
338
|
+
},
|
|
339
|
+
{
|
|
340
|
+
name: "doctor",
|
|
341
|
+
handlesHelp: !0,
|
|
342
|
+
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.",
|
|
343
|
+
status: "wired",
|
|
344
|
+
run: (e) => import("./doctorCommand-BvqGBwNG.js").then((t) => t.runDoctorCommand(e))
|
|
345
|
+
},
|
|
346
|
+
{
|
|
347
|
+
name: "build",
|
|
348
|
+
summary: "Production build for a web app (vite build + per-page SSG pre-render).",
|
|
349
|
+
status: "wired",
|
|
350
|
+
run: (e) => import("./build-CE7Ca9gm.js").then((t) => t.runBuildCommand(e)),
|
|
351
|
+
help: {
|
|
352
|
+
usage: "[app] [--target <t>]",
|
|
353
|
+
flags: [["--target <t>", "build target"]],
|
|
354
|
+
examples: [["voltro build", "production build for the app in the cwd"]],
|
|
355
|
+
notes: [
|
|
356
|
+
"A web app gets the vite build + per-page SSG prerender + the start bundle; an api gets",
|
|
357
|
+
"the precompiled serve bundle. Both regenerate their generated files first, so a clean",
|
|
358
|
+
"CI checkout builds without a `voltro dev` boot."
|
|
359
|
+
]
|
|
360
|
+
}
|
|
361
|
+
},
|
|
362
|
+
{
|
|
363
|
+
name: "prune-runtime",
|
|
364
|
+
summary: "Trim a deployed web tree’s node_modules to the reachable runtime set (standalone image slimming).",
|
|
365
|
+
status: "wired",
|
|
366
|
+
run: (e) => import("./runtimeTrace-CRxalXTs.js").then((t) => t.runPruneRuntimeCommand(e)),
|
|
367
|
+
hidden: !0
|
|
368
|
+
},
|
|
369
|
+
{
|
|
370
|
+
name: "generate",
|
|
371
|
+
summary: "AI app-builder (round-2/06): generate app graph + files from a prompt, gated by `voltro check`. Dry-run by default; --write applies. Usage: voltro generate \"<prompt>\" [--write].",
|
|
372
|
+
status: "wired",
|
|
373
|
+
run: (e) => import("./generateCommand-oibemh97.js").then((t) => t.runGenerateCommand(e)),
|
|
374
|
+
help: {
|
|
375
|
+
usage: "\"<prompt>\" [--write]",
|
|
376
|
+
flags: [["--write", "write the generated files (dry-run is the default)"]],
|
|
377
|
+
examples: [["voltro generate \"a notes app with tags\" --write", "generate + apply, gated by `voltro check`"]]
|
|
378
|
+
}
|
|
379
|
+
},
|
|
380
|
+
{
|
|
381
|
+
name: "dormancy",
|
|
382
|
+
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.",
|
|
383
|
+
status: "wired",
|
|
384
|
+
run: (e) => import("./dormancyCommand-Dszo57d6.js").then((t) => t.runDormancyCommand(e)),
|
|
385
|
+
help: {
|
|
386
|
+
usage: "[app] [--port <n>] [--app-port <n>] [--idle-grace-ms <n>] [--tick-ms <n>]",
|
|
387
|
+
flags: [
|
|
388
|
+
["--port <n>", "the port the wake-orchestrator listens on"],
|
|
389
|
+
["--app-port <n>", "the port it boots the app on"],
|
|
390
|
+
["--idle-grace-ms <n>", "how long an idle app stays up before being stopped"],
|
|
391
|
+
["--tick-ms <n>", "how often to check for idleness / due wakeups"]
|
|
392
|
+
],
|
|
393
|
+
examples: [["voltro dormancy --idle-grace-ms 60000", "scale to zero after a minute idle"]],
|
|
394
|
+
notes: ["Needs a SQL store — the wakeup ledger lives in the database."]
|
|
395
|
+
}
|
|
396
|
+
},
|
|
397
|
+
{
|
|
398
|
+
name: "start",
|
|
399
|
+
summary: "Production runtime: serves dist + SSR-on-demand for ssr/isr pages.",
|
|
400
|
+
status: "wired",
|
|
401
|
+
run: (e) => import("./start-B-9Nsp-S.js").then((t) => t.runStartCommand(e)),
|
|
402
|
+
help: {
|
|
403
|
+
usage: "[app]",
|
|
404
|
+
examples: [["voltro start", "serve a built web app (dist + SSR-on-demand)"]],
|
|
405
|
+
notes: ["Requires `voltro build` output — production never transpiles on demand."]
|
|
406
|
+
}
|
|
407
|
+
},
|
|
408
|
+
{
|
|
409
|
+
name: "deploy",
|
|
410
|
+
summary: "Show deploy options + `voltro deploy plan` auto-detects the target tier (static-cdn / container / functions) per app + function.",
|
|
411
|
+
status: "wired",
|
|
412
|
+
run: (e) => import("./metaCommands-7MJfZ5cf.js").then((t) => t.runDeploy(e)),
|
|
413
|
+
help: {
|
|
414
|
+
usage: "[plan]",
|
|
415
|
+
examples: [["voltro deploy plan", "the auto-detected target tier per app + function"]]
|
|
416
|
+
}
|
|
417
|
+
},
|
|
418
|
+
{
|
|
419
|
+
name: "serverless",
|
|
420
|
+
handlesHelp: !0,
|
|
421
|
+
summary: "Standalone *.serverless.ts functions. Subcommands: list, dev, serve, build, deploy [--target node|cloudflare|scaleway (default node)] [--dry-run].",
|
|
422
|
+
status: "wired",
|
|
423
|
+
run: (e) => import("./serverlessCommand-CfJZy6dS.js").then((t) => t.runServerlessCommand(e))
|
|
424
|
+
},
|
|
425
|
+
{
|
|
426
|
+
name: "static",
|
|
427
|
+
handlesHelp: !0,
|
|
428
|
+
summary: "Deploy a pre-built static site (./dist) to a cheap external host. Subcommands: hosts, deploy --host cloudflare-pages|s3|netlify [--spa] [--dry-run].",
|
|
429
|
+
status: "wired",
|
|
430
|
+
run: (e) => import("./staticCommand-Dr2M6tpU.js").then((t) => t.runStaticCommand(e))
|
|
431
|
+
},
|
|
432
|
+
{
|
|
433
|
+
name: "privacy",
|
|
434
|
+
summary: "GDPR / DSAR tooling. scope [root] — derive the subject graph from the schema AND print what it cannot see. export <subjectId> --url <app> / erase <subjectId> --url <app> --confirm — run against the RUNNING app's admin-gated governance endpoint, so the erasure log and configured anonymize fields apply.",
|
|
435
|
+
status: "wired",
|
|
436
|
+
run: (e) => import("./privacyCommand-C-Df56U_.js").then((t) => t.runPrivacyCommand(e)),
|
|
437
|
+
help: {
|
|
438
|
+
usage: "<scope|export|erase>",
|
|
439
|
+
examples: [
|
|
440
|
+
["voltro privacy scope --subject-table users", "every table a DSAR reaches, and every table it does not"],
|
|
441
|
+
["voltro privacy export usr_123 --url https://api.example.com", "the subject's portable bundle"],
|
|
442
|
+
["voltro privacy erase usr_123 --url https://api.example.com --confirm", "right-to-be-forgotten, logged"]
|
|
443
|
+
],
|
|
444
|
+
notes: [
|
|
445
|
+
"scope is OFFLINE — schema only, so it runs in CI and in a PR review.",
|
|
446
|
+
"export/erase need @voltro/plugin-governance installed in the target app and an inspect credential (--token / VOLTRO_INSPECT_TOKEN).",
|
|
447
|
+
"A derivation cannot see a subject id in a plain column, a polymorphic (type,id) pair, JSON, free text, object storage, logs or backups. `scope` lists what it missed; add subjectScopes for those."
|
|
448
|
+
]
|
|
449
|
+
}
|
|
450
|
+
},
|
|
451
|
+
{
|
|
452
|
+
name: "db",
|
|
453
|
+
summary: "Database subcommands. Declarative flow: plan, apply, branch, plans, drift [--accept], squash, restore-snapshot. File migrations: generate [name], migrate, rollback, status, files, rollback-file. Also: seed, gc-snapshots.",
|
|
454
|
+
status: "wired",
|
|
455
|
+
run: (e) => import("./dbCommand-CpdKLeQq.js").then((t) => t.runDbCommand(e)),
|
|
456
|
+
help: {
|
|
457
|
+
usage: "<plan|apply|branch|plans|drift|squash|restore-snapshot|generate|migrate|rollback|status|files|rollback-file|seed|gc-snapshots>",
|
|
458
|
+
examples: [
|
|
459
|
+
["voltro db plan", "the diff between the declared schema and the live database"],
|
|
460
|
+
["voltro db apply", "apply that diff"],
|
|
461
|
+
["voltro db branch --pr 128", "rehearse that diff on a throwaway branch of the live schema, then drop it"],
|
|
462
|
+
["voltro db drift", "what changed in the database behind the framework's back"]
|
|
463
|
+
],
|
|
464
|
+
notes: ["Run `voltro db <subcommand>` with no further args to see that subcommand's options."]
|
|
465
|
+
}
|
|
466
|
+
},
|
|
467
|
+
{
|
|
468
|
+
name: "data",
|
|
469
|
+
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.",
|
|
470
|
+
status: "wired",
|
|
471
|
+
run: (e) => import("./dataCommand-qL0r7fPO.js").then((t) => t.runDataCommand(e)),
|
|
472
|
+
help: {
|
|
473
|
+
usage: "<export|import|backup|restore> <dir> [options]",
|
|
474
|
+
flags: [
|
|
475
|
+
["--tenant <id>", "export one tenant's rows"],
|
|
476
|
+
["--tables <a,b>", "restrict to these tables"],
|
|
477
|
+
["--assets", "include blobs (logical path only)"],
|
|
478
|
+
["--compression <zstd|gzip|none>", "archive compression"],
|
|
479
|
+
["--consistency <live|snapshot>", "read live, or from a consistent snapshot"],
|
|
480
|
+
["--no-verify", "skip checksum verification on import"],
|
|
481
|
+
["--dry-run", "report what would move, write nothing"],
|
|
482
|
+
["--json", "machine-readable progress + result"]
|
|
483
|
+
],
|
|
484
|
+
examples: [["voltro data export ./dump --assets", "rows + blobs, resumable, typed NDJSON"], ["voltro data backup ./dump", "native dump (rows ONLY — no blobs)"]]
|
|
485
|
+
}
|
|
486
|
+
},
|
|
487
|
+
{
|
|
488
|
+
name: "storage",
|
|
489
|
+
summary: "Diagnose the configured storage backend. Subcommands: doctor (probe reachability, read/write, publicUrl, memory-in-prod), cors (print recommended bucket CORS for presigned uploads).",
|
|
490
|
+
status: "wired",
|
|
491
|
+
run: (e) => import("./storageCommand-Co6NfLqN.js").then((t) => t.runStorageCommand(e)),
|
|
492
|
+
help: {
|
|
493
|
+
usage: "<doctor|cors>",
|
|
494
|
+
examples: [["voltro storage doctor", "probe reachability, read/write, publicUrl, memory-in-prod"], ["voltro storage cors", "the bucket CORS presigned uploads need"]]
|
|
495
|
+
}
|
|
496
|
+
},
|
|
497
|
+
{
|
|
498
|
+
name: "baseline",
|
|
499
|
+
handlesHelp: !0,
|
|
500
|
+
summary: "Manage the project deploy baseline (bare / compose / helm). Subcommands: list, status, set.",
|
|
501
|
+
status: "wired",
|
|
502
|
+
run: (e) => import("./baselineCommand-C2ClWZN3.js").then((t) => t.runBaselineCommand(e))
|
|
503
|
+
},
|
|
504
|
+
{
|
|
505
|
+
name: "add",
|
|
506
|
+
summary: "Add an infra-backed integration to the project. Subcommands: redis (Redis cache backend + compose/helm/.env wiring); mssql (SQL Server store + the @effect/cluster mssql patch so durable cluster workflows work).",
|
|
507
|
+
status: "wired",
|
|
508
|
+
run: (e) => import("./addCommand-aXSQveak.js").then((t) => t.runAddCommand(e)),
|
|
509
|
+
help: {
|
|
510
|
+
usage: "<redis|mssql>",
|
|
511
|
+
examples: [["voltro add redis", "Redis cache backend + compose/helm/.env wiring"], ["voltro add mssql", "SQL Server store + the @effect/cluster patch durable workflows need"]]
|
|
512
|
+
}
|
|
513
|
+
},
|
|
514
|
+
{
|
|
515
|
+
name: "secret",
|
|
516
|
+
handlesHelp: !0,
|
|
517
|
+
summary: "Generate strong secrets. `generate [purpose]` (data-transfer, session, bundle-key, field-encryption, …) emits the right var+format; `generate` alone prints a generic secret; `list` shows all. Encrypted per-env storage is in Voltro Cloud.",
|
|
518
|
+
status: "wired",
|
|
519
|
+
run: (e) => import("./metaCommands-7MJfZ5cf.js").then((t) => t.runSecret(e))
|
|
520
|
+
},
|
|
521
|
+
{
|
|
522
|
+
name: "update",
|
|
523
|
+
handlesHelp: !0,
|
|
524
|
+
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`.",
|
|
525
|
+
status: "wired",
|
|
526
|
+
run: (e) => import("./updateCommand-us1_hdIC.js").then((t) => t.runUpdateCommand(e))
|
|
527
|
+
},
|
|
528
|
+
{
|
|
529
|
+
name: "_apply-codemods",
|
|
530
|
+
summary: "Internal: apply shipped codemods for a framework version jump (re-exec target of `voltro update`).",
|
|
531
|
+
status: "wired",
|
|
532
|
+
hidden: !0,
|
|
533
|
+
run: (e) => import("./updateCommand-us1_hdIC.js").then((t) => t.runApplyCodemods(e))
|
|
534
|
+
},
|
|
535
|
+
{
|
|
536
|
+
name: "embeddings",
|
|
537
|
+
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.",
|
|
538
|
+
status: "wired",
|
|
539
|
+
run: (e) => import("./embeddingsCommand-C0sKVRo1.js").then((t) => t.runEmbeddingsCommand(e)),
|
|
540
|
+
help: {
|
|
541
|
+
usage: "backfill <table> --text <field> --vector <field> [--model <m>] [--batch <n>] [--dry-run]",
|
|
542
|
+
flags: [
|
|
543
|
+
["--text <field>", "the source text column"],
|
|
544
|
+
["--vector <field>", "the embedding column to fill"],
|
|
545
|
+
["--model <m>", "embedding model (default: the one the mixin declares)"],
|
|
546
|
+
["--model-field <f>", "column recording which model produced the vector"],
|
|
547
|
+
["--batch <n>", "rows per batch"],
|
|
548
|
+
["--dry-run", "report what would be embedded, write nothing"]
|
|
549
|
+
],
|
|
550
|
+
examples: [["voltro embeddings backfill notes --text body --vector embedding", "(re)embed rows the mixin missed"]]
|
|
551
|
+
}
|
|
552
|
+
},
|
|
553
|
+
{
|
|
554
|
+
name: "telemetry",
|
|
555
|
+
summary: "Report telemetry status — Voltro collects none (no phone-home, nothing to opt out of).",
|
|
556
|
+
status: "wired",
|
|
557
|
+
run: (e) => import("./metaCommands-7MJfZ5cf.js").then((t) => t.runTelemetry(e)),
|
|
558
|
+
help: {
|
|
559
|
+
usage: "",
|
|
560
|
+
examples: [["voltro telemetry", "confirm what is collected: nothing"]],
|
|
561
|
+
notes: [
|
|
562
|
+
"The framework itself phones home nowhere. The ONE network call the CLI makes on its own",
|
|
563
|
+
"is `create-project` / `add-app` cloud registration, and only when you are logged in —",
|
|
564
|
+
"pass `--no-register` to skip it."
|
|
565
|
+
]
|
|
566
|
+
}
|
|
567
|
+
},
|
|
568
|
+
{
|
|
569
|
+
name: "agents-md",
|
|
570
|
+
summary: "Write the framework-tailored AGENTS.md into the project root (use --force to overwrite).",
|
|
571
|
+
status: "wired",
|
|
572
|
+
run: (e) => import("./agentsMd-BTchIZku.js").then((t) => t.runAgentsMd(e)),
|
|
573
|
+
help: {
|
|
574
|
+
usage: "[--force]",
|
|
575
|
+
flags: [["--force", "overwrite existing files (both AGENTS.md and CLAUDE.md)"]],
|
|
576
|
+
examples: [["voltro agents-md --force", "refresh the seeded agent guide after a framework upgrade"]],
|
|
577
|
+
notes: ["A file whose first lines carry the `voltro:agents-md:keep` marker is never overwritten."]
|
|
578
|
+
}
|
|
579
|
+
},
|
|
580
|
+
{
|
|
581
|
+
name: "schedule",
|
|
582
|
+
summary: "Operate on registered schedules. `run <name>` fires one on demand (--process, --trigger manual|external, --url).",
|
|
583
|
+
status: "wired",
|
|
584
|
+
handlesHelp: !0,
|
|
585
|
+
run: (e) => import("./scheduleCmd--jksTrf6.js").then((t) => t.runScheduleCommand(e))
|
|
586
|
+
},
|
|
587
|
+
{
|
|
588
|
+
name: "schedule-manifest",
|
|
589
|
+
summary: "Emit external-scheduler config for trigger:'external' schedules. --provider kubernetes|aws|gcp|azure|generic --base-url <url>.",
|
|
590
|
+
status: "wired",
|
|
591
|
+
run: (e) => import("./scheduleManifestCmd-D2x0CTTY.js").then((t) => t.runScheduleManifest(e)),
|
|
592
|
+
help: {
|
|
593
|
+
usage: "--provider <kubernetes|aws|gcp|azure|generic> --base-url <url> [--token-env <VAR>]",
|
|
594
|
+
flags: [
|
|
595
|
+
["--provider <p>", "kubernetes | aws | gcp | azure | generic"],
|
|
596
|
+
["--base-url <url>", "the public url the external scheduler should call"],
|
|
597
|
+
["--token-env <VAR>", "env var the emitted config reads the auth token from"]
|
|
598
|
+
],
|
|
599
|
+
examples: [["voltro schedule-manifest --provider kubernetes --base-url https://api.example.com", "CronJob manifests for external schedules"]]
|
|
600
|
+
}
|
|
601
|
+
},
|
|
602
|
+
{
|
|
603
|
+
name: "logs",
|
|
604
|
+
handlesHelp: !0,
|
|
605
|
+
summary: "Tail recent log records from every running voltro process. --tail N --since 30s --level error --filter PAT --format json|pretty|text.",
|
|
606
|
+
status: "wired",
|
|
607
|
+
run: (e) => import("./logsCmd-CCca3KRZ.js").then((t) => t.runLogsCommand(e))
|
|
608
|
+
},
|
|
609
|
+
{
|
|
610
|
+
name: "traces",
|
|
611
|
+
handlesHelp: !0,
|
|
612
|
+
summary: "Distributed traces from every running api. --tail N --errors --since 30s --process NAME --format json|pretty. Use --id <traceId> for the waterfall of one trace.",
|
|
613
|
+
status: "wired",
|
|
614
|
+
run: (e) => import("./tracesCmd-CkEZQrtt.js").then((t) => t.runTracesCommand(e))
|
|
615
|
+
},
|
|
616
|
+
{
|
|
617
|
+
name: "inspect",
|
|
618
|
+
handlesHelp: !0,
|
|
619
|
+
summary: "Query the live /_voltro/inspect/* surface. Subcommands: app, routes, rpc, metrics, cache, schedules, aggregates, invoke. --process NAME --format json|pretty. `schedules --failing` reports only broken crons and exits 1 if any (usable as a post-deploy gate).",
|
|
620
|
+
status: "wired",
|
|
621
|
+
run: (e) => import("./inspectCmd-Bppy-GGw.js").then((t) => t.runInspectCommand(e))
|
|
622
|
+
},
|
|
623
|
+
{
|
|
624
|
+
name: "workflows",
|
|
625
|
+
handlesHelp: !0,
|
|
626
|
+
summary: "Inspect + operate workflow runs. Subcommands: list, show <runId>, start <name>, retry|cancel|suspend|resume <runId>, signal|update <runId> --name, children <parentExecutionId>, flow (declarative flow-control queue + ledger), pause|unpause <workflowName>.",
|
|
627
|
+
status: "wired",
|
|
628
|
+
run: (e) => import("./workflowsCmd-D1VTmLMY.js").then((t) => t.runWorkflowsCommand(e))
|
|
629
|
+
},
|
|
630
|
+
{
|
|
631
|
+
name: "cluster",
|
|
632
|
+
handlesHelp: !0,
|
|
633
|
+
summary: "Clustering snapshot of every running api. Subcommand: status — per-instance replicaId, runner address, dialect, CDC flavor, coordination, server_id, + a flag for SQL runners stuck on localhost. --process NAME --format json|pretty.",
|
|
634
|
+
status: "wired",
|
|
635
|
+
run: (e) => import("./clusterCmd-CNXKlcvD.js").then((t) => t.runClusterCommand(e))
|
|
636
|
+
},
|
|
637
|
+
{
|
|
638
|
+
name: "login",
|
|
639
|
+
summary: "Log in to Voltro Cloud — opens a browser (WorkOS) and returns to the CLI after success. Alias for `voltro cloud login`. `--token <t>` (or VOLTRO_CLOUD_TOKEN) for headless.",
|
|
640
|
+
status: "wired",
|
|
641
|
+
run: (e) => import("./cloudCmd-Cvv5HGaZ.js").then((t) => t.runCloudCommand(["login", ...e])),
|
|
642
|
+
help: {
|
|
643
|
+
usage: "[--token <t>]",
|
|
644
|
+
flags: [["--token <t>", "headless login with an existing token (or set VOLTRO_CLOUD_TOKEN)"]],
|
|
645
|
+
examples: [["voltro login", "open a browser and return to the CLI after success"]]
|
|
646
|
+
}
|
|
647
|
+
},
|
|
648
|
+
{
|
|
649
|
+
name: "cloud",
|
|
650
|
+
handlesHelp: !0,
|
|
651
|
+
summary: "Control-plane client. Subcommands: login (browser/WorkOS), whoami, projects, project create, env list|set|pull, import, deploy, scan, rollback, register. Base url via VOLTRO_CLOUD_URL.",
|
|
652
|
+
status: "wired",
|
|
653
|
+
run: (e) => import("./cloudCmd-Cvv5HGaZ.js").then((t) => t.runCloudCommand(e))
|
|
654
|
+
},
|
|
655
|
+
{
|
|
656
|
+
name: "help",
|
|
657
|
+
summary: "Print this help.",
|
|
658
|
+
status: "wired",
|
|
659
|
+
run: async (e) => (l(), 0)
|
|
660
|
+
},
|
|
661
|
+
{
|
|
662
|
+
name: "version",
|
|
663
|
+
summary: "Print the voltro version.",
|
|
664
|
+
status: "wired",
|
|
665
|
+
run: async () => (console.log(a()), 0)
|
|
666
|
+
}
|
|
667
|
+
], s = [
|
|
668
|
+
["Start a project", [
|
|
669
|
+
"init",
|
|
670
|
+
"create-project",
|
|
671
|
+
"add-app",
|
|
672
|
+
"list-templates",
|
|
673
|
+
"package",
|
|
674
|
+
"create-package",
|
|
675
|
+
"generate",
|
|
676
|
+
"new"
|
|
677
|
+
]],
|
|
678
|
+
["Develop", [
|
|
679
|
+
"dev",
|
|
680
|
+
"codegen",
|
|
681
|
+
"test",
|
|
682
|
+
"typecheck",
|
|
683
|
+
"e2e",
|
|
684
|
+
"dashboard",
|
|
685
|
+
"agents-md",
|
|
686
|
+
"env"
|
|
687
|
+
]],
|
|
688
|
+
["Database & data", [
|
|
689
|
+
"db",
|
|
690
|
+
"migrate",
|
|
691
|
+
"evolve",
|
|
692
|
+
"data",
|
|
693
|
+
"privacy",
|
|
694
|
+
"embeddings",
|
|
695
|
+
"storage",
|
|
696
|
+
"cache"
|
|
697
|
+
]],
|
|
698
|
+
["Build & run", [
|
|
699
|
+
"build",
|
|
700
|
+
"start",
|
|
701
|
+
"serve",
|
|
702
|
+
"dormancy"
|
|
703
|
+
]],
|
|
704
|
+
["Deploy", [
|
|
705
|
+
"deploy",
|
|
706
|
+
"serverless",
|
|
707
|
+
"static",
|
|
708
|
+
"baseline",
|
|
709
|
+
"cloud",
|
|
710
|
+
"login",
|
|
711
|
+
"schedule-manifest"
|
|
712
|
+
]],
|
|
713
|
+
["Integrate", ["webhooks"]],
|
|
714
|
+
["Observe & debug", [
|
|
715
|
+
"inspect",
|
|
716
|
+
"schedule",
|
|
717
|
+
"logs",
|
|
718
|
+
"traces",
|
|
719
|
+
"workflows",
|
|
720
|
+
"cluster",
|
|
721
|
+
"check",
|
|
722
|
+
"eval",
|
|
723
|
+
"doctor",
|
|
724
|
+
"capabilities"
|
|
725
|
+
]],
|
|
726
|
+
["Maintain", [
|
|
727
|
+
"update",
|
|
728
|
+
"add",
|
|
729
|
+
"secret",
|
|
730
|
+
"telemetry",
|
|
731
|
+
"info"
|
|
732
|
+
]],
|
|
733
|
+
["Meta", ["help", "version"]]
|
|
734
|
+
], c = (e, t = 68) => {
|
|
735
|
+
let n = e.search(/\.(\s|$)/), r = n > 0 ? e.slice(0, n) : e;
|
|
736
|
+
return r.length <= t ? r : `${r.slice(0, t - 1).trimEnd()}…`;
|
|
737
|
+
}, l = () => {
|
|
738
|
+
let e = o.filter((e) => !e.hidden), t = new Map(e.map((e) => [e.name, e])), n = e.reduce((e, t) => Math.max(e, t.name.length), 0);
|
|
739
|
+
console.log(`voltro v${a()}`), console.log("voltro <command> [args]");
|
|
740
|
+
for (let [e, r] of s) {
|
|
741
|
+
let i = r.map((e) => t.get(e)).filter((e) => e !== void 0);
|
|
742
|
+
if (i.length !== 0) {
|
|
743
|
+
console.log(`\n${e}`);
|
|
744
|
+
for (let e of i) {
|
|
745
|
+
let t = " ".repeat(n - e.name.length + 2);
|
|
746
|
+
console.log(` ${e.name}${t}${c(e.summary)}`);
|
|
747
|
+
}
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
let r = new Set(s.flatMap(([, e]) => e)), i = e.filter((e) => !r.has(e.name));
|
|
751
|
+
if (i.length > 0) {
|
|
752
|
+
console.log("\nOther");
|
|
753
|
+
for (let e of i) {
|
|
754
|
+
let t = " ".repeat(n - e.name.length + 2);
|
|
755
|
+
console.log(` ${e.name}${t}${c(e.summary)}`);
|
|
756
|
+
}
|
|
757
|
+
}
|
|
758
|
+
console.log("\nRun 'voltro <command> --help' for the full description, or see https://voltro.dev/docs/cli.");
|
|
759
|
+
}, u = (e, t) => {
|
|
760
|
+
let n = Array.from({ length: t.length + 1 }, (e, t) => t), r = Array(t.length + 1).fill(0);
|
|
761
|
+
for (let i = 1; i <= e.length; i++) {
|
|
762
|
+
r[0] = i;
|
|
763
|
+
for (let a = 1; a <= t.length; a++) {
|
|
764
|
+
let o = e[i - 1] === t[a - 1] ? 0 : 1;
|
|
765
|
+
r[a] = Math.min(r[a - 1] + 1, n[a] + 1, n[a - 1] + o);
|
|
766
|
+
}
|
|
767
|
+
for (let e = 0; e <= t.length; e++) n[e] = r[e];
|
|
768
|
+
}
|
|
769
|
+
return n[t.length];
|
|
770
|
+
}, d = (e, t = 3) => {
|
|
771
|
+
let n = o.filter((e) => !e.hidden).map((e) => e.name), r = e.length <= 4 ? 1 : e.length <= 8 ? 2 : 3;
|
|
772
|
+
return n.map((t) => ({
|
|
773
|
+
name: t,
|
|
774
|
+
score: t.startsWith(e) || e.startsWith(t) ? -2 : t.includes(e) ? -1 : u(e, t)
|
|
775
|
+
})).filter((e) => e.score <= r).sort((e, t) => e.score - t.score || e.name.localeCompare(t.name)).slice(0, t).map((e) => e.name);
|
|
776
|
+
}, f = (e) => {
|
|
777
|
+
let t = [`voltro ${e.name} — ${e.summary}`], n = e.help, r = (e) => {
|
|
778
|
+
let t = e.reduce((e, [t]) => Math.max(e, t.length), 0);
|
|
779
|
+
return e.map(([e, n]) => ` ${e}${" ".repeat(t - e.length + 2)}${n}`);
|
|
780
|
+
};
|
|
781
|
+
if (n?.usage !== void 0 && t.push("", "Usage", ` voltro ${e.name}${n.usage === "" ? "" : ` ${n.usage}`}`), n?.flags !== void 0 && n.flags.length > 0 && t.push("", "Flags", ...r(n.flags)), n?.env !== void 0 && n.env.length > 0 && t.push("", "Environment", ...r(n.env)), n?.examples !== void 0 && n.examples.length > 0) {
|
|
782
|
+
t.push("", "Examples");
|
|
783
|
+
for (let [e, r] of n.examples) t.push(` ${e}`, ` ${r}`);
|
|
784
|
+
}
|
|
785
|
+
return n?.notes !== void 0 && n.notes.length > 0 && t.push("", ...n.notes), t.push("", `Docs: https://voltro.dev/docs/cli/${e.name}`), t;
|
|
786
|
+
}, p = /* @__PURE__ */ new Set(["--help", "-h"]), m = async (e) => {
|
|
787
|
+
let [t, ...n] = e;
|
|
788
|
+
if (!t || p.has(t)) return l(), 0;
|
|
789
|
+
if (t === "--version" || t === "-v") return console.log(a()), 0;
|
|
790
|
+
if (t === "help" && n.length > 0 && !n[0].startsWith("-")) return m([n[0], "--help"]);
|
|
791
|
+
let r = o.find((e) => e.name === t);
|
|
792
|
+
if (!r) {
|
|
793
|
+
console.error(`voltro: unknown command '${t}'`);
|
|
794
|
+
let e = d(t);
|
|
795
|
+
if (e.length > 0) {
|
|
796
|
+
console.error(`\nDid you mean${e.length > 1 ? " one of" : ""}?`);
|
|
797
|
+
for (let t of e) console.error(` voltro ${t}`);
|
|
798
|
+
}
|
|
799
|
+
return console.error("\nrun 'voltro help' for available commands"), 2;
|
|
800
|
+
}
|
|
801
|
+
if (!r.handlesHelp && n.some((e) => p.has(e))) {
|
|
802
|
+
for (let e of f(r)) console.log(e);
|
|
803
|
+
return 0;
|
|
804
|
+
}
|
|
805
|
+
return r.run(n);
|
|
806
|
+
};
|
|
807
|
+
//#endregion
|
|
808
|
+
export { f as a, l as i, s as n, d as o, m as r, o as t };
|