void 0.20.3 → 0.21.1
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/README.md +2 -2
- package/dist/agents-gni4eqBu.mjs +111 -0
- package/dist/auth-3sGB0zJ1.mjs +22 -0
- package/dist/{auth-DPl6kck4.mjs → auth-B9_D6ygs.mjs} +6 -241
- package/dist/auth-CAw7zHqj.mjs +2 -0
- package/dist/auth-client-BWBT8HLp.mjs +6 -0
- package/dist/auth-client-Bawdj38n.d.mts +7 -0
- package/dist/auth-client-react-7GFffu8R.d.mts +7 -0
- package/dist/auth-client-react-CMLwT2xI.mjs +6 -0
- package/dist/auth-client-solid-DyTFL4cq.d.mts +7 -0
- package/dist/auth-client-solid-UoreJWZG.mjs +6 -0
- package/dist/auth-client-svelte-Cv_WvrRk.mjs +6 -0
- package/dist/auth-client-svelte-zetW0KIH.d.mts +7 -0
- package/dist/auth-client-vue-CFk7Xbv3.mjs +6 -0
- package/dist/auth-client-vue-bChShbQP.d.mts +7 -0
- package/dist/{auth-cmd-CzwquNiP.mjs → auth-cmd-g_ymMkUe.mjs} +5 -5
- package/dist/{auth-link-ElDTgF7j.mjs → auth-link-DFvxIyZi.mjs} +5 -5
- package/dist/{better-auth-shared-DSCeohOK.d.mts → better-auth-shared-BoVwA5Vm.d.mts} +1 -6
- package/dist/{better-auth-shared-CYw1T3k4.mjs → better-auth-shared-syGYYmnY.mjs} +1 -1
- package/dist/{build-cmd-BpJe6boP.mjs → build-cmd-wJAv808h.mjs} +6 -4
- package/dist/{cache-D98YTqeE.mjs → cache-Be0Fu5Ka.mjs} +6 -4
- package/dist/{cancel-deploy-CPbEQLMG.mjs → cancel-deploy-BgmyOwhe.mjs} +5 -3
- package/dist/cf-access-rAZxzMkL.mjs +181 -0
- package/dist/cf-build-output-CTdlo6Rt.mjs +520 -0
- package/dist/cli/cf-compat.d.mts +1 -0
- package/dist/cli/cf-compat.mjs +944 -0
- package/dist/cli/cli.mjs +60 -38
- package/dist/cli/env-schema-probe.mjs +3 -3
- package/dist/client-DAAivdid.mjs +2 -0
- package/dist/{client-BQBrZoCX.mjs → client-PdAJ-F0t.mjs} +6 -12
- package/dist/{cloudflare-auth-6M5llVPC.mjs → cloudflare-auth-BCmTc1X_.mjs} +13 -44
- package/dist/{cloudflare-cmd-4RPGN3KB.mjs → cloudflare-cmd-D6PrKn7o.mjs} +4 -7
- package/dist/{cloudflare-connect-t1UU5svD.mjs → cloudflare-connect-DloREDlc.mjs} +6 -6
- package/dist/cloudflare-operations-BHNJVDbN.mjs +2 -0
- package/dist/{cloudflare-operations-BzWnlC1_.mjs → cloudflare-operations-CPEdHYhM.mjs} +37 -39
- package/dist/cloudflare-user-output-Q-k0QoNQ.mjs +20 -0
- package/dist/collect-DAUItMDS.mjs +2 -0
- package/dist/collect-DXHNWHcT.mjs +48 -0
- package/dist/config--T87TD8T.mjs +2 -0
- package/dist/{config-NOG_U1aK.mjs → config-BSe70f4T.mjs} +4 -6
- package/dist/config-DDIFxQYx.mjs +2 -0
- package/dist/{config-uNGuFsI2.mjs → config-Dxr6cTXn.mjs} +22 -37
- package/dist/config-DywxBLQC.d.mts +185 -0
- package/dist/config-entry.d.mts +6 -0
- package/dist/config-entry.mjs +7 -0
- package/dist/config-uP7ZDtVZ.mjs +21 -0
- package/dist/config-write-y3CBI_ux.mjs +60 -0
- package/dist/{connect-WCQZ_u3m.mjs → connect-LnvW4HKx.mjs} +8 -6
- package/dist/{create-project-D0oXA090.mjs → create-project-BZBl_gQ0.mjs} +8 -23
- package/dist/create-project-JV9-6ICF.mjs +2 -0
- package/dist/database-provider-Cx525bwX.mjs +6 -0
- package/dist/database-provider.mjs +1 -5
- package/dist/{db-DJ-9qs3S.mjs → db-Mzv88E1C.mjs} +48 -44
- package/dist/{delete-BZ4-WaGm.mjs → delete-Ri6JemSU.mjs} +6 -4
- package/dist/deploy-DAH2-m_-.mjs +2 -0
- package/dist/{deploy-BAhhcg5q.mjs → deploy-DEsMVrCY.mjs} +796 -198
- package/dist/discover-BBzDZe_o.mjs +2 -0
- package/dist/{discover-xvfrgJeo.mjs → discover-C4O6YxVS.mjs} +3 -8
- package/dist/{dist-BrsS7cai.mjs → dist-4WkAWhWx.mjs} +1 -15
- package/dist/{dist-m40_XgNh.mjs → dist-Bn8Kodjp.mjs} +1 -1
- package/dist/dist-C5fND3R0.mjs +2 -0
- package/dist/dist-D7-nEOXi.mjs +2 -0
- package/dist/{output-B0cfNSx5.mjs → dist-Dn6nn2IU.mjs} +3 -926
- package/dist/{domain-BxAyhxXN.mjs → domain-BA37Ye7T.mjs} +7 -5
- package/dist/{route-types-Da-DpyUp.mjs → drizzle-Beb2Am5S.mjs} +1 -280
- package/dist/{email-Bj7Cvdwp.mjs → email-C5NsxrQG.mjs} +14 -12
- package/dist/{email-Ce6SQq-i.mjs → email-C5kaZXzJ.mjs} +2 -2
- package/dist/{entry-DU3oDoQ3.mjs → entry-DdRFGK0y.mjs} +2 -2
- package/dist/{env-DBKmK4vc.mjs → env-DX_v-Q-v.mjs} +1 -1
- package/dist/{env-DP_EErve.mjs → env-U_ohASB0.mjs} +9 -7
- package/dist/env-Yz4HcvHs.mjs +78 -0
- package/dist/env-helpers--wFmQ_5Q.mjs +136 -0
- package/dist/{env-types-BNPhro-M.mjs → env-types-CWDtqHgw.mjs} +6 -2
- package/dist/{env-validation-CF6KvTRf.mjs → env-validation-BsFEXps5.mjs} +19 -28
- package/dist/env-validation-DIDGM7h4.mjs +2 -0
- package/dist/fetch-CXDChK7B.mjs +18 -0
- package/dist/fetch-_SeGZao9.d.mts +57 -0
- package/dist/fetch-stream-AOByI7Ki.mjs +81 -0
- package/dist/fetch-stream-Bjf0hoZb.d.mts +49 -0
- package/dist/gen-B87rlalt.mjs +2 -0
- package/dist/{gen-B_wPnVTK.mjs → gen-pg-Ojg8Y.mjs} +13 -11
- package/dist/{generate-RTK8_kK1.mjs → generate-C0VY6RVf.mjs} +2 -2
- package/dist/{github-cmd-C-z_xRrQ.mjs → github-cmd-DsrkweIl.mjs} +6 -4
- package/dist/{handler-D1hLsObx.d.mts → handler-BXJTXd02.d.mts} +6 -1
- package/dist/handler-DghKr6dU.mjs +150 -0
- package/dist/head-D_QRR5Yd.mjs +112 -0
- package/dist/head-client-DzmJGN4C.mjs +90 -0
- package/dist/{headers-BAHwgHdW.mjs → headers-B_HBMgi0.mjs} +2 -2
- package/dist/help-B403BLBB.mjs +2 -0
- package/dist/{help-CwOX-zmI.mjs → help-sBhFH6pi.mjs} +17 -12
- package/dist/index.d.mts +2 -20
- package/dist/index.mjs +116 -60
- package/dist/{init-BGktCXgA.mjs → init-C--Yyj1b.mjs} +49 -50
- package/dist/{link-D2kbqhWb.mjs → link-BC-mNG9-.mjs} +7 -5
- package/dist/{list-CvkK_G7k.mjs → list-DHU1Wj6c.mjs} +7 -5
- package/dist/live-CB1y5IuC.mjs +411 -0
- package/dist/live-CKiJilLr.d.mts +105 -0
- package/dist/local-d1-DzykTWY8.mjs +104 -0
- package/dist/login-BwiopVdg.mjs +2 -0
- package/dist/{login-WIjNc77c.mjs → login-jKe_0QZL.mjs} +6 -11
- package/dist/{logs-dLUFCapG.mjs → logs-BG11f5PR.mjs} +6 -4
- package/dist/migrate-BV8qHiCb.mjs +285 -0
- package/dist/migrate-BXY3B3m7.mjs +2 -0
- package/dist/migration-handler-DM4clYj5.d.mts +51 -0
- package/dist/{neon-DHwd2zvC.mjs → neon-n74ta1Pr.mjs} +1 -1
- package/dist/{node-Ez5KW5rn.mjs → node-Cupyf7-s.mjs} +6 -6
- package/dist/{operator-auth-B3e08unv.mjs → operator-auth-BkVgJqv-.mjs} +2 -2
- package/dist/{operator-client-LUZnlnYk.mjs → operator-client-A0iex2yi.mjs} +2 -1
- package/dist/{operator-cmd-CKJ7xIRs.mjs → operator-cmd-BwAS2XZt.mjs} +6 -6
- package/dist/output-CCH48AMM.mjs +146 -0
- package/dist/{package-json-CPoWX79C.mjs → package-json-iCbMg5XF.mjs} +1 -1
- package/dist/pages/client.d.mts +5 -2
- package/dist/pages/client.mjs +5 -3
- package/dist/pages/head-client.mjs +1 -89
- package/dist/pages/head.mjs +1 -111
- package/dist/pages/index.d.mts +2 -3
- package/dist/pages/index.mjs +7 -7
- package/dist/pages/islands-plugin.mjs +2 -2
- package/dist/pages/prefetch.d.mts +2 -30
- package/dist/pages/prefetch.mjs +1 -89
- package/dist/pages/protocol.d.mts +2 -2
- package/dist/pages/protocol.mjs +3 -3
- package/dist/pages/serialize.d.mts +2 -9
- package/dist/pages/serialize.mjs +1 -13
- package/dist/plan-BEZ8VJW0.mjs +256 -0
- package/dist/plan-DpuOr14e.mjs +2 -0
- package/dist/{platform-auth-config-CdVWRRJr.mjs → platform-auth-config-C-hv-_Ok.mjs} +6 -6
- package/dist/{platform-auth-protection-Drl0qhrn.mjs → platform-auth-protection-DjTE5Hj-.mjs} +7 -5
- package/dist/{platform-auth-recovery-CmKEWpDo.mjs → platform-auth-recovery-Cr0r8TEb.mjs} +6 -5
- package/dist/{platform-cmd-5q_k56xS.mjs → platform-cmd-0tEh2ZtA.mjs} +8 -5
- package/dist/platform-cmd-DE6dw45v.mjs +2 -0
- package/dist/{platform-domain-4GiDlcqx.mjs → platform-domain-B_7x6Iqx.mjs} +4 -3
- package/dist/platform-lifecycle-Dhx9Pnub.mjs +2 -0
- package/dist/{platform-lifecycle-R9xAxvtG.mjs → platform-lifecycle-Di0LbhPM.mjs} +208 -37
- package/dist/platform-management-B9LUtMt9.mjs +2 -0
- package/dist/{platform-management-BfWsXHEW.mjs → platform-management-eaiaU3uM.mjs} +8 -5
- package/dist/{platform-recovery-CbK-I1FB.mjs → platform-recovery-BxfA8E5C.mjs} +3 -3
- package/dist/platform-registry-BJbgZLS1.mjs +431 -0
- package/dist/{plugin-inference-BDRfZngg.mjs → plugin-inference-DsvtJLll.mjs} +4 -4
- package/dist/prefetch-Bsc_Pb6c.mjs +90 -0
- package/dist/prefetch-Ce6la4EI.d.mts +31 -0
- package/dist/prepare-D4CkM3_v.mjs +2 -0
- package/dist/{prepare-blNRQvQl.mjs → prepare-_T-Haxrr.mjs} +3 -2
- package/dist/{prepare-CtDJjoOj.mjs → prepare-pcWcxSCh.mjs} +13 -11
- package/dist/prerender-render-Cf_WDE9W.mjs +111 -0
- package/dist/prerender-render.mjs +1 -110
- package/dist/{preset-lAy0B0BQ.mjs → preset-Dowh9tTt.mjs} +16 -118
- package/dist/project-BEBFDFLz.mjs +2 -0
- package/dist/project-CWNIPoXc.mjs +209 -0
- package/dist/{project-cmd-CTdmnzvc.mjs → project-cmd-DrnRJdep.mjs} +18 -16
- package/dist/{project-paths-SK8nMHPp.mjs → project-paths-CKQ-Q5JS.mjs} +47 -14
- package/dist/project-slug-23TpquG4.mjs +8 -0
- package/dist/project-slug-DofjTFd-.mjs +2 -0
- package/dist/{project-team-CGxsQe3_.mjs → project-team-CzRbO_kA.mjs} +6 -4
- package/dist/{project-token-Cirx7uwZ.mjs → project-token-Bwxjf4y6.mjs} +6 -4
- package/dist/{project-tsconfig-Ql2XsSQp.mjs → project-tsconfig-CwfqUnVp.mjs} +2 -2
- package/dist/{protocol-C-pqYJjE.d.mts → protocol-ZH3jP4a7.d.mts} +1 -1
- package/dist/providers-BNKRacMr.d.mts +7 -0
- package/dist/provision-CNgEBkVA.mjs +3 -0
- package/dist/{provision-CSJOjjQk.mjs → provision-Cck2m3jJ.mjs} +11 -25
- package/dist/queues-BWKt1Xo4.d.mts +7 -0
- package/dist/{requests-4Nq59hOr.mjs → requests-DwrqUQZ8.mjs} +5 -3
- package/dist/resolve-project-BTotl8Nn.mjs +2 -0
- package/dist/{resolve-project--Vxawf7z.mjs → resolve-project-Xvis70DG.mjs} +2 -8
- package/dist/response-Tn7rU0MV.mjs +30 -0
- package/dist/{rollback-Dr7u0Ljx.mjs → rollback-B4tFWmkN.mjs} +6 -4
- package/dist/{rolldown-runtime-rQ84J-ij.mjs → rolldown-runtime-DXIUcv95.mjs} +1 -10
- package/dist/route-types-Id82-veQ.mjs +280 -0
- package/dist/{local-d1-D2I6Ox5F.mjs → runner-BGVsGgkb.mjs} +6 -114
- package/dist/runner-CQs_cDSG.mjs +2 -0
- package/dist/runner-mysql-1o47achK.mjs +2 -0
- package/dist/{runner-mysql-7BPUNGmL.mjs → runner-mysql-BhwMk2Bm.mjs} +2 -9
- package/dist/{runner-pg-BkEza-dX.mjs → runner-pg-CJ_JeGF6.mjs} +2 -9
- package/dist/runner-pg-D7z01mQS.mjs +2 -0
- package/dist/runtime/ai.mjs +1 -1
- package/dist/runtime/auth-client-react.d.mts +2 -6
- package/dist/runtime/auth-client-react.mjs +1 -5
- package/dist/runtime/auth-client-solid.d.mts +2 -6
- package/dist/runtime/auth-client-solid.mjs +1 -5
- package/dist/runtime/auth-client-svelte.d.mts +2 -6
- package/dist/runtime/auth-client-svelte.mjs +1 -5
- package/dist/runtime/auth-client-vue.d.mts +2 -6
- package/dist/runtime/auth-client-vue.mjs +1 -5
- package/dist/runtime/auth-client.d.mts +2 -6
- package/dist/runtime/auth-client.mjs +1 -5
- package/dist/runtime/auth.mjs +1 -21
- package/dist/runtime/better-auth-mysql.d.mts +1 -1
- package/dist/runtime/better-auth-mysql.mjs +1 -1
- package/dist/runtime/better-auth-pg.d.mts +1 -1
- package/dist/runtime/better-auth-pg.mjs +1 -1
- package/dist/runtime/better-auth.d.mts +1 -1
- package/dist/runtime/better-auth.mjs +1 -1
- package/dist/runtime/client-react.d.mts +3 -3
- package/dist/runtime/client-react.mjs +3 -3
- package/dist/runtime/client-solid.d.mts +3 -3
- package/dist/runtime/client-solid.mjs +3 -3
- package/dist/runtime/client-svelte.d.mts +3 -3
- package/dist/runtime/client-svelte.mjs +3 -3
- package/dist/runtime/client-vue.d.mts +3 -3
- package/dist/runtime/client-vue.mjs +3 -3
- package/dist/runtime/client.d.mts +3 -3
- package/dist/runtime/client.mjs +3 -3
- package/dist/runtime/db.mjs +1 -1
- package/dist/runtime/durable.mjs +1 -1
- package/dist/runtime/email/testing.mjs +1 -1
- package/dist/runtime/env-helpers.mjs +1 -135
- package/dist/runtime/env-public-client.mjs +1 -1
- package/dist/runtime/env-public.mjs +2 -2
- package/dist/runtime/env.mjs +1 -77
- package/dist/runtime/fetch-stream.d.mts +2 -49
- package/dist/runtime/fetch-stream.mjs +2 -80
- package/dist/runtime/fetch.d.mts +2 -57
- package/dist/runtime/fetch.mjs +2 -17
- package/dist/runtime/handler.d.mts +1 -1
- package/dist/runtime/handler.mjs +1 -149
- package/dist/runtime/kv.mjs +1 -1
- package/dist/runtime/live-client.d.mts +1 -1
- package/dist/runtime/live-server.mjs +2 -2
- package/dist/runtime/live.d.mts +2 -104
- package/dist/runtime/live.mjs +1 -410
- package/dist/runtime/migration-handler-mysql.d.mts +1 -1
- package/dist/runtime/migration-handler-pg.d.mts +1 -1
- package/dist/runtime/migration-handler.d.mts +2 -50
- package/dist/runtime/queues.d.mts +2 -6
- package/dist/runtime/queues.mjs +1 -1
- package/dist/runtime/response.mjs +1 -29
- package/dist/runtime/sandbox.mjs +1 -1
- package/dist/runtime/sse.mjs +1 -171
- package/dist/runtime/storage.mjs +1 -1
- package/dist/runtime/validator.d.mts +1 -1
- package/dist/runtime/validator.mjs +1 -71
- package/dist/runtime/ws-server.d.mts +2 -2
- package/dist/runtime/ws-server.mjs +2 -2
- package/dist/runtime/ws.d.mts +2 -121
- package/dist/{scan-CpK-57ug.mjs → scan-DJbooZm2.mjs} +3 -3
- package/dist/{scan-BMH4rzlv.mjs → scan-DdDvRCU1.mjs} +8 -26
- package/dist/{secret-AcPi-FoA.mjs → secret-UtrRjhEO.mjs} +8 -6
- package/dist/serialize-BPvnNQuA.mjs +14 -0
- package/dist/serialize-CfSwWfF2.d.mts +10 -0
- package/dist/{skills-C0RvGjeE.mjs → skills-B-690E7h.mjs} +3 -2
- package/dist/sse-BaC1jXko.mjs +172 -0
- package/dist/{subcommand-prompt-Bmyn5Rlc.mjs → subcommand-prompt-BuGYkAkC.mjs} +2 -1
- package/dist/sveltekit.d.mts +2 -1
- package/dist/sveltekit.mjs +3 -2
- package/dist/validate-DqJ33oHj.mjs +2 -0
- package/dist/validate-qNhV00PD.mjs +180 -0
- package/dist/validator-BTOu0fB0.mjs +72 -0
- package/dist/{wrangler--imS8n0d.mjs → wrangler-D01qs6VB.mjs} +259 -71
- package/dist/ws-BwcqizuH.d.mts +122 -0
- package/dist/{yarn-pnp-DxSInkzL.mjs → yarn-pnp-CVEc3gE7.mjs} +1 -1
- package/package.json +19 -8
- package/skills/void/SKILL.md +6 -4
- package/skills/void/docs/guide/ai.md +3 -3
- package/skills/void/docs/guide/app-types.md +12 -11
- package/skills/void/docs/guide/auth.md +2 -2
- package/skills/void/docs/guide/database/d1.md +1 -1
- package/skills/void/docs/guide/database/mysql.md +1 -1
- package/skills/void/docs/guide/database/postgresql.md +3 -3
- package/skills/void/docs/guide/deployment.md +8 -15
- package/skills/void/docs/guide/durable-state.md +2 -2
- package/skills/void/docs/guide/edge/headers.md +3 -3
- package/skills/void/docs/guide/edge/prerendering.md +1 -1
- package/skills/void/docs/guide/edge/redirects.md +4 -4
- package/skills/void/docs/guide/edge/revalidation.md +6 -6
- package/skills/void/docs/guide/edge/rewrites.md +28 -27
- package/skills/void/docs/guide/edge/static-assets.md +1 -1
- package/skills/void/docs/guide/email.md +60 -66
- package/skills/void/docs/guide/env-migration.md +1 -1
- package/skills/void/docs/guide/index.md +15 -41
- package/skills/void/docs/guide/pages-routing/head.md +1 -1
- package/skills/void/docs/guide/platform/administration/access.md +13 -5
- package/skills/void/docs/guide/platform/administration/projects.md +3 -1
- package/skills/void/docs/guide/platform/installation/ci.md +3 -0
- package/skills/void/docs/guide/platform/installation/credentials.md +15 -5
- package/skills/void/docs/guide/platform/installation/prerequisites.md +2 -0
- package/skills/void/docs/guide/platform/installation/setup.md +1 -1
- package/skills/void/docs/guide/quickstart.md +11 -78
- package/skills/void/docs/guide/remote-dev.md +2 -2
- package/skills/void/docs/guide/sandboxes.md +1 -1
- package/skills/void/docs/guide/ssg.md +1 -1
- package/skills/void/docs/guide/websockets.md +1 -1
- package/skills/void/docs/index.md +17 -17
- package/skills/void/docs/integrations/cloudflare.md +91 -96
- package/skills/void/docs/integrations/frameworks/analog.md +14 -9
- package/skills/void/docs/integrations/frameworks/astro.md +14 -10
- package/skills/void/docs/integrations/frameworks/nuxt.md +14 -9
- package/skills/void/docs/integrations/frameworks/overview.md +35 -29
- package/skills/void/docs/integrations/frameworks/react-router.md +1 -1
- package/skills/void/docs/integrations/frameworks/sveltekit.md +33 -30
- package/skills/void/docs/integrations/frameworks/tanstack-start.md +1 -1
- package/skills/void/docs/integrations/nodejs-bun-deno.md +5 -5
- package/skills/void/docs/reference/api.md +21 -4
- package/skills/void/docs/reference/cli.md +40 -25
- package/skills/void/docs/reference/config.md +58 -35
- package/skills/void/docs/reference/structure.md +2 -2
- package/dist/validate-tBBN_dXH.mjs +0 -505
package/README.md
CHANGED
|
@@ -19,7 +19,7 @@ link another enabled login to their account with `void auth link`.
|
|
|
19
19
|
- Pages mode from `pages/`
|
|
20
20
|
- typed Drizzle access via `void/db`
|
|
21
21
|
- `crons/` and `queues/`
|
|
22
|
-
- URL redirects, rewrites, and fallbacks (`void.
|
|
22
|
+
- URL redirects, rewrites, and fallbacks (`void.config.ts` / `public/_redirects`, plus `c.rewrite()` from middleware)
|
|
23
23
|
- binding inference for D1, KV, R2, AI, auth, queues, and typed Durable Objects
|
|
24
24
|
- remote bindings for local development
|
|
25
25
|
- one target-aware deploy path for Void-hosted and direct Cloudflare apps
|
|
@@ -41,7 +41,7 @@ To install a team platform, use `void platform install`. A domain is recommended
|
|
|
41
41
|
|
|
42
42
|
Init always writes brief coding-agent instructions to `AGENTS.md`, pointing to `node_modules/void/skills/void/docs/`, and links skills for detected agents. Run `void init --agents` to add or refresh just this setup without choosing an agent.
|
|
43
43
|
|
|
44
|
-
Then run `npx void init`. In an empty directory, the full interactive flow can scaffold a starter and configure local project files. It then asks where to deploy: Cloudflare (the default)
|
|
44
|
+
Then run `npx void init`. In an empty directory, the full interactive flow can scaffold a starter and configure local project files. It then asks where to deploy: Cloudflare (the default) writes `void.config.ts`, handles secure browser sign-in through Void's bundled tooling, and saves the selected account; Void asks for the API URL of an explicitly connected company platform (`void connect <url>` or `void platform install`). Existing `void.json` and root Wrangler JSON/JSONC files are migrated automatically; commit `void.config.ts` and `void.lock.json` when created. Back up `~/.void/platforms/` after installing a company platform because its owner-only recovery material contains runtime keys that Cloudflare cannot return. The next app step is just `npx void deploy`. Auth-enabled deploys preserve an existing `BETTER_AUTH_SECRET` or create a persistent encrypted secret when missing on either platform. Root `.env` is local-only; production server keys declared in `env.ts` use encrypted remote secret storage and are rejected as plaintext Worker vars. In an existing app, init configures Void in place by adding missing Vite scripts and creating or patching `vite.config.*` with `voidPlugin()`.
|
|
45
45
|
|
|
46
46
|
```ts
|
|
47
47
|
// vite.config.ts
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import { a as join } from "./dist-4WkAWhWx.mjs";
|
|
2
|
+
import { existsSync, readFileSync } from "node:fs";
|
|
3
|
+
import { fileURLToPath } from "node:url";
|
|
4
|
+
//#region src/cli/agents.ts
|
|
5
|
+
function getPackageDir() {
|
|
6
|
+
let dir = join(fileURLToPath(import.meta.url), "..");
|
|
7
|
+
for (let i = 0; i < 5; i++) {
|
|
8
|
+
if (existsSync(join(dir, "package.json"))) {
|
|
9
|
+
if (JSON.parse(readFileSync(join(dir, "package.json"), "utf-8")).name === "void") return dir;
|
|
10
|
+
}
|
|
11
|
+
dir = join(dir, "..");
|
|
12
|
+
}
|
|
13
|
+
throw new Error("Could not find void package root");
|
|
14
|
+
}
|
|
15
|
+
const agents = {
|
|
16
|
+
"claude-code": {
|
|
17
|
+
displayName: "Claude Code",
|
|
18
|
+
skillsDir: ".claude/skills",
|
|
19
|
+
detect: (root) => existsSync(join(root, ".claude")) || existsSync(join(root, "CLAUDE.md"))
|
|
20
|
+
},
|
|
21
|
+
amp: {
|
|
22
|
+
displayName: "Amp",
|
|
23
|
+
skillsDir: ".agents/skills",
|
|
24
|
+
detect: (root) => existsSync(join(root, ".agents"))
|
|
25
|
+
},
|
|
26
|
+
codex: {
|
|
27
|
+
displayName: "Codex",
|
|
28
|
+
skillsDir: ".agents/skills",
|
|
29
|
+
detect: (root) => existsSync(join(root, ".codex"))
|
|
30
|
+
},
|
|
31
|
+
cursor: {
|
|
32
|
+
displayName: "Cursor",
|
|
33
|
+
skillsDir: ".agents/skills",
|
|
34
|
+
detect: (root) => existsSync(join(root, ".cursor"))
|
|
35
|
+
},
|
|
36
|
+
windsurf: {
|
|
37
|
+
displayName: "Windsurf",
|
|
38
|
+
skillsDir: ".windsurf/skills",
|
|
39
|
+
detect: (root) => existsSync(join(root, ".windsurf"))
|
|
40
|
+
},
|
|
41
|
+
"gemini-cli": {
|
|
42
|
+
displayName: "Gemini CLI",
|
|
43
|
+
skillsDir: ".agents/skills",
|
|
44
|
+
detect: (root) => existsSync(join(root, ".gemini"))
|
|
45
|
+
},
|
|
46
|
+
"github-copilot": {
|
|
47
|
+
displayName: "GitHub Copilot",
|
|
48
|
+
skillsDir: ".agents/skills",
|
|
49
|
+
detect: (root) => existsSync(join(root, ".github", "copilot-instructions.md"))
|
|
50
|
+
},
|
|
51
|
+
cline: {
|
|
52
|
+
displayName: "Cline",
|
|
53
|
+
skillsDir: ".cline/skills",
|
|
54
|
+
detect: (root) => existsSync(join(root, ".cline"))
|
|
55
|
+
},
|
|
56
|
+
roo: {
|
|
57
|
+
displayName: "Roo Code",
|
|
58
|
+
skillsDir: ".roo/skills",
|
|
59
|
+
detect: (root) => existsSync(join(root, ".roo"))
|
|
60
|
+
},
|
|
61
|
+
kilo: {
|
|
62
|
+
displayName: "Kilo Code",
|
|
63
|
+
skillsDir: ".kilocode/skills",
|
|
64
|
+
detect: (root) => existsSync(join(root, ".kilocode"))
|
|
65
|
+
},
|
|
66
|
+
continue: {
|
|
67
|
+
displayName: "Continue",
|
|
68
|
+
skillsDir: ".continue/skills",
|
|
69
|
+
detect: (root) => existsSync(join(root, ".continue"))
|
|
70
|
+
},
|
|
71
|
+
goose: {
|
|
72
|
+
displayName: "Goose",
|
|
73
|
+
skillsDir: ".goose/skills",
|
|
74
|
+
detect: (root) => existsSync(join(root, ".goose"))
|
|
75
|
+
},
|
|
76
|
+
opencode: {
|
|
77
|
+
displayName: "OpenCode",
|
|
78
|
+
skillsDir: ".agents/skills",
|
|
79
|
+
detect: (root) => existsSync(join(root, ".opencode"))
|
|
80
|
+
},
|
|
81
|
+
trae: {
|
|
82
|
+
displayName: "Trae",
|
|
83
|
+
skillsDir: ".trae/skills",
|
|
84
|
+
detect: (root) => existsSync(join(root, ".trae"))
|
|
85
|
+
},
|
|
86
|
+
junie: {
|
|
87
|
+
displayName: "Junie",
|
|
88
|
+
skillsDir: ".junie/skills",
|
|
89
|
+
detect: (root) => existsSync(join(root, ".junie"))
|
|
90
|
+
},
|
|
91
|
+
"kiro-cli": {
|
|
92
|
+
displayName: "Kiro CLI",
|
|
93
|
+
skillsDir: ".kiro/skills",
|
|
94
|
+
detect: (root) => existsSync(join(root, ".kiro"))
|
|
95
|
+
},
|
|
96
|
+
zencoder: {
|
|
97
|
+
displayName: "Zencoder",
|
|
98
|
+
skillsDir: ".zencoder/skills",
|
|
99
|
+
detect: (root) => existsSync(join(root, ".zencoder"))
|
|
100
|
+
},
|
|
101
|
+
"qwen-code": {
|
|
102
|
+
displayName: "Qwen Code",
|
|
103
|
+
skillsDir: ".qwen/skills",
|
|
104
|
+
detect: (root) => existsSync(join(root, ".qwen"))
|
|
105
|
+
}
|
|
106
|
+
};
|
|
107
|
+
function detectAgents(root) {
|
|
108
|
+
return Object.values(agents).filter((a) => a.detect(root));
|
|
109
|
+
}
|
|
110
|
+
//#endregion
|
|
111
|
+
export { getPackageDir as n, detectAgents as t };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { AsyncLocalStorage } from "node:async_hooks";
|
|
2
|
+
import { HTTPException } from "hono/http-exception";
|
|
3
|
+
//#region src/runtime/auth.ts
|
|
4
|
+
const AUTH_CONTEXT_SYMBOL = Symbol.for("void.authContext.v1");
|
|
5
|
+
const globalWithAuthContext = globalThis;
|
|
6
|
+
const authContext = globalWithAuthContext[AUTH_CONTEXT_SYMBOL] ?? (globalWithAuthContext[AUTH_CONTEXT_SYMBOL] = new AsyncLocalStorage());
|
|
7
|
+
function defineAuth(config) {
|
|
8
|
+
return config;
|
|
9
|
+
}
|
|
10
|
+
function getUser() {
|
|
11
|
+
return authContext.getStore()?.user ?? null;
|
|
12
|
+
}
|
|
13
|
+
function getSession() {
|
|
14
|
+
return authContext.getStore()?.state ?? null;
|
|
15
|
+
}
|
|
16
|
+
function requireAuth(c) {
|
|
17
|
+
const user = c.get("user");
|
|
18
|
+
if (!user) throw new HTTPException(401, { message: "Unauthorized" });
|
|
19
|
+
return user;
|
|
20
|
+
}
|
|
21
|
+
//#endregion
|
|
22
|
+
export { requireAuth as a, getUser as i, defineAuth as n, getSession as r, authContext as t };
|
|
@@ -1,251 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { n as dirname, o as join } from "./dist-BrsS7cai.mjs";
|
|
3
|
-
import { B as ensureCloudflaredToken, K as getActivePlatformConnection, X as normalizePlatformApiUrl, Y as listPlatformConnections, Z as platformCredentialAccount, dt as writeKeyringPassword, lt as deleteKeyringPassword, ut as readKeyringPassword } from "./output-B0cfNSx5.mjs";
|
|
1
|
+
import { a as join } from "./dist-4WkAWhWx.mjs";
|
|
4
2
|
import { t as cfAccessHeaders } from "./cf-access-DRsQRe6k.mjs";
|
|
5
|
-
import {
|
|
3
|
+
import { S as writeKeyringPassword, b as deleteKeyringPassword, c as platformCredentialAccount, o as listPlatformConnections, r as getActivePlatformConnection, s as normalizePlatformApiUrl, x as readKeyringPassword } from "./platform-registry-BJbgZLS1.mjs";
|
|
4
|
+
import { t as ensureCloudflaredToken } from "./cf-access-rAZxzMkL.mjs";
|
|
5
|
+
import { a as readProjectApplicationDomain, f as VOID_CLOUD_PLATFORM, m as readLegacyHostedPlatformSelection, n as isLegacyVoidCloudProject, p as VOID_CLOUD_STAGING_PLATFORM, r as isVoidInternalStaging, s as readProjectPlatformUrl } from "./project-CWNIPoXc.mjs";
|
|
6
|
+
import { mkdirSync, readFileSync, writeFileSync } from "node:fs";
|
|
6
7
|
import { createHash, randomBytes } from "node:crypto";
|
|
7
8
|
import { homedir } from "node:os";
|
|
8
|
-
import { normalizeApplicationDomain } from "@void/platform";
|
|
9
9
|
//#region src/shared/proxy.ts
|
|
10
10
|
const DEFAULT_PROXY_URL = "https://proxy.void.cloud";
|
|
11
11
|
const STAGING_PROXY_URL = "https://proxy.staging.void.cloud";
|
|
12
12
|
//#endregion
|
|
13
|
-
//#region src/cli/hosted-platform.ts
|
|
14
|
-
const VOID_CLOUD_PLATFORM = Object.freeze({
|
|
15
|
-
apiUrl: "https://api.void.cloud",
|
|
16
|
-
applicationDomain: "void.app",
|
|
17
|
-
displayName: "Void Cloud",
|
|
18
|
-
proxyUrl: "https://proxy.void.cloud"
|
|
19
|
-
});
|
|
20
|
-
const VOID_CLOUD_STAGING_PLATFORM = Object.freeze({
|
|
21
|
-
apiUrl: "https://api.staging.void.cloud",
|
|
22
|
-
applicationDomain: "staging.void.app",
|
|
23
|
-
displayName: "Void Cloud staging",
|
|
24
|
-
proxyUrl: "https://proxy.staging.void.cloud"
|
|
25
|
-
});
|
|
26
|
-
const HOSTED_PLATFORMS = [VOID_CLOUD_PLATFORM, VOID_CLOUD_STAGING_PLATFORM];
|
|
27
|
-
function hostedPlatformForApiUrl(apiUrl) {
|
|
28
|
-
if (typeof apiUrl !== "string") return null;
|
|
29
|
-
let normalized;
|
|
30
|
-
try {
|
|
31
|
-
const parsed = new URL(apiUrl);
|
|
32
|
-
if (parsed.protocol !== "https:" || parsed.username || parsed.password || parsed.search || parsed.hash || parsed.pathname !== "/" && parsed.pathname !== "") return null;
|
|
33
|
-
normalized = parsed.origin;
|
|
34
|
-
} catch {
|
|
35
|
-
return null;
|
|
36
|
-
}
|
|
37
|
-
return HOSTED_PLATFORMS.find((platform) => platform.apiUrl === normalized) ?? null;
|
|
38
|
-
}
|
|
39
|
-
/** Resolve an old ~/.void/config.json selection without returning credential values. */
|
|
40
|
-
function readLegacyHostedPlatformSelection(configPath = join(homedir(), ".void", "config.json")) {
|
|
41
|
-
let value = {};
|
|
42
|
-
try {
|
|
43
|
-
value = JSON.parse(readFileSync(configPath, "utf8"));
|
|
44
|
-
} catch {
|
|
45
|
-
return null;
|
|
46
|
-
}
|
|
47
|
-
if (value.api !== void 0) {
|
|
48
|
-
const platform = hostedPlatformForApiUrl(value.api);
|
|
49
|
-
return platform ? {
|
|
50
|
-
...platform,
|
|
51
|
-
source: "configured-api"
|
|
52
|
-
} : null;
|
|
53
|
-
}
|
|
54
|
-
if (typeof value.token === "string" && value.token !== "") return {
|
|
55
|
-
...VOID_CLOUD_PLATFORM,
|
|
56
|
-
source: "legacy-credential"
|
|
57
|
-
};
|
|
58
|
-
if (typeof value.stagingToken === "string" && value.stagingToken !== "") return {
|
|
59
|
-
...VOID_CLOUD_STAGING_PLATFORM,
|
|
60
|
-
source: "legacy-credential"
|
|
61
|
-
};
|
|
62
|
-
return null;
|
|
63
|
-
}
|
|
64
|
-
//#endregion
|
|
65
|
-
//#region src/cli/project.ts
|
|
66
|
-
var project_exports = /* @__PURE__ */ __exportAll({
|
|
67
|
-
attachSelectedPlatform: () => attachSelectedPlatform,
|
|
68
|
-
isLegacyVoidCloudProject: () => isLegacyVoidCloudProject,
|
|
69
|
-
isVoidInternalStaging: () => isVoidInternalStaging,
|
|
70
|
-
readDeploymentPlatform: () => readDeploymentPlatform,
|
|
71
|
-
readProjectApplicationDomain: () => readProjectApplicationDomain,
|
|
72
|
-
readProjectConfig: () => readProjectConfig,
|
|
73
|
-
readProjectPlatformUrl: () => readProjectPlatformUrl,
|
|
74
|
-
removeProjectConfig: () => removeProjectConfig,
|
|
75
|
-
writeDeploymentPlatform: () => writeDeploymentPlatform,
|
|
76
|
-
writePlatformSelection: () => writePlatformSelection,
|
|
77
|
-
writeProjectConfig: () => writeProjectConfig
|
|
78
|
-
});
|
|
79
|
-
const PROJECT_FILE = ".void/project.json";
|
|
80
|
-
function readProjectConfigFile(root) {
|
|
81
|
-
const filePath = join(root, PROJECT_FILE);
|
|
82
|
-
try {
|
|
83
|
-
const raw = readFileSync(filePath, "utf-8");
|
|
84
|
-
const config = JSON.parse(raw);
|
|
85
|
-
if (typeof config !== "object" || config === null || Array.isArray(config)) return null;
|
|
86
|
-
return config;
|
|
87
|
-
} catch {
|
|
88
|
-
return null;
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
/**
|
|
92
|
-
* Read the project config from the project root.
|
|
93
|
-
* Returns null if no project.json exists.
|
|
94
|
-
* A file containing only internal metadata is not treated as a linked project.
|
|
95
|
-
*/
|
|
96
|
-
function readProjectConfig(root) {
|
|
97
|
-
const config = readProjectConfigFile(root);
|
|
98
|
-
if (!config || typeof config.projectId !== "string" || typeof config.slug !== "string") return null;
|
|
99
|
-
const result = {
|
|
100
|
-
projectId: config.projectId,
|
|
101
|
-
slug: config.slug
|
|
102
|
-
};
|
|
103
|
-
if (typeof config.platformUrl === "string") result.platformUrl = normalizePlatformApiUrl(config.platformUrl);
|
|
104
|
-
if (typeof config.applicationDomain === "string") result.applicationDomain = normalizeApplicationDomain(config.applicationDomain);
|
|
105
|
-
if (typeof config.proxyUrl === "string") result.proxyUrl = normalizePlatformApiUrl(config.proxyUrl);
|
|
106
|
-
if (config.voidInternalStaging === true) result.voidInternalStaging = true;
|
|
107
|
-
return result;
|
|
108
|
-
}
|
|
109
|
-
/**
|
|
110
|
-
* Read the deployment platform selected during `void init`.
|
|
111
|
-
*
|
|
112
|
-
* Linked project files created before the platform field existed implicitly
|
|
113
|
-
* target Void. A metadata-only file has no deployment preference.
|
|
114
|
-
*/
|
|
115
|
-
function readDeploymentPlatform(root) {
|
|
116
|
-
const config = readProjectConfigFile(root);
|
|
117
|
-
if (!config) return null;
|
|
118
|
-
if (config.platform === "cloudflare" || config.platform === "void" || config.platform === "none") return config.platform;
|
|
119
|
-
if (typeof config.projectId === "string" && typeof config.slug === "string") return "void";
|
|
120
|
-
return null;
|
|
121
|
-
}
|
|
122
|
-
/**
|
|
123
|
-
* Persist a deployment preference without discarding an existing Void project
|
|
124
|
-
* link. Keeping the link makes switching back to Void non-destructive.
|
|
125
|
-
*/
|
|
126
|
-
function writeDeploymentPlatform(root, platform) {
|
|
127
|
-
const filePath = join(root, PROJECT_FILE);
|
|
128
|
-
const existing = readProjectConfigFile(root);
|
|
129
|
-
const next = { platform };
|
|
130
|
-
if (typeof existing?.projectId === "string") next.projectId = existing.projectId;
|
|
131
|
-
if (typeof existing?.platformUrl === "string") next.platformUrl = existing.platformUrl;
|
|
132
|
-
if (typeof existing?.applicationDomain === "string") next.applicationDomain = existing.applicationDomain;
|
|
133
|
-
if (typeof existing?.proxyUrl === "string") next.proxyUrl = existing.proxyUrl;
|
|
134
|
-
if (typeof existing?.slug === "string") next.slug = existing.slug;
|
|
135
|
-
if (existing?.voidInternalStaging === true) next.voidInternalStaging = true;
|
|
136
|
-
mkdirSync(dirname(filePath), { recursive: true });
|
|
137
|
-
writeFileSync(filePath, JSON.stringify(next, null, 2) + "\n");
|
|
138
|
-
}
|
|
139
|
-
/** Select a verified platform without changing an existing project link. */
|
|
140
|
-
function writePlatformSelection(root, connection) {
|
|
141
|
-
const existing = readProjectConfigFile(root);
|
|
142
|
-
const linked = readProjectConfig(root);
|
|
143
|
-
const pinnedUrl = isVoidInternalStaging(root) ? VOID_CLOUD_STAGING_PLATFORM.apiUrl : linked ? linked.platformUrl ?? VOID_CLOUD_PLATFORM.apiUrl : null;
|
|
144
|
-
if (pinnedUrl && pinnedUrl !== connection.apiUrl) return false;
|
|
145
|
-
const filePath = join(root, PROJECT_FILE);
|
|
146
|
-
mkdirSync(dirname(filePath), { recursive: true });
|
|
147
|
-
writeFileSync(filePath, JSON.stringify({
|
|
148
|
-
...existing,
|
|
149
|
-
platform: "void",
|
|
150
|
-
platformUrl: normalizePlatformApiUrl(connection.apiUrl),
|
|
151
|
-
applicationDomain: normalizeApplicationDomain(connection.applicationDomain),
|
|
152
|
-
proxyUrl: normalizePlatformApiUrl(connection.proxyUrl)
|
|
153
|
-
}, null, 2) + "\n");
|
|
154
|
-
return true;
|
|
155
|
-
}
|
|
156
|
-
/**
|
|
157
|
-
* Internal-only platform developers' staging switch.
|
|
158
|
-
* This intentionally lives with the project link state, not public void.json.
|
|
159
|
-
*/
|
|
160
|
-
function isVoidInternalStaging(root) {
|
|
161
|
-
return readProjectConfigFile(root)?.voidInternalStaging === true;
|
|
162
|
-
}
|
|
163
|
-
function readProjectPlatformUrl(root) {
|
|
164
|
-
const value = readProjectConfigFile(root)?.platformUrl;
|
|
165
|
-
return typeof value === "string" && value !== "" ? normalizePlatformApiUrl(value) : null;
|
|
166
|
-
}
|
|
167
|
-
function readProjectApplicationDomain(root) {
|
|
168
|
-
const value = readProjectConfigFile(root)?.applicationDomain;
|
|
169
|
-
return typeof value === "string" && value !== "" ? normalizeApplicationDomain(value) : null;
|
|
170
|
-
}
|
|
171
|
-
/** Resolve the immutable platform identity that every newly linked project records. */
|
|
172
|
-
function attachSelectedPlatform(root, config, platformApiUrl) {
|
|
173
|
-
const apiUrl = normalizePlatformApiUrl(platformApiUrl);
|
|
174
|
-
const hosted = hostedPlatformForApiUrl(apiUrl);
|
|
175
|
-
if (hosted) return {
|
|
176
|
-
...config,
|
|
177
|
-
applicationDomain: hosted.applicationDomain,
|
|
178
|
-
platformUrl: hosted.apiUrl,
|
|
179
|
-
proxyUrl: hosted.proxyUrl,
|
|
180
|
-
...isVoidInternalStaging(root) && hosted.apiUrl === VOID_CLOUD_STAGING_PLATFORM.apiUrl ? { voidInternalStaging: true } : {}
|
|
181
|
-
};
|
|
182
|
-
const connection = listPlatformConnections().find((entry) => entry.apiUrl === apiUrl);
|
|
183
|
-
if (connection?.applicationDomain && connection.proxyUrl) return {
|
|
184
|
-
...config,
|
|
185
|
-
applicationDomain: connection.applicationDomain,
|
|
186
|
-
platformUrl: connection.apiUrl,
|
|
187
|
-
proxyUrl: connection.proxyUrl
|
|
188
|
-
};
|
|
189
|
-
throw new Error(`platform: No verified metadata is registered for ${apiUrl}. Run \`void connect ${apiUrl}\` before linking a project.`);
|
|
190
|
-
}
|
|
191
|
-
function isLegacyVoidCloudProject(root) {
|
|
192
|
-
const config = readProjectConfigFile(root);
|
|
193
|
-
return typeof config?.projectId === "string" && typeof config.slug === "string" && typeof config.platformUrl !== "string";
|
|
194
|
-
}
|
|
195
|
-
/**
|
|
196
|
-
* Write the project config to the project root.
|
|
197
|
-
*/
|
|
198
|
-
function writeProjectConfig(root, config) {
|
|
199
|
-
const filePath = join(root, PROJECT_FILE);
|
|
200
|
-
const existing = readProjectConfigFile(root);
|
|
201
|
-
const next = {
|
|
202
|
-
platform: "void",
|
|
203
|
-
projectId: config.projectId,
|
|
204
|
-
slug: config.slug
|
|
205
|
-
};
|
|
206
|
-
if (config.platformUrl) next.platformUrl = normalizePlatformApiUrl(config.platformUrl);
|
|
207
|
-
else if (typeof existing?.platformUrl === "string") next.platformUrl = existing.platformUrl;
|
|
208
|
-
if (config.applicationDomain) next.applicationDomain = normalizeApplicationDomain(config.applicationDomain);
|
|
209
|
-
else if (typeof existing?.applicationDomain === "string") next.applicationDomain = existing.applicationDomain;
|
|
210
|
-
if (config.proxyUrl) next.proxyUrl = normalizePlatformApiUrl(config.proxyUrl);
|
|
211
|
-
else if (typeof existing?.proxyUrl === "string") next.proxyUrl = existing.proxyUrl;
|
|
212
|
-
if (config.voidInternalStaging === true || existing?.voidInternalStaging === true) next.voidInternalStaging = true;
|
|
213
|
-
mkdirSync(dirname(filePath), { recursive: true });
|
|
214
|
-
writeFileSync(filePath, JSON.stringify(next, null, 2) + "\n");
|
|
215
|
-
}
|
|
216
|
-
/**
|
|
217
|
-
* Remove the project config file. Returns true if removed, false if it didn't exist.
|
|
218
|
-
*/
|
|
219
|
-
function removeProjectConfig(root) {
|
|
220
|
-
const filePath = join(root, PROJECT_FILE);
|
|
221
|
-
try {
|
|
222
|
-
rmSync(filePath);
|
|
223
|
-
return true;
|
|
224
|
-
} catch {
|
|
225
|
-
return false;
|
|
226
|
-
}
|
|
227
|
-
}
|
|
228
|
-
//#endregion
|
|
229
13
|
//#region src/cli/auth.ts
|
|
230
|
-
var auth_exports = /* @__PURE__ */ __exportAll({
|
|
231
|
-
awaitBrowserCallback: () => awaitBrowserCallback,
|
|
232
|
-
createCodeChallenge: () => createCodeChallenge,
|
|
233
|
-
createCodeVerifier: () => createCodeVerifier,
|
|
234
|
-
getAccountCredential: () => getAccountCredential,
|
|
235
|
-
getApiUrl: () => getApiUrl,
|
|
236
|
-
getProxyUrl: () => getProxyUrl,
|
|
237
|
-
getSiteDomain: () => getSiteDomain,
|
|
238
|
-
getToken: () => getToken,
|
|
239
|
-
getTokenSource: () => getTokenSource,
|
|
240
|
-
isStagingMode: () => isStagingMode,
|
|
241
|
-
openBrowser: () => openBrowser,
|
|
242
|
-
readPlatformToken: () => readPlatformToken,
|
|
243
|
-
removeToken: () => removeToken,
|
|
244
|
-
runLogin: () => runLogin,
|
|
245
|
-
runPlatformLogin: () => runPlatformLogin,
|
|
246
|
-
savePlatformToken: () => savePlatformToken,
|
|
247
|
-
saveToken: () => saveToken
|
|
248
|
-
});
|
|
249
14
|
const CONFIG_DIR = join(homedir(), ".void");
|
|
250
15
|
const CONFIG_PATH = join(CONFIG_DIR, "config.json");
|
|
251
16
|
const KEYRING_SERVICE = "dev.void.cli";
|
|
@@ -647,4 +412,4 @@ async function runPlatformLogin(origin, provider = "github", onUrl) {
|
|
|
647
412
|
});
|
|
648
413
|
}
|
|
649
414
|
//#endregion
|
|
650
|
-
export {
|
|
415
|
+
export { saveToken as _, getApiUrl as a, getToken as c, openBrowser as d, readPlatformToken as f, savePlatformToken as g, runPlatformLogin as h, getAccountCredential as i, getTokenSource as l, runLogin as m, createCodeChallenge as n, getProxyUrl as o, removeToken as p, createCodeVerifier as r, getSiteDomain as s, awaitBrowserCallback as t, isStagingMode as u, DEFAULT_PROXY_URL as v, STAGING_PROXY_URL as y };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createAuthClient } from "better-auth/client";
|
|
2
|
+
//#region src/runtime/auth-client.d.ts
|
|
3
|
+
declare const createAuthClient$1: typeof createAuthClient;
|
|
4
|
+
type BetterAuthClientInstance = ReturnType<typeof createAuthClient$1>;
|
|
5
|
+
declare const auth: BetterAuthClientInstance;
|
|
6
|
+
//#endregion
|
|
7
|
+
export { createAuthClient$1 as n, auth as t };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createAuthClient } from "better-auth/react";
|
|
2
|
+
//#region src/runtime/auth-client-react.d.ts
|
|
3
|
+
declare const createAuthClient$1: typeof createAuthClient;
|
|
4
|
+
type BetterAuthClientInstance = ReturnType<typeof createAuthClient$1>;
|
|
5
|
+
declare const auth: BetterAuthClientInstance;
|
|
6
|
+
//#endregion
|
|
7
|
+
export { createAuthClient$1 as n, auth as t };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createAuthClient } from "better-auth/solid";
|
|
2
|
+
//#region src/runtime/auth-client-solid.d.ts
|
|
3
|
+
declare const createAuthClient$1: typeof createAuthClient;
|
|
4
|
+
type BetterAuthClientInstance = ReturnType<typeof createAuthClient$1>;
|
|
5
|
+
declare const auth: BetterAuthClientInstance;
|
|
6
|
+
//#endregion
|
|
7
|
+
export { createAuthClient$1 as n, auth as t };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createAuthClient } from "better-auth/svelte";
|
|
2
|
+
//#region src/runtime/auth-client-svelte.ts
|
|
3
|
+
const createAuthClient$1 = createAuthClient;
|
|
4
|
+
const auth = createAuthClient({ basePath: "/api/auth" });
|
|
5
|
+
//#endregion
|
|
6
|
+
export { createAuthClient$1 as n, auth as t };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createAuthClient } from "better-auth/svelte";
|
|
2
|
+
//#region src/runtime/auth-client-svelte.d.ts
|
|
3
|
+
declare const createAuthClient$1: typeof createAuthClient;
|
|
4
|
+
type BetterAuthClientInstance = ReturnType<typeof createAuthClient$1>;
|
|
5
|
+
declare const auth: BetterAuthClientInstance;
|
|
6
|
+
//#endregion
|
|
7
|
+
export { createAuthClient$1 as n, auth as t };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createAuthClient } from "better-auth/vue";
|
|
2
|
+
//#region src/runtime/auth-client-vue.d.ts
|
|
3
|
+
declare const createAuthClient$1: typeof createAuthClient;
|
|
4
|
+
type BetterAuthClientInstance = ReturnType<typeof createAuthClient$1>;
|
|
5
|
+
declare const auth: BetterAuthClientInstance;
|
|
6
|
+
//#endregion
|
|
7
|
+
export { createAuthClient$1 as n, auth as t };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { n as PlatformClient } from "./client-
|
|
4
|
-
import {
|
|
1
|
+
import { c as getToken, p as removeToken } from "./auth-B9_D6ygs.mjs";
|
|
2
|
+
import { j as log } from "./dist-Dn6nn2IU.mjs";
|
|
3
|
+
import { n as PlatformClient } from "./client-PdAJ-F0t.mjs";
|
|
4
|
+
import { n as runLoginCommand } from "./login-jKe_0QZL.mjs";
|
|
5
5
|
import { execSync } from "node:child_process";
|
|
6
6
|
//#region src/cli/auth-cmd.ts
|
|
7
7
|
async function runAuthCommand(root, args) {
|
|
8
8
|
switch (args.subcommand) {
|
|
9
9
|
case "login": return runLoginCommand(root);
|
|
10
|
-
case "link": return import("./auth-link-
|
|
10
|
+
case "link": return import("./auth-link-DFvxIyZi.mjs").then(({ runAuthLink }) => runAuthLink(root, args.connectionId));
|
|
11
11
|
case "logout":
|
|
12
12
|
if (removeToken(root)) log.success("Logged out.");
|
|
13
13
|
else log.info("Not logged in.");
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { n as PlatformClient } from "./client-
|
|
4
|
-
import {
|
|
5
|
-
import { discoverPlatform } from "./platform-cmd-
|
|
1
|
+
import { a as getApiUrl, c as getToken, d as openBrowser, g as savePlatformToken, h as runPlatformLogin } from "./auth-B9_D6ygs.mjs";
|
|
2
|
+
import { j as log } from "./dist-Dn6nn2IU.mjs";
|
|
3
|
+
import { n as PlatformClient } from "./client-PdAJ-F0t.mjs";
|
|
4
|
+
import { r as selectPlatformLoginMethod } from "./login-jKe_0QZL.mjs";
|
|
5
|
+
import { t as discoverPlatform } from "./platform-cmd-0tEh2ZtA.mjs";
|
|
6
6
|
import { execFile } from "node:child_process";
|
|
7
7
|
//#region src/cli/auth-link.ts
|
|
8
8
|
async function runAuthLink(root, connectionId) {
|
|
@@ -1,13 +1,8 @@
|
|
|
1
|
+
import { t as VoidAuthProvider } from "./providers-BNKRacMr.mjs";
|
|
1
2
|
import { i as VoidAuthConfig, n as AuthState } from "./auth-DkcFflXV.mjs";
|
|
2
3
|
import { DBFieldAttribute } from "better-auth/db";
|
|
3
4
|
import { BetterAuthOptions, betterAuth } from "better-auth";
|
|
4
5
|
import { Context } from "hono";
|
|
5
|
-
//#region src/auth/providers.d.ts
|
|
6
|
-
declare const VOID_SOCIAL_AUTH_PROVIDERS: readonly ["apple", "atlassian", "cognito", "discord", "dropbox", "facebook", "figma", "github", "gitlab", "google", "huggingface", "kakao", "kick", "line", "linear", "linkedin", "microsoft", "naver", "notion", "paybin", "paypal", "polar", "railway", "reddit", "roblox", "salesforce", "slack", "spotify", "tiktok", "twitch", "twitter", "vercel", "vk", "zoom"];
|
|
7
|
-
declare const VOID_EMAIL_AUTH_PROVIDER = "email";
|
|
8
|
-
declare const VOID_AUTH_PROVIDERS: readonly [typeof VOID_EMAIL_AUTH_PROVIDER, ...typeof VOID_SOCIAL_AUTH_PROVIDERS];
|
|
9
|
-
type VoidAuthProvider = (typeof VOID_AUTH_PROVIDERS)[number];
|
|
10
|
-
//#endregion
|
|
11
6
|
//#region src/auth/drizzle.d.ts
|
|
12
7
|
type AuthIdStrategy = "serial" | "text" | "uuid";
|
|
13
8
|
type VoidAuthMigrationField = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as isVoidSocialAuthProvider, r as getVoidAuthProviderEnvNames } from "./providers-CJlNS3kT.mjs";
|
|
2
|
-
import { authContext } from "./
|
|
2
|
+
import { t as authContext } from "./auth-3sGB0zJ1.mjs";
|
|
3
3
|
import { randomBytes, scrypt, timingSafeEqual } from "node:crypto";
|
|
4
4
|
import { betterAuth } from "better-auth";
|
|
5
5
|
//#region src/runtime/better-auth-shared.ts
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
import { a as dim, c as import_picocolors, r as cliTitle } from "./output-CCH48AMM.mjs";
|
|
2
|
+
import { c as getToken } from "./auth-B9_D6ygs.mjs";
|
|
3
|
+
import { o as readProjectConfig } from "./project-CWNIPoXc.mjs";
|
|
4
|
+
import { O as intro, P as outro, j as log } from "./dist-Dn6nn2IU.mjs";
|
|
5
|
+
import { n as PlatformClient, t as PlatformApiError } from "./client-PdAJ-F0t.mjs";
|
|
6
|
+
import { r as resolveProjectBySlug, t as getRequestedProjectSlug } from "./resolve-project-Xvis70DG.mjs";
|
|
5
7
|
import { appendFileSync, writeFileSync } from "node:fs";
|
|
6
8
|
//#region src/cli/build-cmd.ts
|
|
7
9
|
const POLL_MS = 1e3;
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
import { a as dim, i as createSpinner, r as cliTitle } from "./output-CCH48AMM.mjs";
|
|
2
|
+
import { c as getToken } from "./auth-B9_D6ygs.mjs";
|
|
3
|
+
import { o as readProjectConfig } from "./project-CWNIPoXc.mjs";
|
|
4
|
+
import { O as intro, P as outro, j as log } from "./dist-Dn6nn2IU.mjs";
|
|
5
|
+
import { n as PlatformClient } from "./client-PdAJ-F0t.mjs";
|
|
6
|
+
import { r as resolveProjectBySlug, t as getRequestedProjectSlug } from "./resolve-project-Xvis70DG.mjs";
|
|
5
7
|
//#region src/cli/cache.ts
|
|
6
8
|
async function runPurgeCacheCommand(root, projectSlug) {
|
|
7
9
|
console.log();
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { r as cliTitle } from "./output-CCH48AMM.mjs";
|
|
2
|
+
import { c as getToken } from "./auth-B9_D6ygs.mjs";
|
|
3
|
+
import { o as readProjectConfig } from "./project-CWNIPoXc.mjs";
|
|
4
|
+
import { E as confirm, O as intro, P as outro, W as isCancel, j as log } from "./dist-Dn6nn2IU.mjs";
|
|
5
|
+
import { n as PlatformClient } from "./client-PdAJ-F0t.mjs";
|
|
4
6
|
//#region src/cli/cancel-deploy.ts
|
|
5
7
|
const ACTIVE_STATUSES = /* @__PURE__ */ new Set([
|
|
6
8
|
"pending",
|