void 1.7.0 → 1.9.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/dist/{account-cmd-BfkJ_1PC.mjs → account-cmd-BEMOdwtl.mjs} +5 -5
- package/dist/{application-analysis-OV0CBJ80.mjs → application-analysis-3VVsflWZ.mjs} +28 -8
- package/dist/{application-routing-QpyC5G8z.mjs → application-routing-CJRlXCc2.mjs} +1 -1
- package/dist/{auth-CZrthGxs.d.mts → auth-CV9kXHKe.d.mts} +4 -2
- package/dist/{auth-DyWp-fSo.mjs → auth-aMuFOZeI.mjs} +8 -2
- package/dist/{auth-link-CW1Zh6FM.mjs → auth-link-B1IynRW5.mjs} +5 -5
- package/dist/{auth-router-CNBKnEZi.mjs → auth-router-DVaWJdRB.mjs} +3 -3
- package/dist/{better-auth-shared-CdVyCUou.mjs → better-auth-shared-C7LHvF4L.mjs} +1 -1
- package/dist/{better-auth-shared-C-0uZg8-.d.mts → better-auth-shared-ajs3LNrY.d.mts} +2 -2
- package/dist/boundary-plans-CRmWH68v.d.mts +25 -0
- package/dist/{build-cmd-C9qOKW9W.mjs → build-cmd-Dq8tdqQG.mjs} +4 -4
- package/dist/{cache-DVBBbWQL.mjs → cache-DGMnskX7.mjs} +4 -4
- package/dist/{cancel-deploy-COavnjud.mjs → cancel-deploy-96S5hD1E.mjs} +3 -3
- package/dist/cli/cli.mjs +1 -1
- package/dist/cli/cloudflare-operation-process.mjs +92 -19
- package/dist/cli/env-schema-probe.d.mts +1 -1
- package/dist/cli/env-schema-probe.mjs +3 -3
- package/dist/{cli-main-DFteHrJI.mjs → cli-main-CQRLxZAu.mjs} +32 -32
- package/dist/client-66c0RLDM.mjs +1 -0
- package/dist/{client-BEZmTP6p.mjs → client-D6w5x7hM.mjs} +7 -7
- package/dist/{cloudflare-auth-DGIivpTb.mjs → cloudflare-auth-pNvmT6kL.mjs} +1 -1
- package/dist/{cloudflare-cmd-DJaxC-bc.mjs → cloudflare-cmd-BuuHUM4z.mjs} +5 -5
- package/dist/{cloudflare-config-DtOGAbeB.mjs → cloudflare-config-PxbinLLE.mjs} +2 -2
- package/dist/{cloudflare-connect-BjpWmglw.mjs → cloudflare-connect-D1QOosLd.mjs} +3 -3
- package/dist/{cloudflare-operations-k7wYUv56.mjs → cloudflare-operations-G5AObYzF.mjs} +6 -6
- package/dist/{cloudflare-operations-CZkjFrzH.mjs → cloudflare-operations-I4t3mt4R.mjs} +1 -1
- package/dist/{cloudflare-process-BcPvlMFd.mjs → cloudflare-process-wcnaQ5JG.mjs} +2 -2
- package/dist/{config-wo2EaH0X.mjs → config-C1DPf8EK.mjs} +1 -1
- package/dist/{config-CTlUaXWZ.d.mts → config-CCWVY7DY.d.mts} +1 -1
- package/dist/{config-5oSQhZNj.mjs → config-CzFdJYNA.mjs} +1 -1
- package/dist/{config-DcqUBGCb.mjs → config-DlWQ_hIJ.mjs} +3 -3
- package/dist/{config-eeDzKBS9.mjs → config-Do7gJI3T.mjs} +2 -2
- package/dist/config-entry.d.mts +1 -1
- package/dist/{connect-j1F1C_rW.mjs → connect-4uImOwut.mjs} +6 -6
- package/dist/{create-project-CE3jOmd5.mjs → create-project-BaUzZnLZ.mjs} +4 -4
- package/dist/{create-project-DZH3aYGQ.mjs → create-project-CQMyzTvK.mjs} +1 -1
- package/dist/{db-DyLzzxvM.mjs → db-DEpDeDsi.mjs} +22 -22
- package/dist/{db-types-DdHHUVPy.mjs → db-types-BpPYAx0B.mjs} +4 -2
- package/dist/{delete-Dey6YoMA.mjs → delete-BVD2kI82.mjs} +4 -4
- package/dist/deploy-Dr_Qamzw.mjs +2 -0
- package/dist/{deploy-Ccw2D2lw.mjs → deploy-Dyeo5soA.mjs} +40 -81
- package/dist/{deploy-managed-static-BBVtpuGv.mjs → deploy-managed-static-Kn73R83A.mjs} +22 -22
- package/dist/{deploy-transport-Dt0IvSVW.mjs → deploy-transport-BpKBs_KR.mjs} +3 -3
- package/dist/deploy.mjs +6 -6
- package/dist/discover-Diq0l6TZ.mjs +1 -0
- package/dist/{discover-CVFCWU7W.mjs → discover-Vd18lHsj.mjs} +1 -1
- package/dist/{dispatch-pYaww76u.mjs → dispatch-BBfb519j.mjs} +8 -8
- package/dist/{dist-DeTdhbZc.mjs → dist-Cp4b1_T9.mjs} +1 -1
- package/dist/{dist-BQdgCVQF.mjs → dist-STQXl8ck.mjs} +86 -138
- package/dist/{domain-Dh3mG8Vs.mjs → domain-BTIdyUVk.mjs} +5 -5
- package/dist/{drizzle-C8MPqt5m.mjs → drizzle-D4V_06-B.mjs} +1 -1
- package/dist/{drizzle-lFdzSEa9.mjs → drizzle-DBSpPpU1.mjs} +34 -8
- package/dist/{email-DKyMjOYM.mjs → email-DvrS-I0U.mjs} +10 -10
- package/dist/{email-cloudflare-CTt2n_W2.mjs → email-cloudflare-DAGpgzY1.mjs} +16 -11
- package/dist/{entry-Bw-G1VVx.mjs → entry-DMgR7XOf.mjs} +2 -2
- package/dist/{env-DkZzh_Dd.mjs → env-D7vORwpn.mjs} +6 -6
- package/dist/{env-CuzZZyjB.mjs → env-UqS-21xi.mjs} +8 -1
- package/dist/{env-public-CeNeO_AT.d.mts → env-public-DtJL_hZq.d.mts} +8 -7
- package/dist/{env-types-Dz9qkiOn.mjs → env-types-WEZw5D-r.mjs} +1 -1
- package/dist/{env-validation-C8NL3lEH.mjs → env-validation-DKDcpxbt.mjs} +1 -1
- package/dist/{env-validation-1snjKtDX.mjs → env-validation-DeYNRp1d.mjs} +5 -5
- package/dist/{gen-BZmFOGDQ.mjs → gen-DimkGNve.mjs} +6 -6
- package/dist/gen-DmEeVEs4.mjs +1 -0
- package/dist/{github-cmd-7Oky9qgH.mjs → github-cmd-D-zs6VQr.mjs} +4 -4
- package/dist/{handler-DjqciiDc.d.mts → handler-6fzr_ikp.d.mts} +5 -4
- package/dist/{head-MeF_5M_3.d.mts → head-CVO92KEx.d.mts} +14 -3
- package/dist/{head-5XPcnG-j.mjs → head-CWJhfUwV.mjs} +62 -3
- package/dist/{headers-CimYIfQI.mjs → headers-Q0kZDpk8.mjs} +11 -2
- package/dist/{help-CNuUb47C.mjs → help-Cgdcd-SG.mjs} +6 -6
- package/dist/help-Cp3K5m1w.mjs +1 -0
- package/dist/index.d.mts +5 -5
- package/dist/index.mjs +257 -188
- package/dist/{info-DwB8IWIx.mjs → info-BbxQ34kk.mjs} +4 -4
- package/dist/{init-CUGSmcED.mjs → init-zyRj3QRw.mjs} +19 -20
- package/dist/{link-BlRTGHan.mjs → link-DAFXuIER.mjs} +5 -5
- package/dist/{list-iCg7d5Pa.mjs → list-BTIcC3W9.mjs} +5 -5
- package/dist/{live-zKGbRT4h.d.mts → live-DBybyDt0.d.mts} +2 -2
- package/dist/{live-CYJ4KGoR.mjs → live-Dw7NF1t2.mjs} +1 -1
- package/dist/load-user-env-ztmIyiLx.mjs +34 -0
- package/dist/{local-d1-CFcH9Bx3.mjs → local-d1-BnVb7Fem.mjs} +1 -1
- package/dist/login-DBs8JuSl.mjs +1 -0
- package/dist/{login-TA51e5Fw.mjs → login-DOE-MkeK.mjs} +4 -4
- package/dist/{logs-BlyAxlvx.mjs → logs-CUsjihc3.mjs} +4 -4
- package/dist/migrate-BYhoIK9R.mjs +1 -0
- package/dist/{migrate-BH6LCr00.mjs → migrate-DtoKdGas.mjs} +6 -6
- package/dist/nitro.mjs +3 -3
- package/dist/{node-B0otYjDv.mjs → node-D9dPyUr0.mjs} +4 -4
- package/dist/operator-ai-logging-DFTEp81Z.mjs +121 -0
- package/dist/{operator-args-DuKAQ3Ks.mjs → operator-args-BCCohcz3.mjs} +10 -1
- package/dist/{operator-cmd-CoHlJjcT.mjs → operator-cmd-CQOQrUiO.mjs} +27 -7
- package/dist/operator-cmd-xCACDtT1.mjs +1 -0
- package/dist/output-BsdnNpxa.mjs +1 -0
- package/dist/{output-CXJTIAtF.mjs → output-DNVILSz2.mjs} +1 -1
- package/dist/pages/client.d.mts +28 -3
- package/dist/pages/client.mjs +146 -27
- package/dist/pages/head.d.mts +2 -2
- package/dist/pages/head.mjs +1 -1
- package/dist/pages/index.d.mts +5 -4
- package/dist/pages/index.mjs +5 -5
- package/dist/pages/islands-plugin.d.mts +6 -2
- package/dist/pages/islands-plugin.mjs +18 -3
- package/dist/pages/protocol.d.mts +2 -2
- package/dist/pages/protocol.mjs +1 -1
- package/dist/platform-args-DSi4_M8n.mjs +1 -0
- package/dist/{platform-args-DfT8yQBF.mjs → platform-args-DtpHS_75.mjs} +1 -1
- package/dist/{platform-auth-config-MO0VdVs9.mjs → platform-auth-config-fLwIS5VG.mjs} +6 -6
- package/dist/{platform-auth-protection-Dv208eyL.mjs → platform-auth-protection-BTRI_YwD.mjs} +4 -4
- package/dist/{platform-auth-recovery-DvAQ674F.mjs → platform-auth-recovery-DPK2Mvmo.mjs} +4 -4
- package/dist/{platform-cmd-BpUA19r_.mjs → platform-cmd-BLy5uCa-.mjs} +1 -1
- package/dist/{platform-cmd-dlSxrcQ7.mjs → platform-cmd-HS_FSthn.mjs} +7 -7
- package/dist/{platform-domain-DSO4eUEw.mjs → platform-domain-CHpcq_qg.mjs} +4 -4
- package/dist/{platform-lifecycle-CfcFygHb.mjs → platform-lifecycle-B6LUBwjS.mjs} +1 -1
- package/dist/{platform-lifecycle-BSvsyB_x.mjs → platform-lifecycle-D2RS7DE0.mjs} +239 -29
- package/dist/{platform-management-BMdyt667.mjs → platform-management-C-T0ch4y.mjs} +1 -1
- package/dist/{platform-management-CrP1XhVd.mjs → platform-management-d3ETv3Dw.mjs} +15 -15
- package/dist/{platform-plans-config-CgDiwflR.mjs → platform-plans-config-B7yJQKf7.mjs} +116 -32
- package/dist/{platform-recovery-CHWwXVZ6.mjs → platform-recovery-DS5CAsly.mjs} +2 -2
- package/dist/{platform-setup-BTQVbnTC.mjs → platform-setup-Casiffqj.mjs} +2 -2
- package/dist/{plugin-inference-g66Q1Mx9.mjs → plugin-inference-DZHmVe1f.mjs} +4 -4
- package/dist/{prepare-DXduEwQp.mjs → prepare-AVM4Hj3T.mjs} +10 -10
- package/dist/prepare-BSXKz6m8.mjs +1 -0
- package/dist/{prepare-DJYHjpzq.mjs → prepare-DMk8NAO-.mjs} +3 -3
- package/dist/{prerender-render-BN9Lmebs.mjs → prerender-render-BAdYhivW.mjs} +15 -2
- package/dist/prerender-render.d.mts +2 -0
- package/dist/prerender-render.mjs +1 -1
- package/dist/{project-cmd-Dfb1Sg8w.mjs → project-cmd-TQKAOTMV.mjs} +17 -17
- package/dist/{project-paths-G0yut6Zz.mjs → project-paths-CUhCPMpK.mjs} +33 -2
- package/dist/{project-team-BO2dyc7S.mjs → project-team-B1OKeb-T.mjs} +4 -4
- package/dist/{project-token-ByO2mEI2.mjs → project-token-RW_wpmN-.mjs} +4 -4
- package/dist/{project-tsconfig-nhnTWO_Y.mjs → project-tsconfig-MyRJgufB.mjs} +1 -1
- package/dist/{project-zero-trust-CoQfwRBR.mjs → project-zero-trust-TNc66p0_.mjs} +4 -4
- package/dist/{protocol-yxdHxFLN.mjs → protocol-IPSWHolJ.mjs} +233 -76
- package/dist/{protocol-xZMvWsrg.d.mts → protocol-YS3tbxWE.d.mts} +10 -3
- package/dist/{provision-CMH4-8ri.mjs → provision-BLdkpFT4.mjs} +1 -1
- package/dist/{provision-D5q-ptD3.mjs → provision-bgQTi5QZ.mjs} +2 -2
- package/dist/redirect-Dqb4fEc5.mjs +80 -0
- package/dist/{requests-CPOiDkjh.mjs → requests-Cj15-yrI.mjs} +3 -3
- package/dist/resolve-project-C5wC-Hoi.mjs +1 -0
- package/dist/{resolve-project-ClvLMTI9.mjs → resolve-project-Da3OgCU1.mjs} +1 -1
- package/dist/{rollback-BfCs2la4.mjs → rollback-CYnkng7B.mjs} +4 -4
- package/dist/{route-types-Cl3x0Q8B.mjs → route-types-C6eAOmOj.mjs} +4 -3
- package/dist/routes-stub.d.mts +4 -3
- package/dist/runtime/auth.d.mts +1 -1
- package/dist/runtime/auth.mjs +1 -1
- 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 +1 -1
- package/dist/runtime/client-solid.d.mts +1 -1
- package/dist/runtime/client-svelte.d.mts +1 -1
- package/dist/runtime/client-vue.d.mts +1 -1
- package/dist/runtime/client.d.mts +1 -1
- package/dist/runtime/db.d.mts +6 -3
- package/dist/runtime/db.mjs +2 -2
- package/dist/runtime/env-public.d.mts +1 -1
- package/dist/runtime/env-public.mjs +53 -39
- package/dist/runtime/handler.d.mts +1 -1
- package/dist/runtime/live-client.d.mts +1 -1
- package/dist/runtime/live-server.mjs +1 -1
- package/dist/runtime/live.d.mts +1 -1
- package/dist/runtime/live.mjs +1 -1
- package/dist/runtime/routing.d.mts +8 -3
- package/dist/runtime/routing.mjs +164 -23
- package/dist/runtime/validator.d.mts +1 -1
- package/dist/runtime/ws-server.d.mts +3 -3
- package/dist/runtime/ws-server.mjs +1 -1
- package/dist/runtime/ws.d.mts +1 -1
- package/dist/{scan-L8OSv1f7.mjs → scan-4YOxDaw2.mjs} +230 -29
- package/dist/{secret-CuI6LTpD.mjs → secret-BSf7dgg_.mjs} +6 -6
- package/dist/{skills-BBO9wMjB.mjs → skills-CoBB9_Ao.mjs} +1 -1
- package/dist/{ast-bindings-BkivMJIo.mjs → static-exports-DFkzL-NX.mjs} +96 -33
- package/dist/{subcommand-prompt-BZMnCA8T.mjs → subcommand-prompt-0yIARXf2.mjs} +2 -2
- package/dist/{types-agfx0alu.d.mts → types-IPut3_Yx.d.mts} +15 -1
- package/dist/url-DaehRGKR.mjs +106 -0
- package/dist/{version-metadata-eUd6Ar_U.mjs → version-metadata-CeftH0fQ.mjs} +1 -1
- package/dist/{wrangler-k40T7XTQ.mjs → wrangler-B1gkT_wC.mjs} +3 -3
- package/dist/wrangler-fNGvPTlO.mjs +1 -0
- package/dist/{wrapper-BGsi_uHs.mjs → wrapper-xJ4LP5A7.mjs} +3 -3
- package/dist/{ws-DB8Feytg.d.mts → ws-C2zy0QBf.d.mts} +2 -2
- package/docs/guide/ai.md +2 -1
- package/docs/guide/app-types.md +1 -0
- package/docs/guide/auth.md +23 -27
- package/docs/guide/database/d1.md +18 -1
- package/docs/guide/database/mysql.md +1 -0
- package/docs/guide/database/postgresql.md +1 -0
- package/docs/guide/database.md +30 -27
- package/docs/guide/deployment.md +3 -2
- package/docs/guide/durable-state.md +1 -0
- package/docs/guide/edge/headers.md +4 -3
- package/docs/guide/edge/prerendering.md +6 -5
- package/docs/guide/edge/redirects.md +2 -1
- package/docs/guide/edge/revalidation.md +6 -1
- package/docs/guide/edge/rewrites.md +2 -1
- package/docs/guide/edge/static-assets.md +5 -0
- package/docs/guide/email/domains.md +1 -0
- package/docs/guide/email/receiving.md +3 -2
- package/docs/guide/email/sending.md +7 -4
- package/docs/guide/email.md +1 -0
- package/docs/guide/env-vars.md +4 -0
- package/docs/guide/index.md +1 -0
- package/docs/guide/jobs.md +1 -0
- package/docs/guide/kv.md +1 -0
- package/docs/guide/live.md +2 -1
- package/docs/guide/pages-routing/actions-and-forms.md +58 -22
- package/docs/guide/pages-routing/errors.md +109 -0
- package/docs/guide/pages-routing/head.md +45 -1
- package/docs/guide/pages-routing/islands.md +4 -1
- package/docs/guide/pages-routing/layouts.md +4 -1
- package/docs/guide/pages-routing/loaders.md +4 -1
- package/docs/guide/pages-routing/markdown.md +6 -4
- package/docs/guide/pages-routing/overview.md +16 -20
- package/docs/guide/pages-routing/view-transitions.md +1 -0
- package/docs/guide/platform/administration/access.md +1 -0
- package/docs/guide/platform/administration/connected-apps.md +13 -2
- package/docs/guide/platform/administration/email.md +1 -0
- package/docs/guide/platform/administration/operations.md +1 -0
- package/docs/guide/platform/administration/plans.md +35 -1
- package/docs/guide/platform/administration/projects.md +16 -1
- package/docs/guide/platform/administration/zero-trust.md +1 -0
- package/docs/guide/platform/development/local.md +1 -0
- package/docs/guide/platform/development/runtime.md +1 -0
- package/docs/guide/platform/development/schema-ci.md +1 -0
- package/docs/guide/platform/installation/ci.md +1 -0
- package/docs/guide/platform/installation/credentials.md +12 -9
- package/docs/guide/platform/installation/domains.md +1 -0
- package/docs/guide/platform/installation/first-deployment.md +1 -0
- package/docs/guide/platform/installation/maintenance.md +8 -1
- package/docs/guide/platform/installation/prerequisites.md +1 -0
- package/docs/guide/platform/installation/setup.md +9 -7
- package/docs/guide/platform/installation/uninstall.md +1 -0
- package/docs/guide/platform-administration.md +1 -0
- package/docs/guide/platform-development.md +1 -0
- package/docs/guide/project-collaboration.md +1 -0
- package/docs/guide/queues.md +3 -0
- package/docs/guide/quickstart.md +3 -2
- package/docs/guide/remote-dev.md +1 -0
- package/docs/guide/sandboxes.md +1 -0
- package/docs/guide/self-hosted-platform.md +1 -0
- package/docs/guide/server-routing.md +3 -2
- package/docs/guide/sse.md +2 -1
- package/docs/guide/ssg.md +18 -6
- package/docs/guide/ssr.md +1 -0
- package/docs/guide/storage.md +2 -1
- package/docs/guide/testing.md +64 -0
- package/docs/guide/type-safety.md +24 -21
- package/docs/guide/typed-fetch.md +1 -0
- package/docs/guide/websockets.md +1 -0
- package/docs/index.md +1 -0
- package/docs/integrations/agents.md +1 -0
- package/docs/integrations/cloudflare.md +7 -2
- package/docs/integrations/frameworks/analog.md +1 -0
- package/docs/integrations/frameworks/astro.md +1 -0
- package/docs/integrations/frameworks/nuxt.md +2 -1
- package/docs/integrations/frameworks/overview.md +1 -0
- package/docs/integrations/frameworks/react-router.md +1 -0
- package/docs/integrations/frameworks/sveltekit.md +1 -0
- package/docs/integrations/frameworks/tanstack-start.md +1 -0
- package/docs/integrations/hono.md +22 -0
- package/docs/integrations/nodejs-bun-deno.md +5 -4
- package/docs/reference/api/auth.md +23 -4
- package/docs/reference/api/client.md +1 -0
- package/docs/reference/api/database.md +24 -1
- package/docs/reference/api/deploy.md +4 -0
- package/docs/reference/api/durable.md +1 -0
- package/docs/reference/api/env.md +1 -0
- package/docs/reference/api/handlers.md +1 -0
- package/docs/reference/api/pages.md +38 -16
- package/docs/reference/api/plugin.md +1 -0
- package/docs/reference/api/resources.md +2 -1
- package/docs/reference/api/rewrites.md +9 -4
- package/docs/reference/api/types.md +1 -0
- package/docs/reference/api.md +2 -1
- package/docs/reference/cli/auth.md +1 -0
- package/docs/reference/cli/database.md +1 -0
- package/docs/reference/cli/deploy.md +5 -2
- package/docs/reference/cli/domains.md +1 -0
- package/docs/reference/cli/email.md +1 -0
- package/docs/reference/cli/generate.md +1 -0
- package/docs/reference/cli/github.md +1 -0
- package/docs/reference/cli/platform-config.md +4 -3
- package/docs/reference/cli/platform-email.md +1 -0
- package/docs/reference/cli/platform-installation.md +1 -0
- package/docs/reference/cli/platform-operations.md +1 -0
- package/docs/reference/cli/platform-users.md +71 -1
- package/docs/reference/cli/platform-zero-trust.md +1 -0
- package/docs/reference/cli/platform.md +1 -0
- package/docs/reference/cli/project.md +1 -0
- package/docs/reference/cli/secrets.md +1 -0
- package/docs/reference/cli/setup.md +1 -0
- package/docs/reference/cli.md +3 -0
- package/docs/reference/config.md +8 -3
- package/docs/reference/resource-inference.md +1 -0
- package/docs/reference/structure.md +1 -0
- package/package.json +25 -25
- package/skills/void/SKILL.md +3 -1
- package/dist/action-key-XtKKbbsi.mjs +0 -25
- package/dist/client-BAxLpSKv.mjs +0 -1
- package/dist/deploy-DEZkUS77.mjs +0 -2
- package/dist/discover-1DJD4YXD.mjs +0 -1
- package/dist/gen-C6iknRdI.mjs +0 -1
- package/dist/help-C_cqTByy.mjs +0 -1
- package/dist/load-user-env-CSwdofj0.mjs +0 -48
- package/dist/login-C4q1S-5b.mjs +0 -1
- package/dist/migrate-CVBsSFhC.mjs +0 -1
- package/dist/operator-cmd-DnaCnCSP.mjs +0 -1
- package/dist/output-CNsMDEd2.mjs +0 -1
- package/dist/platform-args-B7-wQ0_B.mjs +0 -1
- package/dist/prepare-Bx4a8cb1.mjs +0 -1
- package/dist/resolve-project-BALVa9q0.mjs +0 -1
- package/dist/url-CuoEn0o3.mjs +0 -43
- package/dist/wrangler-R3kMdJfw.mjs +0 -1
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { L as log } from "./dist-
|
|
1
|
+
import { L as log } from "./dist-STQXl8ck.mjs";
|
|
2
2
|
import { c as getToken, f as removeToken } from "./auth-CCk9Seol.mjs";
|
|
3
|
-
import { r as PlatformClient } from "./client-
|
|
4
|
-
import { n as runLoginCommand } from "./login-
|
|
5
|
-
import { m as printSuccess } from "./output-
|
|
3
|
+
import { r as PlatformClient } from "./client-D6w5x7hM.mjs";
|
|
4
|
+
import { n as runLoginCommand } from "./login-DOE-MkeK.mjs";
|
|
5
|
+
import { m as printSuccess } from "./output-DNVILSz2.mjs";
|
|
6
6
|
import { execSync } from "node:child_process";
|
|
7
7
|
// src/cli/account-cmd.ts
|
|
8
8
|
async function runAccountCommand(root, args) {
|
|
9
9
|
switch (args.subcommand) {
|
|
10
10
|
case "login": return runLoginCommand(root);
|
|
11
|
-
case "link": return import("./auth-link-
|
|
11
|
+
case "link": return import("./auth-link-B1IynRW5.mjs").then(({ runAuthLink }) => runAuthLink(root, args.connectionId));
|
|
12
12
|
case "logout":
|
|
13
13
|
if (removeToken(root)) printSuccess("Logged out.");
|
|
14
14
|
else log.info("Not logged in.");
|
|
@@ -1,13 +1,14 @@
|
|
|
1
|
-
import { c as scanWebSocketRoutesSync, d as readResourceDefinition, f as listConventionFiles, h as needsApplicationDatabase, i as inferProjectBindings, n as FRAMEWORK_SCAN_DIRS, p as listRouteFiles, r as detectFramework, s as isWebSocketPatternFile } from "./plugin-inference-
|
|
2
|
-
import { r as findVoidAuthConfig } from "./config-
|
|
3
|
-
import { l as getDatabaseDialect, m as resolveBindingNames } from "./config-
|
|
1
|
+
import { c as scanWebSocketRoutesSync, d as readResourceDefinition, f as listConventionFiles, h as needsApplicationDatabase, i as inferProjectBindings, n as FRAMEWORK_SCAN_DIRS, p as listRouteFiles, r as detectFramework, s as isWebSocketPatternFile } from "./plugin-inference-DZHmVe1f.mjs";
|
|
2
|
+
import { r as findVoidAuthConfig } from "./config-Do7gJI3T.mjs";
|
|
3
|
+
import { l as getDatabaseDialect, m as resolveBindingNames } from "./config-CzFdJYNA.mjs";
|
|
4
4
|
import { a as join, i as isAbsolute, t as basename } from "./dist-DMYe8CZJ.mjs";
|
|
5
|
-
import { a as
|
|
5
|
+
import { a as unwrapStaticExpression, i as staticLiteral, n as readStaticExports, o as bindingNames, t as mayExportAll } from "./static-exports-DFkzL-NX.mjs";
|
|
6
6
|
import { n as resourceNameWords } from "./resource-name-DlJ9QXzg.mjs";
|
|
7
7
|
import { t as collectMigrations } from "./collect-C6Blu9yw.mjs";
|
|
8
|
-
import { i as resolveProjectPaths, n as readProjectPaths } from "./project-paths-
|
|
8
|
+
import { i as resolveProjectPaths, n as readProjectPaths } from "./project-paths-CUhCPMpK.mjs";
|
|
9
|
+
import { i as voidWarn } from "./log-D9hwSySP.mjs";
|
|
9
10
|
import { i as scanEmailHandlersSync } from "./email-BHY72ixO.mjs";
|
|
10
|
-
import {
|
|
11
|
+
import { _ as isRouteEnabledForEnvironment, g as compareRouteSpecificity, n as scanPages, v as parseRouteFilename } from "./scan-4YOxDaw2.mjs";
|
|
11
12
|
import { n as globSync } from "./dist-BWNkVq50.mjs";
|
|
12
13
|
import { n as isIdentifier, o as moduleExportName } from "./ast-Cv0JwXqb.mjs";
|
|
13
14
|
import { existsSync, readFileSync, readdirSync } from "node:fs";
|
|
@@ -19,7 +20,7 @@ function extractJobName(filePath) {
|
|
|
19
20
|
return filePath.replace(/\.[^.]+$/, "");
|
|
20
21
|
}
|
|
21
22
|
function extractCronExpressions(source, filePath) {
|
|
22
|
-
const initializer = unwrapStaticExpression(
|
|
23
|
+
const initializer = unwrapStaticExpression(readStaticExports(filePath, source, /* @__PURE__ */ new Set(["cron"])).initializers.get("cron"));
|
|
23
24
|
if (!initializer) throw new Error(`cron: Invalid job file '${filePath}'. Add \`export const cron = "<schedule>"\`.`);
|
|
24
25
|
const values = initializer.type === "ArrayExpression" ? initializer.elements ?? [] : [initializer];
|
|
25
26
|
if (values.length === 0) throw new Error(`cron: Invalid job file '${filePath}'. Cron array cannot be empty.`);
|
|
@@ -90,12 +91,31 @@ const OPTION_NAMES = [
|
|
|
90
91
|
"maxRetries",
|
|
91
92
|
"retryDelay"
|
|
92
93
|
];
|
|
94
|
+
const OPTION_NAME_SET = new Set(OPTION_NAMES);
|
|
95
|
+
/** Queue files already warned about `export *`; a dev server rescans queues on every change. */
|
|
96
|
+
const warnedExportAll = /* @__PURE__ */ new Set();
|
|
97
|
+
/**
|
|
98
|
+
* Consumer options configure Cloudflare before any queue code runs, so they are
|
|
99
|
+
* read from the source. Reject exports whose value the source does not show,
|
|
100
|
+
* instead of deploying Cloudflare's defaults.
|
|
101
|
+
*/
|
|
102
|
+
function readOptionInitializers(absPath, filePath, source) {
|
|
103
|
+
if (!OPTION_NAMES.some((option) => source.includes(option)) && !mayExportAll(source)) return /* @__PURE__ */ new Map();
|
|
104
|
+
const exports = readStaticExports(absPath, source, OPTION_NAME_SET);
|
|
105
|
+
const unreadable = OPTION_NAMES.find((option) => exports.unreadable.has(option));
|
|
106
|
+
if (unreadable) throw new Error(`queue: ${unreadable} in '${filePath}' must be declared in the queue file as \`export const ${unreadable} = <integer>\`. Re-exported options and other export forms are not read.`);
|
|
107
|
+
if (exports.exportsAll && OPTION_NAMES.some((option) => !exports.initializers.has(option)) && !warnedExportAll.has(absPath)) {
|
|
108
|
+
warnedExportAll.add(absPath);
|
|
109
|
+
voidWarn(`queue: '${filePath}' uses \`export * from\`. Void does not read consumer options through it, so declare them in the queue file with \`export const\`. Re-export other names individually to remove this warning.`);
|
|
110
|
+
}
|
|
111
|
+
return exports.initializers;
|
|
112
|
+
}
|
|
93
113
|
function scanQueuesSync(queuesDir) {
|
|
94
114
|
const definitions = listConventionFiles(queuesDir).sort().map((filePath) => {
|
|
95
115
|
const absPath = join(queuesDir, filePath);
|
|
96
116
|
const source = readFileSync(absPath, "utf-8");
|
|
97
117
|
const name = extractName(filePath);
|
|
98
|
-
const options =
|
|
118
|
+
const options = readOptionInitializers(absPath, filePath, source);
|
|
99
119
|
const optionValue = (option) => {
|
|
100
120
|
const initializer = options.get(option);
|
|
101
121
|
if (!initializer) return;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { l as scanRoutes, t as analyzeApplicationSync } from "./application-analysis-
|
|
1
|
+
import { l as scanRoutes, t as analyzeApplicationSync } from "./application-analysis-3VVsflWZ.mjs";
|
|
2
2
|
// src/application-routing.ts
|
|
3
3
|
/** Complete route/page analysis using the same resource and handler inventories. */
|
|
4
4
|
async function completeApplicationAnalysis(analysis) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
2
|
-
import { Auth, BetterAuthOptions, Session, User } from "better-auth";
|
|
3
2
|
import { Context, Env } from "hono";
|
|
3
|
+
import { Auth, BetterAuthOptions, Session, User } from "better-auth";
|
|
4
4
|
/**
|
|
5
5
|
* Filled in by the generated `.void/auth.d.ts` with the user and session types
|
|
6
6
|
* Better Auth infers from the app's `auth.ts`. Empty when the app has no
|
|
@@ -71,5 +71,7 @@ declare function requireAuth<E extends Env & {
|
|
|
71
71
|
Variables: {
|
|
72
72
|
user: AuthUser | null;
|
|
73
73
|
};
|
|
74
|
-
}>(c: Context<E
|
|
74
|
+
}>(c: Context<E>, options?: {
|
|
75
|
+
throwRedirect?: string;
|
|
76
|
+
}): AuthUser;
|
|
75
77
|
export { InferAuthInstance as a, VoidAuthConfigContext as c, defineAuth as d, getAuth as f, requireAuth as h, AuthUser as i, VoidAuthTypes as l, getUser as m, AuthSession as n, InferAuthSession as o, getSession as p, AuthState as r, VoidAuthConfig as s, AuthInstance as t, authContext as u };
|
|
@@ -19,9 +19,15 @@ function getAuth(c) {
|
|
|
19
19
|
if (!auth) throw new Error("Better Auth is not available for this request. Enable auth in void.config.ts.");
|
|
20
20
|
return auth;
|
|
21
21
|
}
|
|
22
|
-
function requireAuth(c) {
|
|
22
|
+
function requireAuth(c, options) {
|
|
23
23
|
const user = c.get("user");
|
|
24
|
-
if (!user)
|
|
24
|
+
if (!user) {
|
|
25
|
+
if (options?.throwRedirect !== void 0) {
|
|
26
|
+
const status = c.req.method === "GET" || c.req.method === "HEAD" ? 302 : 303;
|
|
27
|
+
throw new HTTPException(status, { res: c.redirect(options.throwRedirect, status) });
|
|
28
|
+
}
|
|
29
|
+
throw new HTTPException(401, { message: "Unauthorized" });
|
|
30
|
+
}
|
|
25
31
|
return user;
|
|
26
32
|
}
|
|
27
33
|
export { getUser as a, getSession as i, defineAuth as n, requireAuth as o, getAuth as r, authContext as t };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { L as log } from "./dist-
|
|
1
|
+
import { L as log } from "./dist-STQXl8ck.mjs";
|
|
2
2
|
import { a as getApiUrl, c as getToken, m as savePlatformToken, p as runPlatformLogin, u as openBrowser } from "./auth-CCk9Seol.mjs";
|
|
3
|
-
import { r as PlatformClient } from "./client-
|
|
4
|
-
import { r as selectPlatformLoginMethod } from "./login-
|
|
5
|
-
import { l as formatUrl } from "./output-
|
|
6
|
-
import { t as discoverPlatform } from "./platform-cmd-
|
|
3
|
+
import { r as PlatformClient } from "./client-D6w5x7hM.mjs";
|
|
4
|
+
import { r as selectPlatformLoginMethod } from "./login-DOE-MkeK.mjs";
|
|
5
|
+
import { l as formatUrl } from "./output-DNVILSz2.mjs";
|
|
6
|
+
import { t as discoverPlatform } from "./platform-cmd-HS_FSthn.mjs";
|
|
7
7
|
// src/cli/auth-link.ts
|
|
8
8
|
async function runAuthLink(root, connectionId) {
|
|
9
9
|
const token = getToken(root);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { K as select, tt as isCancel } from "./dist-
|
|
1
|
+
import { K as select, tt as isCancel } from "./dist-STQXl8ck.mjs";
|
|
2
2
|
import { c as normalizePlatformApiUrl, s as listPlatformConnections } from "./platform-registry-DZ_2Xuqd.mjs";
|
|
3
3
|
import { n as readDeploymentPlatform } from "./project-CLwxcEdq.mjs";
|
|
4
4
|
// src/cli/auth-router.ts
|
|
@@ -39,11 +39,11 @@ async function chooseDestination(root, args, interactive) {
|
|
|
39
39
|
async function runAuthRouter(root, args, interactive = Boolean(process.stdin.isTTY)) {
|
|
40
40
|
const destination = await chooseDestination(root, args, interactive);
|
|
41
41
|
if (destination.platform === "cloudflare") {
|
|
42
|
-
const { runCloudflareCommand } = await import("./cloudflare-cmd-
|
|
42
|
+
const { runCloudflareCommand } = await import("./cloudflare-cmd-BuuHUM4z.mjs");
|
|
43
43
|
await runCloudflareCommand(root, { subcommand: args.subcommand });
|
|
44
44
|
return;
|
|
45
45
|
}
|
|
46
|
-
const { runAccountCommand } = await import("./account-cmd-
|
|
46
|
+
const { runAccountCommand } = await import("./account-cmd-BEMOdwtl.mjs");
|
|
47
47
|
const subcommand = args.subcommand === "status" ? "whoami" : args.subcommand;
|
|
48
48
|
if (!destination.apiUrl) {
|
|
49
49
|
await runAccountCommand(root, { subcommand });
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { i as getVoidAuthProviderSettingEnvNames, o as isVoidSocialAuthProvider, r as getVoidAuthProviderEnvNames } from "./providers-ZARwX2cL.mjs";
|
|
2
2
|
import { i as authDependentRequests, r as SHARED_CACHE_HEADERS, t as isUnchangedStaticAsset } from "./static-asset-marker-DsQKz6lt.mjs";
|
|
3
|
-
import { t as authContext } from "./auth-
|
|
3
|
+
import { t as authContext } from "./auth-aMuFOZeI.mjs";
|
|
4
4
|
import { randomBytes, scrypt, timingSafeEqual } from "node:crypto";
|
|
5
5
|
import { betterAuth } from "better-auth";
|
|
6
6
|
// src/runtime/better-auth-shared.ts
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as VoidAuthProvider } from "./providers-D5P8j_8D.mjs";
|
|
2
|
-
import { r as AuthState, s as VoidAuthConfig } from "./auth-
|
|
3
|
-
import { BetterAuthOptions, betterAuth } from "better-auth";
|
|
2
|
+
import { r as AuthState, s as VoidAuthConfig } from "./auth-CV9kXHKe.mjs";
|
|
4
3
|
import { Context } from "hono";
|
|
4
|
+
import { BetterAuthOptions, betterAuth } from "better-auth";
|
|
5
5
|
import { DBFieldAttribute } from "better-auth/db";
|
|
6
6
|
type AuthIdStrategy = "serial" | "text" | "uuid";
|
|
7
7
|
type VoidAuthMigrationField = {
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
type BoundaryPlan = {
|
|
2
|
+
id: string;
|
|
3
|
+
componentId: string;
|
|
4
|
+
filePath: string;
|
|
5
|
+
directory: string;
|
|
6
|
+
kind: "error" | "not-found";
|
|
7
|
+
source: string;
|
|
8
|
+
layouts: Array<string>;
|
|
9
|
+
};
|
|
10
|
+
type PageBoundaryPlans = {
|
|
11
|
+
notFound?: string;
|
|
12
|
+
notFoundErrors?: Array<string>;
|
|
13
|
+
errors: Array<string>;
|
|
14
|
+
catches: Array<{
|
|
15
|
+
depth: number;
|
|
16
|
+
plan: string;
|
|
17
|
+
}>;
|
|
18
|
+
};
|
|
19
|
+
type BoundaryManifest = {
|
|
20
|
+
plans: Record<string, BoundaryPlan>;
|
|
21
|
+
pages: Record<string, PageBoundaryPlans>;
|
|
22
|
+
root?: string;
|
|
23
|
+
rootErrors?: Array<string>;
|
|
24
|
+
};
|
|
25
|
+
export { BoundaryManifest as t };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { H as outro, L as log } from "./dist-
|
|
1
|
+
import { H as outro, L as log } from "./dist-STQXl8ck.mjs";
|
|
2
2
|
import { c as getToken } from "./auth-CCk9Seol.mjs";
|
|
3
|
-
import { n as PlatformApiError, r as PlatformClient } from "./client-
|
|
4
|
-
import { f as import_picocolors, i as dim, m as printSuccess } from "./output-
|
|
3
|
+
import { n as PlatformApiError, r as PlatformClient } from "./client-D6w5x7hM.mjs";
|
|
4
|
+
import { f as import_picocolors, i as dim, m as printSuccess } from "./output-DNVILSz2.mjs";
|
|
5
5
|
import { r as readProjectConfig } from "./project-CLwxcEdq.mjs";
|
|
6
|
-
import { a as resolveProjectBySlug, t as getRequestedProjectSlug } from "./resolve-project-
|
|
6
|
+
import { a as resolveProjectBySlug, t as getRequestedProjectSlug } from "./resolve-project-Da3OgCU1.mjs";
|
|
7
7
|
import { appendFileSync, writeFileSync } from "node:fs";
|
|
8
8
|
// src/cli/build-cmd.ts
|
|
9
9
|
const POLL_MS = 1e3;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { L as log } from "./dist-
|
|
1
|
+
import { L as log } from "./dist-STQXl8ck.mjs";
|
|
2
2
|
import { c as getToken } from "./auth-CCk9Seol.mjs";
|
|
3
|
-
import { r as PlatformClient } from "./client-
|
|
4
|
-
import { m as printSuccess, o as formatCount, r as createSpinner } from "./output-
|
|
3
|
+
import { r as PlatformClient } from "./client-D6w5x7hM.mjs";
|
|
4
|
+
import { m as printSuccess, o as formatCount, r as createSpinner } from "./output-DNVILSz2.mjs";
|
|
5
5
|
import { r as readProjectConfig } from "./project-CLwxcEdq.mjs";
|
|
6
|
-
import { a as resolveProjectBySlug, t as getRequestedProjectSlug } from "./resolve-project-
|
|
6
|
+
import { a as resolveProjectBySlug, t as getRequestedProjectSlug } from "./resolve-project-Da3OgCU1.mjs";
|
|
7
7
|
// src/cli/cache.ts
|
|
8
8
|
async function runPurgeCacheCommand(root, projectSlug) {
|
|
9
9
|
console.log();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { A as confirm, H as outro, L as log, tt as isCancel } from "./dist-
|
|
1
|
+
import { A as confirm, H as outro, L as log, tt as isCancel } from "./dist-STQXl8ck.mjs";
|
|
2
2
|
import { c as getToken } from "./auth-CCk9Seol.mjs";
|
|
3
|
-
import { r as PlatformClient } from "./client-
|
|
4
|
-
import { m as printSuccess } from "./output-
|
|
3
|
+
import { r as PlatformClient } from "./client-D6w5x7hM.mjs";
|
|
4
|
+
import { m as printSuccess } from "./output-DNVILSz2.mjs";
|
|
5
5
|
import { r as readProjectConfig } from "./project-CLwxcEdq.mjs";
|
|
6
6
|
// src/cli/cancel-deploy.ts
|
|
7
7
|
const ACTIVE_STATUSES = /* @__PURE__ */ new Set([
|
package/dist/cli/cli.mjs
CHANGED
|
@@ -84,5 +84,5 @@ const message = unsupportedRuntimeMessage(process.versions, process.execPath);
|
|
|
84
84
|
if (message) {
|
|
85
85
|
process.stderr.write(`${message}\n`);
|
|
86
86
|
process.exitCode = 1;
|
|
87
|
-
} else await import("../cli-main-
|
|
87
|
+
} else await import("../cli-main-CQRLxZAu.mjs");
|
|
88
88
|
export {};
|
|
@@ -4,7 +4,7 @@ import { a as join, c as resolve, n as dirname } from "../dist-DMYe8CZJ.mjs";
|
|
|
4
4
|
import { i as safePositional, n as isD1Bookmark, r as readCfUploadOutput, t as CF_VERSION_SOURCE_MAX_OUTPUT_BYTES } from "../cf-command-values-Ccl-zRhl.mjs";
|
|
5
5
|
import { n as getCfCliVersion, r as getVoidUserAgent, t as publishCloudflareWorkerSettings } from "../cf-worker-settings-CARs4Wy9.mjs";
|
|
6
6
|
import { t as require_picocolors } from "../picocolors-D1NxSLw-.mjs";
|
|
7
|
-
import { l as formatUrl } from "../output-
|
|
7
|
+
import { l as formatUrl } from "../output-DNVILSz2.mjs";
|
|
8
8
|
import { t as sanitizeTerminalLogText } from "../terminal-log-text-DNsWJREL.mjs";
|
|
9
9
|
import { copyFileSync, mkdtempSync, readFileSync, rmSync, writeFileSync } from "node:fs";
|
|
10
10
|
import { fileURLToPath } from "node:url";
|
|
@@ -437,7 +437,8 @@ function apiHeaders() {
|
|
|
437
437
|
async function readApiHeaders() {
|
|
438
438
|
const key = process.env.CLOUDFLARE_API_KEY ?? process.env.CF_API_KEY;
|
|
439
439
|
const email = process.env.CLOUDFLARE_EMAIL ?? process.env.CF_EMAIL;
|
|
440
|
-
|
|
440
|
+
const token = process.env.CLOUDFLARE_API_TOKEN || process.env.CF_API_TOKEN;
|
|
441
|
+
if (key && email && !token) return {
|
|
441
442
|
"User-Agent": getVoidUserAgent(),
|
|
442
443
|
"X-Auth-Key": key,
|
|
443
444
|
"X-Auth-Email": email
|
|
@@ -821,24 +822,91 @@ function email() {
|
|
|
821
822
|
default: throw new Error("Unsupported Cloudflare Email operation.");
|
|
822
823
|
}
|
|
823
824
|
}
|
|
825
|
+
async function postWorkersApi(path, body) {
|
|
826
|
+
const response = await fetch(`${apiBaseUrl()}/accounts/${encodeURIComponent(accountId())}/workers/workers${path}`, {
|
|
827
|
+
method: "POST",
|
|
828
|
+
headers: {
|
|
829
|
+
...await apiHeaders(),
|
|
830
|
+
"Content-Type": "application/json"
|
|
831
|
+
},
|
|
832
|
+
body: JSON.stringify(body),
|
|
833
|
+
redirect: "error",
|
|
834
|
+
signal: AbortSignal.timeout(3e4)
|
|
835
|
+
});
|
|
836
|
+
const parsed = await response.json().catch(() => null);
|
|
837
|
+
return {
|
|
838
|
+
status: response.status,
|
|
839
|
+
body: parsed && typeof parsed === "object" && !Array.isArray(parsed) ? parsed : null
|
|
840
|
+
};
|
|
841
|
+
}
|
|
842
|
+
/** An error that keeps the first few reasons Cloudflare gave, so the user can act on them. */
|
|
843
|
+
function workersApiFailure(action, response) {
|
|
844
|
+
const reasons = (Array.isArray(response.body?.errors) ? response.body.errors : []).slice(0, 3).flatMap((error) => {
|
|
845
|
+
if (!error || typeof error !== "object") return [];
|
|
846
|
+
const { code, message } = error;
|
|
847
|
+
if (typeof message !== "string" || !message) return [];
|
|
848
|
+
return [`${typeof code === "number" ? `code ${code}: ` : ""}${message.slice(0, 300)}`];
|
|
849
|
+
});
|
|
850
|
+
return new Error([`Cloudflare did not ${action} (HTTP ${response.status}).`, ...reasons].join("\n"));
|
|
851
|
+
}
|
|
852
|
+
function workerWithoutDeploymentMessage(worker) {
|
|
853
|
+
return [
|
|
854
|
+
`Cloudflare Worker "${worker}" exists but has no deployment, so Void cannot set its secrets.`,
|
|
855
|
+
"If a deploy or secret command is running for this Worker, wait for it to finish and run this command again.",
|
|
856
|
+
`Otherwise, run \`void deploy\` first. If the deploy stops because a required secret is missing, delete the Worker "${worker}" in the Cloudflare dashboard (Workers & Pages) and run this command again.`
|
|
857
|
+
].join("\n");
|
|
858
|
+
}
|
|
859
|
+
/**
|
|
860
|
+
* Set secrets on a Worker that has no deployed code yet.
|
|
861
|
+
*
|
|
862
|
+
* Cloudflare keeps secrets on deployed Worker versions, so the secrets go live inside an empty
|
|
863
|
+
* placeholder that the first `void deploy` replaces. Deploy that placeholder only to a Worker this
|
|
864
|
+
* command created: when a first `void deploy` or another secret command creates the Worker after
|
|
865
|
+
* the 10007, a placeholder would replace that app or its secrets. The Worker create fails (409)
|
|
866
|
+
* when the name is taken, and the placeholder and its secrets go live in one request.
|
|
867
|
+
*
|
|
868
|
+
* A Worker that exists without a deployment (another command is setting it up, or an earlier one
|
|
869
|
+
* failed after the create) cannot tell those cases apart, so this fails with the recovery steps.
|
|
870
|
+
*/
|
|
871
|
+
async function setSecretsOnWorkerWithoutCode(worker, values, retry) {
|
|
872
|
+
const created = await postWorkersApi("", {
|
|
873
|
+
name: worker,
|
|
874
|
+
subdomain: {
|
|
875
|
+
enabled: false,
|
|
876
|
+
previews_enabled: false
|
|
877
|
+
}
|
|
878
|
+
});
|
|
879
|
+
if (created.status === 409) {
|
|
880
|
+
const retried = retry();
|
|
881
|
+
if (retried.status === 0 || retried.errorCode !== 10007 && retried.errorCode !== 10013) return retried;
|
|
882
|
+
return result(1, "", workerWithoutDeploymentMessage(worker));
|
|
883
|
+
}
|
|
884
|
+
if (created.status !== 200 || created.body?.success !== true) throw workersApiFailure("create the Worker", created);
|
|
885
|
+
const { VOID_SECRET_DRAFT_MESSAGE, VOID_SECRET_DRAFT_SOURCE } = await import("@void/deploy-cloudflare");
|
|
886
|
+
const uploaded = await postWorkersApi(`/${encodeURIComponent(worker)}/versions?deploy=true`, {
|
|
887
|
+
main_module: "index.js",
|
|
888
|
+
modules: [{
|
|
889
|
+
name: "index.js",
|
|
890
|
+
content_type: "application/javascript+module",
|
|
891
|
+
content_base64: Buffer.from(VOID_SECRET_DRAFT_SOURCE).toString("base64")
|
|
892
|
+
}],
|
|
893
|
+
compatibility_date: config().compatibility_date ?? "2025-01-01",
|
|
894
|
+
bindings: Object.entries(values).map(([name, text]) => ({
|
|
895
|
+
type: "secret_text",
|
|
896
|
+
name,
|
|
897
|
+
text
|
|
898
|
+
})),
|
|
899
|
+
annotations: { "workers/message": VOID_SECRET_DRAFT_MESSAGE }
|
|
900
|
+
});
|
|
901
|
+
if (uploaded.status !== 200 || uploaded.body?.success !== true) throw workersApiFailure("deploy the secret placeholder", uploaded);
|
|
902
|
+
return result(0);
|
|
903
|
+
}
|
|
824
904
|
async function secrets() {
|
|
825
905
|
const worker = workerName();
|
|
826
|
-
const apply = async (action) => {
|
|
906
|
+
const apply = async (values, action) => {
|
|
827
907
|
const first = action();
|
|
828
908
|
if (first.status === 0 || first.errorCode !== 10007) return first;
|
|
829
|
-
|
|
830
|
-
name: worker,
|
|
831
|
-
account_id: process.env.CLOUDFLARE_ACCOUNT_ID ?? config().account_id,
|
|
832
|
-
compatibility_date: config().compatibility_date ?? "2025-01-01",
|
|
833
|
-
workers_dev: false,
|
|
834
|
-
preview_urls: false
|
|
835
|
-
}, null, (directory) => runCf([
|
|
836
|
-
"deploy",
|
|
837
|
-
"--prebuilt",
|
|
838
|
-
"--message",
|
|
839
|
-
"void:secret-draft"
|
|
840
|
-
], directory));
|
|
841
|
-
return draft.status === 0 ? action() : draft;
|
|
909
|
+
return setSecretsOnWorkerWithoutCode(worker, values, action);
|
|
842
910
|
};
|
|
843
911
|
switch (operation.type) {
|
|
844
912
|
case "secret.list": return runCf([
|
|
@@ -855,7 +923,7 @@ async function secrets() {
|
|
|
855
923
|
name,
|
|
856
924
|
text: value,
|
|
857
925
|
type: "secret_text"
|
|
858
|
-
}), (path) => apply(() => runCf([
|
|
926
|
+
}), (path) => apply({ [name]: value }, () => runCf([
|
|
859
927
|
"workers",
|
|
860
928
|
"secrets",
|
|
861
929
|
"update",
|
|
@@ -868,11 +936,16 @@ async function secrets() {
|
|
|
868
936
|
}
|
|
869
937
|
case "secret.bulk": {
|
|
870
938
|
const values = object(parsedJson(readFileSync(0, "utf8")));
|
|
871
|
-
const
|
|
939
|
+
const texts = {};
|
|
940
|
+
for (const [name, text] of Object.entries(values)) {
|
|
941
|
+
if (typeof text !== "string") throw new Error("Secret values must be strings.");
|
|
942
|
+
texts[name] = text;
|
|
943
|
+
}
|
|
944
|
+
const patch = Object.fromEntries(Object.entries(texts).map(([name, text]) => [name, {
|
|
872
945
|
type: "secret_text",
|
|
873
946
|
text
|
|
874
947
|
}]));
|
|
875
|
-
return withSecretFile(JSON.stringify({ secrets: patch }), (path) => apply(() => runCf([
|
|
948
|
+
return withSecretFile(JSON.stringify({ secrets: patch }), (path) => apply(texts, () => runCf([
|
|
876
949
|
"workers",
|
|
877
950
|
"secrets",
|
|
878
951
|
"bulk",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as findEnvFile } from "../env-types-
|
|
1
|
+
import { t as findEnvFile } from "../env-types-WEZw5D-r.mjs";
|
|
2
2
|
import { writeSync } from "node:fs";
|
|
3
3
|
import { fileURLToPath } from "node:url";
|
|
4
4
|
import { spawnSync } from "node:child_process";
|
|
@@ -109,7 +109,7 @@ function emitResult(result) {
|
|
|
109
109
|
writeSync(RESULT_FD, JSON.stringify(result));
|
|
110
110
|
}
|
|
111
111
|
async function runFactsChild(root) {
|
|
112
|
-
const { deriveSelfHostSchemaFacts, SelfHostSchemaError } = await import("../env-validation-
|
|
112
|
+
const { deriveSelfHostSchemaFacts, SelfHostSchemaError } = await import("../env-validation-DKDcpxbt.mjs");
|
|
113
113
|
try {
|
|
114
114
|
emitResult({
|
|
115
115
|
kind: "ok",
|
|
@@ -128,7 +128,7 @@ async function runFactsChild(root) {
|
|
|
128
128
|
}
|
|
129
129
|
/** The parent already found the emitted config, so a read failure here fails closed. */
|
|
130
130
|
async function runValidateEmittedChild(root) {
|
|
131
|
-
const { computeInvalidEmittedKeys, readEmittedWorkerVars, SelfHostSchemaError } = await import("../env-validation-
|
|
131
|
+
const { computeInvalidEmittedKeys, readEmittedWorkerVars, SelfHostSchemaError } = await import("../env-validation-DKDcpxbt.mjs");
|
|
132
132
|
const emitted = readEmittedWorkerVars(root);
|
|
133
133
|
if (!emitted.ok) {
|
|
134
134
|
emitResult({
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { L as log } from "./dist-
|
|
1
|
+
import { L as log } from "./dist-STQXl8ck.mjs";
|
|
2
2
|
import { n as getOwnVersion } from "./agents-DRo8gzni.mjs";
|
|
3
3
|
import { t as formatCloudflareUserMessage } from "./cloudflare-user-output-zEwuGrEJ.mjs";
|
|
4
4
|
import { n as isD1Bookmark } from "./cf-command-values-Ccl-zRhl.mjs";
|
|
5
|
-
import { i as printVoidHeader, n as printGlobalHelp, r as printHelpPage, t as getHelpPath } from "./help-
|
|
6
|
-
import { n as operatorGroups } from "./operator-args-
|
|
5
|
+
import { i as printVoidHeader, n as printGlobalHelp, r as printHelpPage, t as getHelpPath } from "./help-Cgdcd-SG.mjs";
|
|
6
|
+
import { n as operatorGroups } from "./operator-args-BCCohcz3.mjs";
|
|
7
7
|
import { r as OperatorClientError } from "./operator-client-XvXTkea6.mjs";
|
|
8
|
-
import { f as import_picocolors, l as formatUrl } from "./output-
|
|
9
|
-
import { n as platformSubcommands, t as parsePlatformArgs } from "./platform-args-
|
|
8
|
+
import { f as import_picocolors, l as formatUrl } from "./output-DNVILSz2.mjs";
|
|
9
|
+
import { n as platformSubcommands, t as parsePlatformArgs } from "./platform-args-DtpHS_75.mjs";
|
|
10
10
|
import { parseArgs } from "node:util";
|
|
11
11
|
// src/cli/account-args.ts
|
|
12
12
|
const accountSubcommands = [
|
|
@@ -1605,7 +1605,7 @@ async function runSubcommandGroup(command, subcommands, parse, run) {
|
|
|
1605
1605
|
const hasNamedSubcommand = args.slice(1).some((arg) => subcommands.some(({ name }) => name === arg));
|
|
1606
1606
|
try {
|
|
1607
1607
|
if ((!sub || sub.startsWith("-") && !hasNamedSubcommand) && process.stdin.isTTY) {
|
|
1608
|
-
const { promptSubcommand } = await import("./subcommand-prompt-
|
|
1608
|
+
const { promptSubcommand } = await import("./subcommand-prompt-0yIARXf2.mjs");
|
|
1609
1609
|
if (command === "platform" && !sub) log.info(`A Void platform lets a team deploy Void apps to a shared Cloudflare account.
|
|
1610
1610
|
This command sets up and manages platforms. Join with \`void connect <url>\`.
|
|
1611
1611
|
Docs: ${formatUrl("https://void.cloud/guide/self-hosted-platform")}`);
|
|
@@ -1633,19 +1633,19 @@ const args = process.argv.slice(2);
|
|
|
1633
1633
|
const command = args[0];
|
|
1634
1634
|
const helpPath = getHelpPath(args);
|
|
1635
1635
|
const subcommandGroups = {
|
|
1636
|
-
auth: () => runSubcommandGroup("auth", authSubcommands, parseAuthArgs, (root, parsed) => import("./auth-router-
|
|
1637
|
-
account: () => runSubcommandGroup("account", accountSubcommands, parseAccountArgs, (root, parsed) => import("./account-cmd-
|
|
1638
|
-
platform: () => runSubcommandGroup("platform", platformSubcommands, parsePlatformArgs, (root, parsed) => import("./platform-cmd-
|
|
1639
|
-
cloudflare: () => runSubcommandGroup("cloudflare", cloudflareSubcommands, parseCloudflareArgs, (root, parsed) => import("./cloudflare-cmd-
|
|
1640
|
-
project: () => runSubcommandGroup("project", projectSubcommands, parseProjectArgs, (root, parsed) => import("./project-cmd-
|
|
1641
|
-
secret: () => runSubcommandGroup("secret", secretSubcommands, parseSecretArgs, (root, parsed) => import("./secret-
|
|
1642
|
-
domain: () => runSubcommandGroup("domain", domainSubcommands, parseDomainArgs, (root, parsed) => import("./domain-
|
|
1643
|
-
email: () => runSubcommandGroup("email", emailSubcommands, parseEmailArgs, (root, parsed) => import("./email-
|
|
1644
|
-
db: () => runSubcommandGroup("db", dbSubcommands, parseDbArgs, (root, parsed) => import("./db-
|
|
1645
|
-
env: () => runSubcommandGroup("env", envSubcommands, parseEnvArgs, (root, parsed) => import("./env-
|
|
1646
|
-
gen: () => runSubcommandGroup("gen", genSubcommands, parseGenArgs, (root, parsed) => import("./gen-
|
|
1647
|
-
github: () => runSubcommandGroup("github", githubSubcommands, parseGithubArgs, (root, parsed) => import("./github-cmd-
|
|
1648
|
-
build: () => runSubcommandGroup("build", buildSubcommands, parseBuildArgs, (root, parsed) => import("./build-cmd-
|
|
1636
|
+
auth: () => runSubcommandGroup("auth", authSubcommands, parseAuthArgs, (root, parsed) => import("./auth-router-DVaWJdRB.mjs").then(({ runAuthRouter }) => runAuthRouter(root, parsed))),
|
|
1637
|
+
account: () => runSubcommandGroup("account", accountSubcommands, parseAccountArgs, (root, parsed) => import("./account-cmd-BEMOdwtl.mjs").then(({ runAccountCommand }) => runAccountCommand(root, parsed))),
|
|
1638
|
+
platform: () => runSubcommandGroup("platform", platformSubcommands, parsePlatformArgs, (root, parsed) => import("./platform-cmd-BLy5uCa-.mjs").then(({ runPlatformCommand }) => runPlatformCommand(root, parsed))),
|
|
1639
|
+
cloudflare: () => runSubcommandGroup("cloudflare", cloudflareSubcommands, parseCloudflareArgs, (root, parsed) => import("./cloudflare-cmd-BuuHUM4z.mjs").then(({ runCloudflareCommand }) => runCloudflareCommand(root, parsed))),
|
|
1640
|
+
project: () => runSubcommandGroup("project", projectSubcommands, parseProjectArgs, (root, parsed) => import("./project-cmd-TQKAOTMV.mjs").then(({ runProjectCommand }) => runProjectCommand(root, parsed))),
|
|
1641
|
+
secret: () => runSubcommandGroup("secret", secretSubcommands, parseSecretArgs, (root, parsed) => import("./secret-BSf7dgg_.mjs").then(({ runSecretCommand }) => runSecretCommand(root, parsed))),
|
|
1642
|
+
domain: () => runSubcommandGroup("domain", domainSubcommands, parseDomainArgs, (root, parsed) => import("./domain-BTIdyUVk.mjs").then(({ runDomainCommand }) => runDomainCommand(root, parsed))),
|
|
1643
|
+
email: () => runSubcommandGroup("email", emailSubcommands, parseEmailArgs, (root, parsed) => import("./email-DvrS-I0U.mjs").then(({ runEmailCommand }) => runEmailCommand(root, parsed))),
|
|
1644
|
+
db: () => runSubcommandGroup("db", dbSubcommands, parseDbArgs, (root, parsed) => import("./db-DEpDeDsi.mjs").then(({ runDbCommand }) => runDbCommand(root, parsed))),
|
|
1645
|
+
env: () => runSubcommandGroup("env", envSubcommands, parseEnvArgs, (root, parsed) => import("./env-D7vORwpn.mjs").then(({ runEnvCommand }) => runEnvCommand(root, parsed))),
|
|
1646
|
+
gen: () => runSubcommandGroup("gen", genSubcommands, parseGenArgs, (root, parsed) => import("./gen-DmEeVEs4.mjs").then(({ runGenCommand }) => runGenCommand(root, parsed))),
|
|
1647
|
+
github: () => runSubcommandGroup("github", githubSubcommands, parseGithubArgs, (root, parsed) => import("./github-cmd-D-zs6VQr.mjs").then(({ runGithubCommand }) => runGithubCommand(root, parsed))),
|
|
1648
|
+
build: () => runSubcommandGroup("build", buildSubcommands, parseBuildArgs, (root, parsed) => import("./build-cmd-Dq8tdqQG.mjs").then(({ runBuildCommand }) => runBuildCommand(root, parsed)))
|
|
1649
1649
|
};
|
|
1650
1650
|
if (helpPath) {
|
|
1651
1651
|
if (helpPath.length === 0) printGlobalHelp();
|
|
@@ -1664,7 +1664,7 @@ if (helpPath) {
|
|
|
1664
1664
|
log.error(formatCloudflareUserMessage(err instanceof Error ? err.message : String(err)));
|
|
1665
1665
|
process.exit(1);
|
|
1666
1666
|
}
|
|
1667
|
-
import("./deploy-
|
|
1667
|
+
import("./deploy-Dr_Qamzw.mjs").then(({ runDeploy }) => {
|
|
1668
1668
|
runDeploy(root, deployArgs).catch((err) => {
|
|
1669
1669
|
log.error(formatCloudflareUserMessage(err.message ?? String(err)));
|
|
1670
1670
|
process.exit(1);
|
|
@@ -1672,14 +1672,14 @@ if (helpPath) {
|
|
|
1672
1672
|
});
|
|
1673
1673
|
} else if (command === "connect") (async () => {
|
|
1674
1674
|
const parsed = parseConnectArgs(args.slice(1));
|
|
1675
|
-
const { runConnectCommand } = await import("./connect-
|
|
1675
|
+
const { runConnectCommand } = await import("./connect-4uImOwut.mjs");
|
|
1676
1676
|
await runConnectCommand(process.cwd(), parsed);
|
|
1677
1677
|
})().catch((err) => {
|
|
1678
1678
|
log.error(formatCloudflareUserMessage(err instanceof Error ? err.message : String(err)));
|
|
1679
1679
|
process.exit(1);
|
|
1680
1680
|
});
|
|
1681
1681
|
else if (command && Object.hasOwn(subcommandGroups, command)) subcommandGroups[command]();
|
|
1682
|
-
else if (command === "info") import("./info-
|
|
1682
|
+
else if (command === "info") import("./info-BbxQ34kk.mjs").then(async ({ runInfoCommand }) => {
|
|
1683
1683
|
try {
|
|
1684
1684
|
await runInfoCommand(process.cwd(), parseInfoArgs(args.slice(1)));
|
|
1685
1685
|
} catch (err) {
|
|
@@ -1700,7 +1700,7 @@ else if (command === "prepare") {
|
|
|
1700
1700
|
log.error(formatCloudflareUserMessage(err instanceof Error ? err.message : String(err)));
|
|
1701
1701
|
process.exit(1);
|
|
1702
1702
|
}
|
|
1703
|
-
import("./prepare-
|
|
1703
|
+
import("./prepare-DMk8NAO-.mjs").then(({ runPrepareCommand }) => {
|
|
1704
1704
|
runPrepareCommand(root).catch((err) => {
|
|
1705
1705
|
log.error(formatCloudflareUserMessage(err.message ?? String(err)));
|
|
1706
1706
|
process.exit(1);
|
|
@@ -1708,7 +1708,7 @@ else if (command === "prepare") {
|
|
|
1708
1708
|
});
|
|
1709
1709
|
} else if (command === "init") {
|
|
1710
1710
|
const root = process.cwd();
|
|
1711
|
-
import("./init-
|
|
1711
|
+
import("./init-zyRj3QRw.mjs").then(({ runInitCommand, parseInitArgs }) => {
|
|
1712
1712
|
let initArgs;
|
|
1713
1713
|
try {
|
|
1714
1714
|
initArgs = parseInitArgs(args.slice(1));
|
|
@@ -1726,7 +1726,7 @@ else if (command === "prepare") {
|
|
|
1726
1726
|
log.error("migrate: This command takes no arguments.");
|
|
1727
1727
|
process.exit(1);
|
|
1728
1728
|
}
|
|
1729
|
-
import("./migrate-
|
|
1729
|
+
import("./migrate-BYhoIK9R.mjs").then(({ runMigrateCommand }) => {
|
|
1730
1730
|
runMigrateCommand(process.cwd()).catch((err) => {
|
|
1731
1731
|
log.error(formatCloudflareUserMessage(err instanceof Error ? err.message : String(err)));
|
|
1732
1732
|
process.exit(1);
|
|
@@ -1840,7 +1840,7 @@ else if (command) {
|
|
|
1840
1840
|
];
|
|
1841
1841
|
(async () => {
|
|
1842
1842
|
printVoidHeader();
|
|
1843
|
-
const { promptSubcommand } = await import("./subcommand-prompt-
|
|
1843
|
+
const { promptSubcommand } = await import("./subcommand-prompt-0yIARXf2.mjs");
|
|
1844
1844
|
const result = await promptSubcommand("", topLevelCommands);
|
|
1845
1845
|
if (!result) process.exit(0);
|
|
1846
1846
|
const cmd = result.subcommand;
|
|
@@ -1848,32 +1848,32 @@ else if (command) {
|
|
|
1848
1848
|
if (Object.hasOwn(subcommandGroups, cmd)) return subcommandGroups[cmd]();
|
|
1849
1849
|
switch (cmd) {
|
|
1850
1850
|
case "connect": {
|
|
1851
|
-
const { runConnectCommand } = await import("./connect-
|
|
1851
|
+
const { runConnectCommand } = await import("./connect-4uImOwut.mjs");
|
|
1852
1852
|
await runConnectCommand(root, parseConnectArgs([]));
|
|
1853
1853
|
return;
|
|
1854
1854
|
}
|
|
1855
1855
|
case "init": {
|
|
1856
|
-
const { runInitCommand, parseInitArgs } = await import("./init-
|
|
1856
|
+
const { runInitCommand, parseInitArgs } = await import("./init-zyRj3QRw.mjs");
|
|
1857
1857
|
await runInitCommand(root, parseInitArgs([]));
|
|
1858
1858
|
return;
|
|
1859
1859
|
}
|
|
1860
1860
|
case "migrate": {
|
|
1861
|
-
const { runMigrateCommand } = await import("./migrate-
|
|
1861
|
+
const { runMigrateCommand } = await import("./migrate-BYhoIK9R.mjs");
|
|
1862
1862
|
await runMigrateCommand(root);
|
|
1863
1863
|
return;
|
|
1864
1864
|
}
|
|
1865
1865
|
case "deploy": {
|
|
1866
|
-
const { runDeploy } = await import("./deploy-
|
|
1866
|
+
const { runDeploy } = await import("./deploy-Dr_Qamzw.mjs");
|
|
1867
1867
|
await runDeploy(root);
|
|
1868
1868
|
return;
|
|
1869
1869
|
}
|
|
1870
1870
|
case "info": {
|
|
1871
|
-
const { runInfoCommand } = await import("./info-
|
|
1871
|
+
const { runInfoCommand } = await import("./info-BbxQ34kk.mjs");
|
|
1872
1872
|
await runInfoCommand(root, parseInfoArgs([]));
|
|
1873
1873
|
return;
|
|
1874
1874
|
}
|
|
1875
1875
|
case "prepare": {
|
|
1876
|
-
const { runPrepareCommand } = await import("./prepare-
|
|
1876
|
+
const { runPrepareCommand } = await import("./prepare-DMk8NAO-.mjs");
|
|
1877
1877
|
await runPrepareCommand(root);
|
|
1878
1878
|
return;
|
|
1879
1879
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { r as PlatformClient, s as isOlderPlatformVersion } from "./client-D6w5x7hM.mjs";
|