cf 1.0.0-beta.16 → 1.0.0-beta.17
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/{abuse-reports-17K-TRhO.mjs → abuse-reports-C4LxDvUM.mjs} +1 -1
- package/dist/{access-BwB7sg1D.mjs → access-DnWW2AAT.mjs} +1 -1
- package/dist/{account-tags-povXTDAu.mjs → account-tags-zvHRQZxb.mjs} +1 -1
- package/dist/{accounts-BnIGu_ac.mjs → accounts-8UcHNm3S.mjs} +1 -1
- package/dist/{acm-CQRcu_zw.mjs → acm-qRM3iy4Z.mjs} +1 -1
- package/dist/{addressing-Qcm9jd3C.mjs → addressing-CAb8z2Dq.mjs} +1 -1
- package/dist/{agent-memory-B3xN9I6-.mjs → agent-memory-oIUP4ZV5.mjs} +1 -1
- package/dist/{ai-BRKOCckA.mjs → ai-DnhytGdc.mjs} +1 -1
- package/dist/{ai-audit-Cd9Rc2Fc.mjs → ai-audit-B7_5EOcN.mjs} +1 -1
- package/dist/{ai-gateway-BWU5064V.mjs → ai-gateway-b3FFu6UV.mjs} +1 -1
- package/dist/{ai-search-CJ3b8eot.mjs → ai-search-CtfW5fzl.mjs} +5 -5
- package/dist/{ai-security-Dn0Ee6QS.mjs → ai-security-KUs94UW-.mjs} +1 -1
- package/dist/{alerting-BXTiMfXo.mjs → alerting-CCmyEPzN.mjs} +1 -1
- package/dist/{analytics-Jyd04TRW.mjs → analytics-BAvBj6qx.mjs} +1 -1
- package/dist/{analytics-engine-CzrNfUeh.mjs → analytics-engine-DAJp89gM.mjs} +1 -1
- package/dist/{api-security-DRBHZaf_.mjs → api-security-BItVQymb.mjs} +1 -1
- package/dist/{argo-DiQt0pSb.mjs → argo-DsJCvfml.mjs} +1 -1
- package/dist/{artifacts-eBZ4YN53.mjs → artifacts-DzHXeah6.mjs} +1 -1
- package/dist/{audit-logs-Bb4HTZay.mjs → audit-logs-D9XxsVZm.mjs} +1 -1
- package/dist/{auth-C6My1gI6.mjs → auth-C530fHKQ.mjs} +1 -1
- package/dist/auth-Ccm5viK_.mjs +2 -0
- package/dist/{auth-eVI_UEt8.mjs → auth-MNz2D-PD.mjs} +1 -1
- package/dist/{auth-token-Cfj2yehs.mjs → auth-token-Cw4c0y89.mjs} +1 -1
- package/dist/{autoconfig-B0ESZ8DJ.mjs → autoconfig-9po_tqsS.mjs} +1 -1
- package/dist/{basin-catalog-Cwk1RSMX.mjs → basin-catalog-DcMiZV9J.mjs} +1 -1
- package/dist/{billing-CfV8oi6A.mjs → billing-COgAWTYh.mjs} +1 -1
- package/dist/{bot-management-CH4_Kewx.mjs → bot-management-Dx3lh9Fi.mjs} +1 -1
- package/dist/{botnet-feed-Cg_Wp8ei.mjs → botnet-feed-C8496Nhl.mjs} +1 -1
- package/dist/{brand-protection-Cp2ckWou.mjs → brand-protection-B0p8Sv6s.mjs} +1 -1
- package/dist/{browser-run-CfQ30dB6.mjs → browser-run-ChXohmNG.mjs} +1 -1
- package/dist/build-BRJnyeu8.mjs +2 -0
- package/dist/{build-sBpqm9ga.mjs → build-i8l2qGVZ.mjs} +1 -1
- package/dist/{builds-B2RBgVL9.mjs → builds-DmEFTQTa.mjs} +1 -1
- package/dist/{cache-yvrYPvRI.mjs → cache-BUh85NRr.mjs} +1 -1
- package/dist/{certificate-authorities-BdMRaOnD.mjs → certificate-authorities-BTLdA7EQ.mjs} +1 -1
- package/dist/chunk-JP6R7L72-C0kFUelb.mjs +2 -0
- package/dist/cli-DJhpXf38.mjs +6 -0
- package/dist/{client-certificates-CuWGvZSr.mjs → client-certificates-B3UxH_Au.mjs} +1 -1
- package/dist/{client-side-security-D50iZjd_.mjs → client-side-security-km3-4L_4.mjs} +1 -1
- package/dist/{cloud-connector-wvSGdxWT.mjs → cloud-connector-BoKFprDD.mjs} +1 -1
- package/dist/{cloudforce-one-j6vlmaMB.mjs → cloudforce-one-DN5N3C3w.mjs} +1 -1
- package/dist/{command-CM_f48gs.mjs → command-B694oLDo.mjs} +1 -1
- package/dist/{command-BSbhJRmu.mjs → command-Bmee6uwe.mjs} +1 -1
- package/dist/{command-DFRsim8q.mjs → command-CAs3SxlI.mjs} +1 -1
- package/dist/{command-BbO3sBQ2.mjs → command-CCq-Z2Ua.mjs} +1 -1
- package/dist/{command-Dr4PEvB2.mjs → command-CbQFbfps.mjs} +1 -1
- package/dist/{command-74P4_CTx.mjs → command-CiApsRql.mjs} +1 -1
- package/dist/{command-DiqRELHF.mjs → command-D1JR8Fb7.mjs} +1 -1
- package/dist/{command-DQojhTEQ.mjs → command-DerHAjQL.mjs} +1 -1
- package/dist/{command-BDpm-U8z.mjs → command-RC9WM5jq.mjs} +1 -1
- package/dist/{command-CmUtmu5j.mjs → command-rx0Kb5pn.mjs} +1 -1
- package/dist/{completions-oD1EcuHk.mjs → completions-11latun5.mjs} +1 -1
- package/dist/{connector-interrupts-DP4rbOe8.mjs → connector-interrupts-wvQcZsO1.mjs} +1 -1
- package/dist/{connector-telemetry-events-BQGBQwzR.mjs → connector-telemetry-events-C0GGCIQk.mjs} +1 -1
- package/dist/{connector-telemetry-snapshots-DBO0Mdcj.mjs → connector-telemetry-snapshots-ZXzsFgea.mjs} +1 -1
- package/dist/{connectors-BSVr3Kz1.mjs → connectors-DXIUG4Zi.mjs} +1 -1
- package/dist/{containers-BTqAeVV2.mjs → containers-DCH6MFjY.mjs} +2 -2
- package/dist/{containers-BOpKpipz.mjs → containers-WMWKhLkp.mjs} +1 -1
- package/dist/{content-scan-B9Keyxe-.mjs → content-scan-CRDmR7rD.mjs} +1 -1
- package/dist/{context-B-vEsyrK.mjs → context-q-6bMSL-.mjs} +1 -1
- package/dist/{cps-VRP794c5.mjs → cps-Due0P5IW.mjs} +1 -1
- package/dist/{csam-scanner-C1jOgXVu.mjs → csam-scanner-DvLrPw45.mjs} +1 -1
- package/dist/{ct-alerting-Y9vfa6Fo.mjs → ct-alerting-BtEGkRJi.mjs} +1 -1
- package/dist/{custom-certificates-CojTEC0E.mjs → custom-certificates-CMLXTTEc.mjs} +1 -1
- package/dist/{custom-csrs-DM5X-K6H.mjs → custom-csrs-BV017SqE.mjs} +1 -1
- package/dist/{custom-hostnames-BBjqaiFF.mjs → custom-hostnames-DI_dFaof.mjs} +1 -1
- package/dist/{custom-nameservers-C0NDMLPJ.mjs → custom-nameservers-BLoE8VGG.mjs} +1 -1
- package/dist/{custom-pages-M4RUxcn6.mjs → custom-pages-ubava9Qm.mjs} +1 -1
- package/dist/{d1-hin5PmxW.mjs → d1-Dbs8HItA.mjs} +1 -1
- package/dist/{dcv-delegation-KOO8syyQ.mjs → dcv-delegation-sGGt6UU_.mjs} +1 -1
- package/dist/{deploy-Bo7FtE44.mjs → deploy-5utIiOMN.mjs} +1 -1
- package/dist/{deploy-context-ClvBD87y.mjs → deploy-context-C0iVbWRG.mjs} +1 -1
- package/dist/{deploy-input-BqJ7GVZ-.mjs → deploy-input-KK6yyBN_.mjs} +1 -1
- package/dist/{dev-EtnMYA7K.mjs → dev-CnoMHxf4.mjs} +1 -1
- package/dist/{diagnostics-LZuMrGjK.mjs → diagnostics-C9B07eJY.mjs} +1 -1
- package/dist/{dls-Bq8k3iy-.mjs → dls-lbM3i4x-.mjs} +1 -1
- package/dist/{dns-ry5E2Bsa.mjs → dns-QTMPGYMa.mjs} +1 -1
- package/dist/{dns-firewall-zavP5Qxj.mjs → dns-firewall-Bfv0S44I.mjs} +1 -1
- package/dist/{docs-B08YtL0U.mjs → docs-bV3hPwQL.mjs} +1 -1
- package/dist/{durable-objects-B9fo41B1.mjs → durable-objects-0JvGTV27.mjs} +1 -1
- package/dist/{email-auth-D9LGjFlh.mjs → email-auth-PzRqG0ex.mjs} +1 -1
- package/dist/{email-routing-6iDnNPhY.mjs → email-routing-BgHL0Rbz.mjs} +1 -1
- package/dist/{email-security-ty4ufRnJ.mjs → email-security-CSTKIecn.mjs} +1 -1
- package/dist/{email-sending-d7LO_Cz_.mjs → email-sending-BSwuAir8.mjs} +1 -1
- package/dist/{field-extractors-DkgQ7PSw.mjs → field-extractors-B_lFnwaL.mjs} +1 -1
- package/dist/{firewall-Q88YyEwD.mjs → firewall-BsZxVitA.mjs} +1 -1
- package/dist/{flagship-CzI8zhd6.mjs → flagship-qBohOZaM.mjs} +1 -1
- package/dist/{fraud-CvFXTR0w.mjs → fraud-vGNdrSm-.mjs} +1 -1
- package/dist/{google-tag-gateway-Y2zbyey8.mjs → google-tag-gateway-BHdOg4VW.mjs} +1 -1
- package/dist/{healthchecks-4Hz-6xYi.mjs → healthchecks-DAYYLZ6u.mjs} +1 -1
- package/dist/{hostnames-B3k7fIUL.mjs → hostnames-CLlaMqHu.mjs} +1 -1
- package/dist/{hyperdrive-BWGYz95H.mjs → hyperdrive-CXTqaIqk.mjs} +1 -1
- package/dist/{iam-AXco_qmt.mjs → iam-Dl_n_Lqq.mjs} +1 -1
- package/dist/{images-BzYh8y0u.mjs → images-vMtXk2Rf.mjs} +1 -1
- package/dist/index.mjs +1 -1
- package/dist/{init-DlenHBtS.mjs → init-_7djeBVw.mjs} +1 -1
- package/dist/{intel-BBi3i_GU.mjs → intel-Bq4GGXv-.mjs} +1 -1
- package/dist/{ips-CWG2b7AM.mjs → ips-BcvZS46g.mjs} +1 -1
- package/dist/{k2-DXdMe3Cb.mjs → k2-DL4hrVTj.mjs} +1 -1
- package/dist/{keyless-certificates-B4ta_OGS.mjs → keyless-certificates-0pzjkZb6.mjs} +1 -1
- package/dist/{keys-B9zvFzrf.mjs → keys-BSV5IXdU.mjs} +1 -1
- package/dist/{kv-FUd7UdDu.mjs → kv-BLo9wMgb.mjs} +1 -1
- package/dist/{lazy-command-BC8rIlHu.mjs → lazy-command-CRcT6Dx-.mjs} +1 -1
- package/dist/{leaked-credential-checks-BufVA9vL.mjs → leaked-credential-checks-Dx4RXMyN.mjs} +1 -1
- package/dist/{load-balancers-CWd9mSWM.mjs → load-balancers-CCCWoQXv.mjs} +1 -1
- package/dist/{login-BJr2PBaJ.mjs → login-DT6Q1UJw.mjs} +1 -1
- package/dist/{login-DVbXZ_Tv.mjs → login-Du_W6b9o.mjs} +1 -1
- package/dist/{logo-matches-BluaPvMa.mjs → logo-matches-C-1J0Oc3.mjs} +1 -1
- package/dist/{logos-CXtmYWEJ.mjs → logos-BuhvSu_H.mjs} +1 -1
- package/dist/{logpush-DCYgrqz0.mjs → logpush-DgZtF9vG.mjs} +1 -1
- package/dist/{logs-as60IP29.mjs → logs-CaKOk-1v.mjs} +1 -1
- package/dist/{magic-cloud-networking-0RsHugUF.mjs → magic-cloud-networking-CKxXYT8r.mjs} +1 -1
- package/dist/{magic-network-monitoring-CPqvZdcb.mjs → magic-network-monitoring-BykFGQCz.mjs} +1 -1
- package/dist/{magic-transit-ClPyGzOE.mjs → magic-transit-DYULsrUP.mjs} +1 -1
- package/dist/{managed-defense-P4_QWSbK.mjs → managed-defense-DIb_uN25.mjs} +1 -1
- package/dist/{managed-transforms-CUwQXMij.mjs → managed-transforms-an3wQ0DW.mjs} +1 -1
- package/dist/{matches-BjckDBW1.mjs → matches-DkLSWb5X.mjs} +1 -1
- package/dist/{mcp-C2EG2c7L.mjs → mcp-BcV1XqE8.mjs} +1 -1
- package/dist/{mesh-CpMZA7Xt.mjs → mesh-CSSlZ-0F.mjs} +1 -1
- package/dist/{migrate-6e5mJ79R.mjs → migrate-DerOyuv2.mjs} +1 -1
- package/dist/{monetization-DypuCZmU.mjs → monetization-B-nJ0SyI.mjs} +1 -1
- package/dist/{mtls-certificates-B5AWTU6u.mjs → mtls-certificates-ukwDz6Lc.mjs} +1 -1
- package/dist/{network-DQ5Ridgy.mjs → network-ZzxQ_Dcz.mjs} +1 -1
- package/dist/{network-interconnects-ifU4JhGE.mjs → network-interconnects-CI9NXQpe.mjs} +1 -1
- package/dist/{o11y-CzssfRHt.mjs → o11y-LG6Y9LUZ.mjs} +1 -1
- package/dist/{oauth-BDdhqasa.mjs → oauth-Bx693Af5.mjs} +1 -1
- package/dist/{oauth-BNTiErBG.mjs → oauth-CP82E1_0.mjs} +1 -1
- package/dist/{oauth-clients-gknNcBdV.mjs → oauth-clients-BA30rTEl.mjs} +1 -1
- package/dist/{oauth-scopes-BJeSanuF.mjs → oauth-scopes-hseWES1v.mjs} +1 -1
- package/dist/open-PCXX3ZDZ-5J5IU2MX-CKla-jDt.mjs +4 -0
- package/dist/{organization-CXAM41sd.mjs → organization-DMr_z6n4.mjs} +1 -1
- package/dist/{organizations-kfFFW4uO.mjs → organizations-CcgZPmFl.mjs} +1 -1
- package/dist/{origin-ca-certificates-DwhYV3m_.mjs → origin-ca-certificates-BZxUbB5N.mjs} +1 -1
- package/dist/{origin-post-quantum-encryption-DfrnptJ1.mjs → origin-post-quantum-encryption-BhdlaolV.mjs} +1 -1
- package/dist/{origin-tls-client-auth-COSxTc2q.mjs → origin-tls-client-auth-DzbZvtmi.mjs} +1 -1
- package/dist/{page-rules-ByrDMDBZ.mjs → page-rules-DFfqfllI.mjs} +1 -1
- package/dist/{pages-DuGcBC6k.mjs → pages-BkcL5rC4.mjs} +1 -1
- package/dist/{pay-per-crawl-B3_Gn9Cj.mjs → pay-per-crawl-Dulm7Xy5.mjs} +1 -1
- package/dist/{pay-per-use-49EXt75f.mjs → pay-per-use-C_HxhpM4.mjs} +1 -1
- package/dist/{pipelines-Bvgh1BQZ.mjs → pipelines-DUMIVwof.mjs} +1 -1
- package/dist/{precursor-VobQf--m.mjs → precursor-DsGbA_YJ.mjs} +1 -1
- package/dist/{previews-DkwFHNRx.mjs → previews-Cma3-M7K.mjs} +1 -1
- package/dist/{progress-R-1tIuep.mjs → progress-DaQ4MzBI.mjs} +1 -1
- package/dist/{prompt-dgLm0iFJ.mjs → prompt-KWYZvJWM.mjs} +1 -1
- package/dist/{queries-EbIadtC5.mjs → queries-DoyhspQf.mjs} +1 -1
- package/dist/{queues-C4GZ-O3f.mjs → queues-BPxTU2rU.mjs} +1 -1
- package/dist/{r2-DEuFfWBR.mjs → r2-CQt4S7o7.mjs} +1 -1
- package/dist/{radar-CDOERVcR.mjs → radar-CALpR1vq.mjs} +1 -1
- package/dist/{raw-fetch-BapeoreV.mjs → raw-fetch-Cy09TjHc.mjs} +1 -1
- package/dist/{realtime-D_A9Qgly.mjs → realtime-BiHKBoI4.mjs} +1 -1
- package/dist/{registrar-X1YLlnmg.mjs → registrar-gERQ3b85.mjs} +1 -1
- package/dist/{registrar-sandbox-BF3cYO3n.mjs → registrar-sandbox-BttFwYqE.mjs} +1 -1
- package/dist/{reporting-BWm9jIF8.mjs → reporting-8aRJD5HX.mjs} +1 -1
- package/dist/{request-headers-BRxv6NkA.mjs → request-headers-CqfJOkpO.mjs} +1 -1
- package/dist/{request-tracers-CHWpiejG.mjs → request-tracers-DcnwQg3K.mjs} +1 -1
- package/dist/{resource-sharing-C186jZv0.mjs → resource-sharing-uVVpMW0w.mjs} +1 -1
- package/dist/{resource-tagging-BTagOZli.mjs → resource-tagging-SlsUtLsq.mjs} +1 -1
- package/dist/{rules-DYnGIU_0.mjs → rules-CFOuN3t2.mjs} +1 -1
- package/dist/{rulesets-BcNrbVcq.mjs → rulesets-DkhV2Hny.mjs} +1 -1
- package/dist/{rum-BDyRecfp.mjs → rum-BnMW0Tlb.mjs} +1 -1
- package/dist/run-CHNyLZLG.mjs +2 -0
- package/dist/{run-BvDCuZ8q.mjs → run-Clc3P2u7.mjs} +1 -1
- package/dist/{schema-flags-DcKjAxI1.mjs → schema-flags-b096XMpt.mjs} +1 -1
- package/dist/{scim-zn-CNCsc.mjs → scim-tvZm6A-r.mjs} +1 -1
- package/dist/{secrets-store-CFhyQUV6.mjs → secrets-store-DuNxSh1_.mjs} +1 -1
- package/dist/{security-insights-D8XgtCed.mjs → security-insights-C17c9ZYZ.mjs} +1 -1
- package/dist/{security-txt-CCM-Vro0.mjs → security-txt-D4pRk7-w.mjs} +1 -1
- package/dist/{shared-ouAF7o4S.mjs → shared-zePemxHi.mjs} +1 -1
- package/dist/{smart-shield-DwW7N92r.mjs → smart-shield-2egm1Vaw.mjs} +1 -1
- package/dist/{snippets-B2jBY0m_.mjs → snippets-BIcZ6vSW.mjs} +1 -1
- package/dist/{spawn-DQttFH05.mjs → spawn-BW2bJmKO.mjs} +1 -1
- package/dist/{spectrum-Cf_4cGE8.mjs → spectrum-DjDX0geK.mjs} +1 -1
- package/dist/{speed-DoXdyIYK.mjs → speed-DiPoFJMm.mjs} +1 -1
- package/dist/{sql-Bze4h80q.mjs → sql-DLjCt_R3.mjs} +1 -1
- package/dist/{src-BguQDHjS.mjs → src-CutrsNl4.mjs} +5 -5
- package/dist/{ssl-u_0gUhPA.mjs → ssl-vNzK0c9S.mjs} +1 -1
- package/dist/{stream-BcReYIHJ.mjs → stream-uhn_Zsni.mjs} +1 -1
- package/dist/{submit-ldFVNfNC.mjs → submit-C3suIDBX.mjs} +1 -1
- package/dist/{tags-D_Hc_A-r.mjs → tags-Dy2jG-Dt.mjs} +1 -1
- package/dist/telemetry-Bdv5LZZs.mjs +2 -0
- package/dist/{telemetry-Cojgz4Sv.mjs → telemetry-DYjsavEr.mjs} +1 -1
- package/dist/{tenant-AZ0EAsmT.mjs → tenant-DK88yQM4.mjs} +1 -1
- package/dist/{tenant-custom-nameservers-aozjaasc.mjs → tenant-custom-nameservers-BZ1JD1Yf.mjs} +1 -1
- package/dist/{tunnels-CXez5LPB.mjs → tunnels-DjbomhCa.mjs} +2 -2
- package/dist/{turnstile-B2NQ8Nsk.mjs → turnstile-DXrbEy2A.mjs} +1 -1
- package/dist/{update-check-BlyKN8m0.mjs → update-check-BhhtSXVZ.mjs} +1 -1
- package/dist/update-check-Dld7rbLd.mjs +2 -0
- package/dist/update-check-worker.mjs +1 -1
- package/dist/{url-info-D_UqGiWD.mjs → url-info-a0mY4UsC.mjs} +1 -1
- package/dist/{url-normalization-CF1YHpIN.mjs → url-normalization-DiwpDIhc.mjs} +1 -1
- package/dist/{url-scanner-ChF3GO2U.mjs → url-scanner-D0egjBe5.mjs} +1 -1
- package/dist/{user-BfWRsdJh.mjs → user-DDH9lxf5.mjs} +1 -1
- package/dist/{values-CLfxkAUJ.mjs → values-Bfr5-bL6.mjs} +1 -1
- package/dist/{vectorize-CRYbWKg5.mjs → vectorize-DaT3amFV.mjs} +1 -1
- package/dist/version-CAuKDZAG.mjs +2 -0
- package/dist/{waiting-rooms-Crp7MVd9.mjs → waiting-rooms-BGMpu9gS.mjs} +1 -1
- package/dist/{web-assets-CgyrPnT-.mjs → web-assets-NqNglLSI.mjs} +1 -1
- package/dist/{web3-Cd0Yd0eQ.mjs → web3-UnCUuIfB.mjs} +1 -1
- package/dist/{workers-CTwJpTfJ.mjs → workers-DfA9ugmb.mjs} +2 -2
- package/dist/{workers-builds-f2nVw7EZ.mjs → workers-builds-Cy6fdtm5.mjs} +1 -1
- package/dist/{workers-for-platforms-DjeKp2uy.mjs → workers-for-platforms-JscCHivQ.mjs} +1 -1
- package/dist/{workers-vpc-B_L3TEg2.mjs → workers-vpc-FDZQBqOu.mjs} +1 -1
- package/dist/{workflows-CBPGf65x.mjs → workflows-Dq-k81hU.mjs} +1 -1
- package/dist/wrangler-migration-R9TQ_4Qd.mjs +946 -0
- package/dist/{zaraz-3VDxl0gF.mjs → zaraz-Dpr1pLDx.mjs} +1 -1
- package/dist/{zero-trust-B9xY8zcn.mjs → zero-trust-CZ685QhO.mjs} +1 -1
- package/dist/{zone-CmwVqTI2.mjs → zone-DcZIUTWt.mjs} +1 -1
- package/dist/{zones-Bf0VVpMf.mjs → zones-BVdvYUCv.mjs} +1 -1
- package/package.json +10 -10
- package/dist/auth-OFqV2M4q.mjs +0 -2
- package/dist/build-Bm6kGyzo.mjs +0 -2
- package/dist/cli-CsnoQloF.mjs +0 -6
- package/dist/run-roYb_Odh.mjs +0 -2
- package/dist/telemetry-Ct_2AaO4.mjs +0 -2
- package/dist/update-check-BnGDxswi.mjs +0 -2
- package/dist/version-CVlh2Zaq.mjs +0 -2
- package/dist/wrangler-migration-DxTB5yPT.mjs +0 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-MNz2D-PD.mjs";import{i as r}from"./context-q-6bMSL-.mjs";import{t as i}from"./output-Co4xdFf6.mjs";import{t as a}from"./dry-run-C2KjGX10.mjs";import{t as o}from"./progress-DaQ4MzBI.mjs";import{t as s}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";import{n as c,t as l}from"./body-parser-DkHKPkJ7.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{a as d,i as f,n as p}from"./prompt-KWYZvJWM.mjs";var m={method:`POST`,path:t=>e`/zones/${t.zone_id}/environments/${t.environment_id}/invalidate_cache`,body:`json`};function h(e){return e.usage("$0 cache invalidate-environment <environment-id>\n\nMarks cached content as stale for one environment of the zone. Content cached for the zone's other environments, including production, is not affected. Otherwise this works like `POST /zones/{zone_id}/invalidate_cache`: the next request for invalidated content makes Cloudflare revalidate it with your origin, and the request body takes the same fields. Environments are part of [Version Management](https://developers.cloudflare.com/version-management/). To delete the content instead, use `POST /zones/{zone_id}/environments/{environment_id}/purge_cache`. Invalidating by URL (`files`) does not work for environments that select requests by IP address, country, ASN, or threat score, and fails with error `1136`. Use `tags`, `hosts`, `prefixes`, or `purge_everything` for those environments. ### Availability and limits Rate limits and the number of items you can send in one request depend on your plan. See [Purge cache: availability and limits](https://developers.cloudflare.com/cache/how-to/purge-cache/#availability-and-limits).").positional(`environment-id`,{type:`string`,description:`The environment ID, from Version Management.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const g={command:`invalidate-environment <environment-id>`,describe:`Invalidate Cached Content by Environment`,builder:h,handler:async e=>s({command:`cache invalidate-environment`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf cache invalidate-environment`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/environments/${e[`environment-id`]==null?`<environment-id>`:encodeURIComponent(String(e[`environment-id`]))}/invalidate_cache`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),"environment-id":String(e[`environment-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:c(e.body)});return}let s=await n(e),l=await r({zone:e.zone},s,{quiet:e.quiet});if(e.zoneId=l,!await p({force:!!e.force,message:`This operation marks the selected content in the environment's cache as stale.`})){process.stderr.write(`Aborted.
|
|
3
3
|
`);return}if(e.body){let t=c(e.body),n=await o(`Deleting`,async()=>s.send(m,{body:t,zone_id:l,environment_id:e[`environment-id`]}));i(n,{successLabel:`Deleted`});return}let u=await o(`Deleting`,async()=>t(s,`POST`,`/zones/${e.zoneId}/environments/${encodeURIComponent(String(e[`environment-id`]))}/invalidate_cache`));i(u,{successLabel:`Deleted`})})};var ee={method:`POST`,path:t=>e`/zones/${t.zone_id}/invalidate_cache`,body:`json`};function te(e){return e.usage("$0 cache invalidate\n\nMarks cached content as stale in every Cloudflare data center and cache tier, including Cache Reserve. The content stays in cache. The next request for it makes Cloudflare revalidate it with your origin, using the `ETag` and `Last-Modified` values it was cached with: - If your origin answers `304 Not Modified`, Cloudflare serves the cached copy without downloading it again, and `CF-Cache-Status` is `REVALIDATED`. - If your origin sends a full response, Cloudflare serves and caches the new content, and `CF-Cache-Status` is `EXPIRED`. With Tiered Cache, each tier revalidates with the tier above it, so a visitor can see `EXPIRED` even when your origin answered `304`. Until content is revalidated, your `stale-while-revalidate` and `stale-if-error` directives still apply, counted from the time you invalidated it. For example, if your origin fails during revalidation, Cloudflare can keep serving the stale copy for the `stale-if-error` window. ### Invalidate or purge? - **Invalidate** when content may not have changed, for example after a deploy. Unchanged content costs your origin a `304` instead of a full response. That saving needs an origin that sends `ETag` or `Last-Modified` and answers conditional requests. Otherwise, every revalidation downloads the full response. - **Purge**, with `POST /zones/{zone_id}/purge_cache`, when content must not be served again, for example content you removed for legal or security reasons. Invalidating takes the same request bodies as purging, needs the same permission, and counts against the same rate limits. After a broad invalidation, such as `purge_everything`, expect more conditional requests to your origin while visitors request the invalidated content again. ### Choose what to invalidate Send one of these fields in the request body: - `files`: specific URLs. If your cache key includes request headers, send each URL with the header values it was cached with. - `tags`: all content whose `Cache-Tag` response header contains one of the tags. - `hosts`: all content cached for the hostnames. - `prefixes`: all content whose URL starts with one of the prefixes. - `purge_everything`: all cached content in the zone. ### Check the result A `200` response with `success: true` means Cloudflare accepted the request. To check, request an invalidated URL and confirm that the `CF-Cache-Status` response header is `REVALIDATED` or `EXPIRED`. ### Availability and limits Rate limits and the number of items you can send in one request depend on your plan. See [Purge cache: availability and limits](https://developers.cloudflare.com/cache/how-to/purge-cache/#availability-and-limits).").option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const ne={command:`invalidate`,describe:`Invalidate Cached Content`,builder:te,handler:async e=>s({command:`cache invalidate`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf cache invalidate`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/invalidate_cache`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:c(e.body)});return}let s=await n(e),l=await r({zone:e.zone},s,{quiet:e.quiet});if(e.zoneId=l,!await p({force:!!e.force,message:`This operation marks the selected content in the zone's cache as stale.`})){process.stderr.write(`Aborted.
|
|
4
4
|
`);return}if(e.body){let t=c(e.body),n=await o(`Deleting`,async()=>s.send(ee,{body:t,zone_id:l}));i(n,{successLabel:`Deleted`});return}let u=await o(`Deleting`,async()=>t(s,`POST`,`/zones/${e.zoneId}/invalidate_cache`));i(u,{successLabel:`Deleted`})})};function re(e){return e.usage("$0 cache origin-cloud-regions bulk-delete\n\nRemoves up to 100 IP-to-cloud-region mappings in a single request. Each IP is validated independently — successfully deleted items are returned in the `succeeded` array and IPs that could not be found or are invalid are returned in the `failed` array.").option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const ie={command:`bulk-delete`,describe:`Batch delete origin cloud region mappings`,builder:re,handler:async e=>s({command:`cache origin-cloud-regions bulk-delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf cache origin-cloud-regions bulk-delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/origin/cloud_regions/batch`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:c(e.body)});return}let s=await n(e);if(e.zoneId=await r({zone:e.zone},s,{quiet:e.quiet}),!await p({force:!!e.force,message:`Are you sure you want to delete these Origin Cloud Region configurations?`})){process.stderr.write(`Aborted.
|
|
5
5
|
`);return}if(e.body){let n=c(e.body);if(Array.isArray(n)&&n.length>100){let r=Math.ceil(n.length/100),a=null;for(let i=0;i<n.length;i+=100){let c=n.slice(i,i+100),l=Math.floor(i/100)+1;a=await o(`Deleting: batch ${l}/${r}`,async()=>t(s,`DELETE`,`/zones/${e.zoneId}/origin/cloud_regions/batch`,{body:c}))}i(a,{successLabel:`Deleted`});return}let r=await o(`Deleting`,async()=>t(s,`DELETE`,`/zones/${e.zoneId}/origin/cloud_regions/batch`,{body:n}));i(r,{successLabel:`Deleted`});return}if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};function ae(e){return e.usage("$0 cache origin-cloud-regions bulk-update\n\nUpserts up to 100 IP-to-cloud-region mappings in a single request. Items in the request body are created or replaced; mappings not included in the request body are preserved unchanged (this is a merge operation, not a full collection replacement). Each item is validated independently — valid items are applied and invalid items are returned in the `failed` array. The vendor and region for every item are validated against the list from `GET /zones/{zone_id}/origin/cloud_regions/supported_regions`.").option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const _={command:`bulk-update`,describe:`Batch create or replace origin cloud region mappings`,builder:ae,handler:async e=>s({command:`cache origin-cloud-regions bulk-update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf cache origin-cloud-regions bulk-update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/origin/cloud_regions/batch`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:c(e.body)});return}let s=await n(e);if(e.zoneId=await r({zone:e.zone},s,{quiet:e.quiet}),e.body){let n=c(e.body);if(Array.isArray(n)&&n.length>100){let r=Math.ceil(n.length/100),a=null;for(let i=0;i<n.length;i+=100){let c=n.slice(i,i+100),l=Math.floor(i/100)+1;a=await o(`Updating: batch ${l}/${r}`,async()=>t(s,`PUT`,`/zones/${e.zoneId}/origin/cloud_regions/batch`,{body:c}))}i(a,{successLabel:`Updated`});return}let r=await o(`Updating`,async()=>t(s,`PUT`,`/zones/${e.zoneId}/origin/cloud_regions/batch`,{body:n}));i(r,{successLabel:`Updated`});return}if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var v={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/origin/cloud_regions/${t.origin_ip}`};function y(e){return e.usage(`$0 cache origin-cloud-regions delete <origin-ip>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-MNz2D-PD.mjs";import{i as n}from"./context-q-6bMSL-.mjs";import{t as r}from"./output-Co4xdFf6.mjs";import{t as i}from"./dry-run-C2KjGX10.mjs";import{t as a}from"./progress-DaQ4MzBI.mjs";import{t as o}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";import{n as s,t as c}from"./body-parser-DkHKPkJ7.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";var u={method:`GET`,path:t=>e`/zones/${t.zone_id}/certificate_authorities/hostname_associations`,query:[`mtls_certificate_id`]};function d(e){return e.usage(`$0 certificate-authorities hostname-associations get
|
|
3
3
|
|
|
4
4
|
List Hostname Associations.`).option(`mtls-certificate-id`,{type:`string`,description:`The UUID to match against for a certificate that was uploaded to the mTLS Certificate Management endpoint. If no mtls_certificate_id is given, the results will be the hostnames associated to your active Cloudflare Managed CA.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const f={command:`get`,describe:`List Hostname Associations`,builder:d,handler:async e=>o({command:`certificate-authorities hostname-associations get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let o={mtls_certificate_id:e[`mtls-certificate-id`]};if(e.dryRun){i({command:`cf certificate-authorities hostname-associations get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/certificate_authorities/hostname_associations`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},query:o,bodyKind:`none`});return}let s=await t(e),c=await n({zone:e.zone},s,{quiet:e.quiet});e.zoneId=c;let l=await a(`Loading`,async()=>s.send(u,{zone_id:c,...o}));r(l,{successLabel:`Loaded`})})};var p={method:`PUT`,path:t=>e`/zones/${t.zone_id}/certificate_authorities/hostname_associations`,body:`json`};function m(e){return e.usage(`$0 certificate-authorities hostname-associations update
|
|
5
5
|
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{createRequire as e}from"node:module";const t=e(import.meta.url||(typeof __filename==`string`?__filename:`/`));var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,c=(e,t)=>r(e,`name`,{value:t,configurable:!0}),l=/* @__PURE__ */ (e=>t===void 0?typeof Proxy<`u`?new Proxy(e,{get:(e,n)=>(t===void 0?e:t)[n]}):e:t)(function(e){if(t!==void 0)return t.apply(this,arguments);throw Error(`Dynamic require of "`+e+`" is not supported`)}),u=(e,t)=>function(){return e&&(t=(0,e[a(e)[0]])(e=0)),t},d=(e,t)=>function(){return t||(0,e[a(e)[0]])((t={exports:{}}).exports,t),t.exports},f=(e,t)=>{for(var n in t)r(e,n,{get:t[n],enumerable:!0})},p=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of a(t))!s.call(e,c)&&c!==n&&r(e,c,{get:()=>t[c],enumerable:!(o=i(t,c))||o.enumerable});return e},m=(e,t,i)=>(i=e==null?{}:n(o(e)),p(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),h=e=>p(r({},`__esModule`,{value:!0}),e),g=e(import.meta.url||(typeof __filename==`string`?__filename:`/`)),_=Object.create,v=Object.defineProperty,y=Object.getOwnPropertyDescriptor,b=Object.getOwnPropertyNames,x=Object.getPrototypeOf,S=Object.prototype.hasOwnProperty,C=/* @__PURE__ */ c((e,t)=>v(e,`name`,{value:t,configurable:!0}),`__name`),w=/* @__PURE__ */ (e=>g===void 0?typeof Proxy<`u`?new Proxy(e,{get:/* @__PURE__ */ c((e,t)=>(g===void 0?e:g)[t],`get`)}):e:g)(function(e){if(g!==void 0)return g.apply(this,arguments);throw Error(`Dynamic require of "`+e+`" is not supported`)}),T=/* @__PURE__ */ c((e,t)=>/* @__PURE__ */ c(function(){return t||(0,e[b(e)[0]])((t={exports:{}}).exports,t),t.exports},`__require2`),`__commonJS`),E=/* @__PURE__ */ c((e,t)=>{for(var n in t)v(e,n,{get:t[n],enumerable:!0})},`__export`),D=/* @__PURE__ */ c((e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let i of b(t))!S.call(e,i)&&i!==n&&v(e,i,{get:/* @__PURE__ */ c(()=>t[i],`get`),enumerable:!(r=y(t,i))||r.enumerable});return e},`__copyProps`),O=/* @__PURE__ */ c((e,t,n)=>(n=e==null?{}:_(x(e)),D(t||!e||!e.__esModule?v(n,`default`,{value:e,enumerable:!0}):n,e)),`__toESM`);export{E as a,l as c,m as d,O as f,f as i,w as l,T as n,c as o,u as r,C as s,d as t,h as u};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{n as e,t}from"./metadata-Df5kCWJv.mjs";import{r as n}from"./theme-BGHWSKCw.mjs";import{t as r}from"./cli-exit-CstFZ1eJ.mjs";import"./ui-BtIBQeaG.mjs";import{t as i}from"./output-Co4xdFf6.mjs";import{a,f as o,m as s,t as c,u as l}from"./run-Clc3P2u7.mjs";function u({enabled:e,source:t}){let r=e?n.success(`Enabled`):n.error(`Disabled`),i=l(t);return`Status: ${r}${i?` (set by ${i})`:``}\n`}const d={command:`disable`,describe:`Disable cf telemetry collection`,handler:()=>{s(!1);let{enabled:e,source:t}=o();console.log(u({enabled:e,source:t})),console.log(e?`cf is collecting usage telemetry because ${l(t)}=true overrides this setting.\n`:`cf is no longer collecting usage telemetry.
|
|
3
|
+
`)}},f={command:`enable`,describe:`Enable cf telemetry collection`,handler:()=>{s(!0);let{enabled:e,source:t}=o();console.log(u({enabled:e,source:t})),console.log(e?`cf is now collecting anonymous usage telemetry. Thank you for helping make cf better.
|
|
4
|
+
`:`cf is not collecting usage telemetry because ${l(t)}${t===`env`||t===`wrangler-env`?`=false`:``} overrides this setting.\n`)}},p={command:`status`,describe:`Check whether cf telemetry collection is enabled`,handler:()=>{console.log(u(o())),console.log(n.muted(`Configure on this machine: \`cf cli telemetry enable\` / \`cf cli telemetry disable\`.
|
|
5
|
+
Override per invocation with ${a}=true/false. DO_NOT_TRACK is also honored.\nLearn more: https://github.com/cloudflare/cf/blob/main/packages/cli/telemetry.md`))}},m={command:`telemetry`,describe:`Configure whether cf collects anonymous usage telemetry`,builder:e=>e.command(p).command(f).command(d).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},h=`KEYS`,g=`VALUES`;var _=class{constructor(e,t){let n=e._tree,r=Array.from(n.keys());this.set=e,this._type=t,this._path=r.length>0?[{node:n,keys:r}]:[]}next(){let e=this.dive();return this.backtrack(),e}dive(){if(this._path.length===0)return{done:!0,value:void 0};let{node:e,keys:t}=v(this._path);if(v(t)===``)return{done:!1,value:this.result()};let n=e.get(v(t));return this._path.push({node:n,keys:Array.from(n.keys())}),this.dive()}backtrack(){if(this._path.length===0)return;let e=v(this._path).keys;e.pop(),!(e.length>0)&&(this._path.pop(),this.backtrack())}key(){return this.set._prefix+this._path.map(({keys:e})=>v(e)).filter(e=>e!==``).join(``)}value(){return v(this._path).node.get(``)}result(){switch(this._type){case g:return this.value();case h:return this.key();default:return[this.key(),this.value()]}}[Symbol.iterator](){return this}};const v=e=>e[e.length-1],y=(e,t,n)=>{let r=/* @__PURE__ */ new Map;if(t===void 0)return r;let i=t.length+1,a=i+n,o=new Uint8Array(a*i).fill(n+1);for(let e=0;e<i;++e)o[e]=e;for(let e=1;e<a;++e)o[e*i]=e;return b(e,t,n,r,o,1,i,``),r},b=(e,t,n,r,i,a,o,s)=>{let c=a*o;key:for(let l of e.keys())if(l===``){let t=i[c-1];t<=n&&r.set(s,[e.get(l),t])}else{let c=a;for(let e=0;e<l.length;++e,++c){let r=l[e],a=o*c,s=a-o,u=i[a],d=Math.max(0,c-n-1),f=Math.min(o-1,c+n);for(let e=d;e<f;++e){let n=r!==t[e],o=i[s+e]+ +n,c=i[s+e+1]+1,l=i[a+e]+1,d=i[a+e+1]=Math.min(o,c,l);d<u&&(u=d)}if(u>n)continue key}b(e.get(l),t,n,r,i,c,o,s+l)}};var x=class e{constructor(e=/* @__PURE__ */ new Map,t=``){this._size=void 0,this._tree=e,this._prefix=t}atPrefix(t){if(!t.startsWith(this._prefix))throw Error(`Mismatched prefix`);let[n,r]=S(this._tree,t.slice(this._prefix.length));if(n===void 0){let[n,i]=O(r);for(let r of n.keys())if(r!==``&&r.startsWith(i)){let a=/* @__PURE__ */ new Map;return a.set(r.slice(i.length),n.get(r)),new e(a,t)}}return new e(n,t)}clear(){this._size=void 0,this._tree.clear()}delete(e){return this._size=void 0,T(this._tree,e)}entries(){return new _(this,`ENTRIES`)}forEach(e){for(let[t,n]of this)e(t,n,this)}fuzzyGet(e,t){return y(this._tree,e,t)}get(e){let t=C(this._tree,e);return t===void 0?void 0:t.get(``)}has(e){let t=C(this._tree,e);return t!==void 0&&t.has(``)}keys(){return new _(this,h)}set(e,t){if(typeof e!=`string`)throw Error(`key must be a string`);return this._size=void 0,w(this._tree,e).set(``,t),this}get size(){if(this._size)return this._size;this._size=0;let e=this.entries();for(;!e.next().done;)this._size+=1;return this._size}update(e,t){if(typeof e!=`string`)throw Error(`key must be a string`);this._size=void 0;let n=w(this._tree,e);return n.set(``,t(n.get(``))),this}fetch(e,t){if(typeof e!=`string`)throw Error(`key must be a string`);this._size=void 0;let n=w(this._tree,e),r=n.get(``);return r===void 0&&n.set(``,r=t()),r}values(){return new _(this,g)}[Symbol.iterator](){return this.entries()}static from(t){let n=new e;for(let[e,r]of t)n.set(e,r);return n}static fromObject(t){return e.from(Object.entries(t))}};const S=(e,t,n=[])=>{if(t.length===0||e==null)return[e,n];for(let r of e.keys())if(r!==``&&t.startsWith(r))return n.push([e,r]),S(e.get(r),t.slice(r.length),n);return n.push([e,t]),S(void 0,``,n)},C=(e,t)=>{if(t.length===0||e==null)return e;for(let n of e.keys())if(n!==``&&t.startsWith(n))return C(e.get(n),t.slice(n.length))},w=(e,t)=>{let n=t.length;outer:for(let r=0;e&&r<n;){for(let i of e.keys())if(i!==``&&t[r]===i[0]){let a=Math.min(n-r,i.length),o=1;for(;o<a&&t[r+o]===i[o];)++o;let s=e.get(i);if(o===i.length)e=s;else{let n=/* @__PURE__ */ new Map;n.set(i.slice(o),s),e.set(t.slice(r,r+o),n),e.delete(i),e=n}r+=o;continue outer}let i=/* @__PURE__ */ new Map;return e.set(t.slice(r),i),i}return e},T=(e,t)=>{let[n,r]=S(e,t);if(n!==void 0){if(n.delete(``),n.size===0)E(r);else if(n.size===1){let[e,t]=n.entries().next().value;D(r,e,t)}}},E=e=>{if(e.length===0)return;let[t,n]=O(e);if(t.delete(n),t.size===0)E(e.slice(0,-1));else if(t.size===1){let[n,r]=t.entries().next().value;n!==``&&D(e.slice(0,-1),n,r)}},D=(e,t,n)=>{if(e.length===0)return;let[r,i]=O(e);r.set(i+t,n),r.delete(i)},O=e=>e[e.length-1];var k=class e{constructor(e){if(e?.fields==null)throw Error(`MiniSearch: option "fields" must be provided`);let t=e.autoVacuum==null||e.autoVacuum===!0?B:e.autoVacuum;this._options={...F,...e,autoVacuum:t,searchOptions:{...I,...e.searchOptions||{}},autoSuggestOptions:{...L,...e.autoSuggestOptions||{}}},this._index=new x,this._documentCount=0,this._documentIds=/* @__PURE__ */ new Map,this._idToShortId=/* @__PURE__ */ new Map,this._fieldIds={},this._fieldLength=/* @__PURE__ */ new Map,this._avgFieldLength=[],this._nextId=0,this._storedFields=/* @__PURE__ */ new Map,this._dirtCount=0,this._currentVacuum=null,this._enqueuedVacuum=null,this._enqueuedVacuumConditions=z,this.addFields(this._options.fields)}add(e){let{extractField:t,stringifyField:n,tokenize:r,processTerm:i,fields:a,idField:o}=this._options,s=t(e,o);if(s==null)throw Error(`MiniSearch: document does not have ID field "${o}"`);if(this._idToShortId.has(s))throw Error(`MiniSearch: duplicate ID ${s}`);let c=this.addDocumentId(s);this.saveStoredFields(c,e);for(let o of a){let a=t(e,o);if(a==null)continue;let s=r(n(a,o),o),l=this._fieldIds[o],u=new Set(s).size;this.addFieldLength(c,l,this._documentCount-1,u);for(let e of s){let t=i(e,o);if(Array.isArray(t))for(let e of t)this.addTerm(l,c,e);else t&&this.addTerm(l,c,t)}}}addAll(e){for(let t of e)this.add(t)}addAllAsync(e,t={}){let{chunkSize:n=10}=t,r={chunk:[],promise:Promise.resolve()},{chunk:i,promise:a}=e.reduce(({chunk:e,promise:t},r,i)=>(e.push(r),(i+1)%n===0?{chunk:[],promise:t.then(()=>new Promise(e=>setTimeout(e,0))).then(()=>this.addAll(e))}:{chunk:e,promise:t}),r);return a.then(()=>this.addAll(i))}remove(e){let{tokenize:t,processTerm:n,extractField:r,stringifyField:i,fields:a,idField:o}=this._options,s=r(e,o);if(s==null)throw Error(`MiniSearch: document does not have ID field "${o}"`);let c=this._idToShortId.get(s);if(c==null)throw Error(`MiniSearch: cannot remove document with ID ${s}: it is not in the index`);for(let o of a){let a=r(e,o);if(a==null)continue;let s=t(i(a,o),o),l=this._fieldIds[o],u=new Set(s).size;this.removeFieldLength(c,l,this._documentCount,u);for(let e of s){let t=n(e,o);if(Array.isArray(t))for(let e of t)this.removeTerm(l,c,e);else t&&this.removeTerm(l,c,t)}}this._storedFields.delete(c),this._documentIds.delete(c),this._idToShortId.delete(s),this._fieldLength.delete(c),--this._documentCount}removeAll(e){if(e)for(let t of e)this.remove(t);else if(arguments.length>0)throw Error(`Expected documents to be present. Omit the argument to remove all documents.`);else this._index=new x,this._documentCount=0,this._documentIds=/* @__PURE__ */ new Map,this._idToShortId=/* @__PURE__ */ new Map,this._fieldLength=/* @__PURE__ */ new Map,this._avgFieldLength=[],this._storedFields=/* @__PURE__ */ new Map,this._nextId=0}discard(e){let t=this._idToShortId.get(e);if(t==null)throw Error(`MiniSearch: cannot discard document with ID ${e}: it is not in the index`);this._idToShortId.delete(e),this._documentIds.delete(t),this._storedFields.delete(t),(this._fieldLength.get(t)||[]).forEach((e,n)=>{this.removeFieldLength(t,n,this._documentCount,e)}),this._fieldLength.delete(t),--this._documentCount,this._dirtCount+=1,this.maybeAutoVacuum()}maybeAutoVacuum(){if(this._options.autoVacuum===!1)return;let{minDirtFactor:e,minDirtCount:t,batchSize:n,batchWait:r}=this._options.autoVacuum;this.conditionalVacuum({batchSize:n,batchWait:r},{minDirtCount:t,minDirtFactor:e})}discardAll(e){let t=this._options.autoVacuum;try{this._options.autoVacuum=!1;for(let t of e)this.discard(t)}finally{this._options.autoVacuum=t}this.maybeAutoVacuum()}replace(e){let{idField:t,extractField:n}=this._options,r=n(e,t);this.discard(r),this.add(e)}vacuum(e={}){return this.conditionalVacuum(e)}conditionalVacuum(e,t){return this._currentVacuum?(this._enqueuedVacuumConditions=this._enqueuedVacuumConditions&&t,this._enqueuedVacuum??=this._currentVacuum.then(()=>{let t=this._enqueuedVacuumConditions;return this._enqueuedVacuumConditions=z,this.performVacuuming(e,t)}),this._enqueuedVacuum):this.vacuumConditionsMet(t)===!1?Promise.resolve():(this._currentVacuum=this.performVacuuming(e),this._currentVacuum)}async performVacuuming(e,t){let n=this._dirtCount;if(this.vacuumConditionsMet(t)){let t=e.batchSize||R.batchSize,r=e.batchWait||R.batchWait,i=1;for(let[e,n]of this._index){for(let[e,t]of n)for(let[r]of t)this._documentIds.has(r)||(t.size<=1?n.delete(e):t.delete(r));this._index.get(e).size===0&&this._index.delete(e),i%t===0&&await new Promise(e=>setTimeout(e,r)),i+=1}this._dirtCount-=n}await null,this._currentVacuum=this._enqueuedVacuum,this._enqueuedVacuum=null}vacuumConditionsMet(e){if(e==null)return!0;let{minDirtCount:t,minDirtFactor:n}=e;return t||=B.minDirtCount,n||=B.minDirtFactor,this.dirtCount>=t&&this.dirtFactor>=n}get isVacuuming(){return this._currentVacuum!=null}get dirtCount(){return this._dirtCount}get dirtFactor(){return this._dirtCount/(1+this._documentCount+this._dirtCount)}has(e){return this._idToShortId.has(e)}getStoredFields(e){let t=this._idToShortId.get(e);if(t!=null)return this._storedFields.get(t)}search(t,n={}){let{searchOptions:r}=this._options,i={...r,...n},a=this.executeQuery(t,n),o=[];for(let[e,{score:t,terms:n,match:r}]of a){let a=n.length||1,s={id:this._documentIds.get(e),score:t*a,terms:Object.keys(r),queryTerms:n,match:r};Object.assign(s,this._storedFields.get(e)),(i.filter==null||i.filter(s))&&o.push(s)}return t===e.wildcard&&i.boostDocument==null||o.sort(U),o}autoSuggest(e,t={}){t={...this._options.autoSuggestOptions,...t};let n=/* @__PURE__ */ new Map;for(let{score:r,terms:i}of this.search(e,t)){let e=i.join(` `),t=n.get(e);t==null?n.set(e,{score:r,terms:i,count:1}):(t.score+=r,t.count+=1)}let r=[];for(let[e,{score:t,terms:i,count:a}]of n)r.push({suggestion:e,terms:i,score:t/a});return r.sort(U),r}get documentCount(){return this._documentCount}get termCount(){return this._index.size}static loadJSON(e,t){if(t==null)throw Error(`MiniSearch: loadJSON should be given the same options used when serializing the index`);return this.loadJS(JSON.parse(e),t)}static async loadJSONAsync(e,t){if(t==null)throw Error(`MiniSearch: loadJSON should be given the same options used when serializing the index`);return this.loadJSAsync(JSON.parse(e),t)}static getDefault(e){if(F.hasOwnProperty(e))return A(F,e);throw Error(`MiniSearch: unknown option "${e}"`)}static loadJS(e,t){let{index:n,documentIds:r,fieldLength:i,storedFields:a,serializationVersion:o}=e,s=this.instantiateMiniSearch(e,t);s._documentIds=G(r),s._fieldLength=G(i),s._storedFields=G(a);for(let[e,t]of s._documentIds)s._idToShortId.set(t,e);for(let[e,t]of n){let n=/* @__PURE__ */ new Map;for(let e of Object.keys(t)){let r=t[e];o===1&&(r=r.ds),n.set(parseInt(e,10),G(r))}s._index.set(e,n)}return s}static async loadJSAsync(e,t){let{index:n,documentIds:r,fieldLength:i,storedFields:a,serializationVersion:o}=e,s=this.instantiateMiniSearch(e,t);s._documentIds=await K(r),s._fieldLength=await K(i),s._storedFields=await K(a);for(let[e,t]of s._documentIds)s._idToShortId.set(t,e);let c=0;for(let[e,t]of n){let n=/* @__PURE__ */ new Map;for(let e of Object.keys(t)){let r=t[e];o===1&&(r=r.ds),n.set(parseInt(e,10),await K(r))}++c%1e3==0&&await q(0),s._index.set(e,n)}return s}static instantiateMiniSearch(t,n){let{documentCount:r,nextId:i,fieldIds:a,averageFieldLength:o,dirtCount:s,serializationVersion:c}=t;if(c!==1&&c!==2)throw Error(`MiniSearch: cannot deserialize an index created with an incompatible version`);let l=new e(n);return l._documentCount=r,l._nextId=i,l._idToShortId=/* @__PURE__ */ new Map,l._fieldIds=a,l._avgFieldLength=o,l._dirtCount=s||0,l._index=new x,l}executeQuery(t,n={}){if(t===e.wildcard)return this.executeWildcardQuery(n);if(typeof t!=`string`){let e={...n,...t,queries:void 0},r=t.queries.map(t=>this.executeQuery(t,e));return this.combineResults(r,e.combineWith)}let{tokenize:r,processTerm:i,searchOptions:a}=this._options,o={tokenize:r,processTerm:i,...a,...n},{tokenize:s,processTerm:c}=o,l=s(t).flatMap(e=>c(e)).filter(e=>!!e).map(P(o)).map(e=>this.executeQuerySpec(e,o));return this.combineResults(l,o.combineWith)}executeQuerySpec(e,t){let n={...this._options.searchOptions,...t},r=(n.fields||this._options.fields).reduce((e,t)=>({...e,[t]:A(n.boost,t)||1}),{}),{boostDocument:i,weights:a,maxFuzzy:o,bm25:s}=n,{fuzzy:c,prefix:l}={...I.weights,...a},u=this._index.get(e.term),d=this.termResults(e.term,e.term,1,e.termBoost,u,r,i,s),f,p;if(e.prefix&&(f=this._index.atPrefix(e.term)),e.fuzzy){let t=e.fuzzy===!0?.2:e.fuzzy,n=t<1?Math.min(o,Math.round(e.term.length*t)):t;n&&(p=this._index.fuzzyGet(e.term,n))}if(f)for(let[t,n]of f){let a=t.length-e.term.length;if(!a)continue;p?.delete(t);let o=l*t.length/(t.length+.3*a);this.termResults(e.term,t,o,e.termBoost,n,r,i,s,d)}if(p)for(let t of p.keys()){let[n,a]=p.get(t);if(!a)continue;let o=c*t.length/(t.length+a);this.termResults(e.term,t,o,e.termBoost,n,r,i,s,d)}return d}executeWildcardQuery(e){let t=/* @__PURE__ */ new Map,n={...this._options.searchOptions,...e};for(let[e,r]of this._documentIds){let i=n.boostDocument?n.boostDocument(r,``,this._storedFields.get(e)):1;t.set(e,{score:i,terms:[],match:{}})}return t}combineResults(e,t=`or`){if(e.length===0)return/* @__PURE__ */ new Map;let n=t.toLowerCase(),r=j[n];if(!r)throw Error(`Invalid combination operator: ${t}`);return e.reduce(r)||/* @__PURE__ */ new Map}toJSON(){let e=[];for(let[t,n]of this._index){let r={};for(let[e,t]of n)r[e]=Object.fromEntries(t);e.push([t,r])}return{documentCount:this._documentCount,nextId:this._nextId,documentIds:Object.fromEntries(this._documentIds),fieldIds:this._fieldIds,fieldLength:Object.fromEntries(this._fieldLength),averageFieldLength:this._avgFieldLength,storedFields:Object.fromEntries(this._storedFields),dirtCount:this._dirtCount,index:e,serializationVersion:2}}termResults(e,t,n,r,i,a,o,s,c=/* @__PURE__ */ new Map){if(i==null)return c;for(let l of Object.keys(a)){let u=a[l],d=this._fieldIds[l],f=i.get(d);if(f==null)continue;let p=f.size,m=this._avgFieldLength[d];for(let i of f.keys()){if(!this._documentIds.has(i)){this.removeTerm(d,i,t),--p;continue}let a=o?o(this._documentIds.get(i),t,this._storedFields.get(i)):1;if(!a)continue;let h=f.get(i),g=this._fieldLength.get(i)[d],_=N(h,p,this._documentCount,g,m,s),v=n*r*u*a*_,y=c.get(i);if(y){y.score+=v,V(y.terms,e);let n=A(y.match,t);n?n.push(l):y.match[t]=[l]}else c.set(i,{score:v,terms:[e],match:{[t]:[l]}})}}return c}addTerm(e,t,n){let r=this._index.fetch(n,W),i=r.get(e);if(i==null)i=/* @__PURE__ */ new Map,i.set(t,1),r.set(e,i);else{let e=i.get(t);i.set(t,(e||0)+1)}}removeTerm(e,t,n){if(!this._index.has(n)){this.warnDocumentChanged(t,e,n);return}let r=this._index.fetch(n,W),i=r.get(e);i==null||i.get(t)==null?this.warnDocumentChanged(t,e,n):i.get(t)<=1?i.size<=1?r.delete(e):i.delete(t):i.set(t,i.get(t)-1),this._index.get(n).size===0&&this._index.delete(n)}warnDocumentChanged(e,t,n){for(let r of Object.keys(this._fieldIds))if(this._fieldIds[r]===t){this._options.logger(`warn`,`MiniSearch: document with ID ${this._documentIds.get(e)} has changed before removal: term "${n}" was not present in field "${r}". Removing a document after it has changed can corrupt the index!`,`version_conflict`);return}}addDocumentId(e){let t=this._nextId;return this._idToShortId.set(e,t),this._documentIds.set(t,e),this._documentCount+=1,this._nextId+=1,t}addFields(e){for(let t=0;t<e.length;t++)this._fieldIds[e[t]]=t}addFieldLength(e,t,n,r){let i=this._fieldLength.get(e);i??this._fieldLength.set(e,i=[]),i[t]=r;let a=(this._avgFieldLength[t]||0)*n+r;this._avgFieldLength[t]=a/(n+1)}removeFieldLength(e,t,n,r){if(n===1){this._avgFieldLength[t]=0;return}let i=this._avgFieldLength[t]*n-r;this._avgFieldLength[t]=i/(n-1)}saveStoredFields(e,t){let{storeFields:n,extractField:r}=this._options;if(n==null||n.length===0)return;let i=this._storedFields.get(e);i??this._storedFields.set(e,i={});for(let e of n){let n=r(t,e);n!==void 0&&(i[e]=n)}}};k.wildcard=Symbol(`*`);const A=(e,t)=>Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0,j={or:(e,t)=>{for(let n of t.keys()){let r=e.get(n);if(r==null)e.set(n,t.get(n));else{let{score:e,terms:i,match:a}=t.get(n);r.score+=e,r.match=Object.assign(r.match,a),H(r.terms,i)}}return e},and:(e,t)=>{let n=/* @__PURE__ */ new Map;for(let r of t.keys()){let i=e.get(r);if(i==null)continue;let{score:a,terms:o,match:s}=t.get(r);H(i.terms,o),n.set(r,{score:i.score+a,terms:i.terms,match:Object.assign(i.match,s)})}return n},and_not:(e,t)=>{for(let n of t.keys())e.delete(n);return e}},M={k:1.2,b:.7,d:.5},N=(e,t,n,r,i,a)=>{let{k:o,b:s,d:c}=a;return Math.log(1+(n-t+.5)/(t+.5))*(c+e*(o+1)/(e+o*(1-s+s*r/i)))},P=e=>(t,n,r)=>({term:t,fuzzy:typeof e.fuzzy==`function`?e.fuzzy(t,n,r):e.fuzzy||!1,prefix:typeof e.prefix==`function`?e.prefix(t,n,r):e.prefix===!0,termBoost:typeof e.boostTerm==`function`?e.boostTerm(t,n,r):1}),F={idField:`id`,extractField:(e,t)=>e[t],stringifyField:(e,t)=>e.toString(),tokenize:e=>e.split(J),processTerm:e=>e.toLowerCase(),fields:void 0,searchOptions:void 0,storeFields:[],logger:(e,t)=>{typeof(console==null?void 0:console[e])==`function`&&console[e](t)},autoVacuum:!0},I={combineWith:`or`,prefix:!1,fuzzy:!1,maxFuzzy:6,boost:{},weights:{fuzzy:.45,prefix:.375},bm25:M},L={combineWith:`and`,prefix:(e,t,n)=>t===n.length-1},R={batchSize:1e3,batchWait:10},z={minDirtFactor:.1,minDirtCount:20},B={...R,...z},V=(e,t)=>{e.includes(t)||e.push(t)},H=(e,t)=>{for(let n of t)e.includes(n)||e.push(n)},U=({score:e},{score:t})=>t-e,W=()=>/* @__PURE__ */ new Map,G=e=>{let t=/* @__PURE__ */ new Map;for(let n of Object.keys(e))t.set(parseInt(n,10),e[n]);return t},K=async e=>{let t=/* @__PURE__ */ new Map,n=0;for(let r of Object.keys(e))t.set(parseInt(r,10),e[r]),++n%1e3==0&&await q(0);return t},q=e=>new Promise(t=>setTimeout(t,e)),J=/[\n\r\p{Z}\p{P}]+/u;function Y(e,t){let n=e.fullPath.slice(0,-1).map((t,n)=>e.fullPath.slice(0,n+1).join(` `));return{command:e.command,summary:e.summary||e.description.split(`
|
|
6
|
+
`)[0]||``,description:e.description,context:[...n.map(e=>t[e]??``),...e.arguments.map(e=>`${e.name} ${e.description}`),...e.options.map(e=>`${e.name} ${e.description}`)].join(` `)}}function X(e,t){let n=e.commands.map(t=>Y(t,e.descriptions??{})),r=new k({fields:[`command`,`summary`,`description`,`context`],storeFields:[`command`,`summary`],idField:`command`});return r.addAll(n),r.search(t,{prefix:!0,fuzzy:.2,boost:{command:8,summary:5,description:2,context:.5}}).slice(0,5).map(({command:e,summary:t})=>({command:e,summary:t}))}const Z={command:`search <query>`,describe:`Search all CLI commands by intent`,builder:e=>e.positional(`query`,{describe:`Search terms or a description of what you want to do`,type:`string`,demandOption:!0}),handler:n=>c({command:`cli search`,recordArgs:!1,searchQuery:n.query},n,()=>{let a=e(import.meta.url,`commands.json`,t);if(!a)throw console.error(`Error: Could not load commands.json.`),new r(1);i(X(a,n.query))})},Q={command:`cli`,describe:`Discover commands and configure the cf CLI`,builder:e=>e.command(Z).command(m).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{Q as default};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-MNz2D-PD.mjs";import{i as n}from"./context-q-6bMSL-.mjs";import{t as r}from"./output-Co4xdFf6.mjs";import{t as i}from"./dry-run-C2KjGX10.mjs";import{t as a}from"./progress-DaQ4MzBI.mjs";import{t as o}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";import{n as s,t as c}from"./body-parser-DkHKPkJ7.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{a as u,n as d}from"./prompt-KWYZvJWM.mjs";var f={method:`POST`,path:t=>e`/zones/${t.zone_id}/client_certificates`,body:`json`};function p(e){return e.usage(`$0 client-certificates create
|
|
3
3
|
|
|
4
4
|
Create a new API Shield mTLS Client Certificate.`).option(`csr`,{type:`string`,description:`The Certificate Signing Request (CSR). Must be newline-encoded.`}).option(`validity-days`,{type:`number`,description:`The number of days the Client Certificate will be valid after the issued_on date.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const m={command:`create`,describe:`Create Client Certificate`,builder:p,handler:async e=>o({command:`client-certificates create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf client-certificates create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/client_certificates`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?c({csr:l(e.csr,`csr`,`text`),validity_days:e[`validity-days`]}):s(e.body)});return}let o=await t(e),d=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=d,e.body){let t=s(e.body),n=await a(`Creating`,async()=>o.send(f,{body:t,zone_id:d}));r(n,{successLabel:`Created`});return}if(e.csr===void 0&&(e.csr=await u(`csr`,`The Certificate Signing Request (CSR). Must be newline-encoded.`)),e[`validity-days`]===void 0)throw Error(`--validity-days is required (or pass --body with this field set).`);let p=c({csr:l(e.csr,`csr`,`text`),validity_days:e[`validity-days`]}),m=await a(`Creating`,async()=>o.send(f,{body:p,zone_id:d}));r(m,{successLabel:`Created`})})};var h={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/client_certificates/${t.client_certificate_id}`};function g(e){return e.usage(`$0 client-certificates delete <client-certificate-id>
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-MNz2D-PD.mjs";import{i as n}from"./context-q-6bMSL-.mjs";import{t as r}from"./output-Co4xdFf6.mjs";import{t as i}from"./dry-run-C2KjGX10.mjs";import{t as a}from"./progress-DaQ4MzBI.mjs";import{t as o}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";import{n as s,t as c}from"./body-parser-DkHKPkJ7.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{a as u,i as d,n as f}from"./prompt-KWYZvJWM.mjs";var p={method:`GET`,path:t=>e`/zones/${t.zone_id}/page_shield/connections/${t.connection_id}`};function m(e){return e.usage(`$0 client-side-security connections get <connection-id>
|
|
3
3
|
|
|
4
4
|
Returns a webpage connection detected on the zone by connection ID.`).positional(`connection-id`,{type:`string`,description:`Identifier`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const h={command:`get <connection-id>`,describe:`Get a detected connection`,builder:m,handler:async e=>o({command:`client-side-security connections get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf client-side-security connections get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/page_shield/connections/${e[`connection-id`]==null?`<connection-id>`:encodeURIComponent(String(e[`connection-id`]))}`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),"connection-id":String(e[`connection-id`]??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});e.zoneId=s;let c=await a(`Loading`,async()=>o.send(p,{zone_id:s,connection_id:e[`connection-id`]}));r(c,{successLabel:`Loaded`})})};var g={method:`GET`,path:t=>e`/zones/${t.zone_id}/page_shield/connections`,query:[`exclude_urls`,`urls`,`hosts`,`page`,`per_page`,`order_by`,`direction`,`prioritize_malicious`,`exclude_cdn_cgi`,`status`,`page_url`,`export`]};function _(e){return e.usage(`$0 client-side-security connections list
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-MNz2D-PD.mjs";import{i as n}from"./context-q-6bMSL-.mjs";import{t as r}from"./output-Co4xdFf6.mjs";import{t as i}from"./dry-run-C2KjGX10.mjs";import{t as a}from"./progress-DaQ4MzBI.mjs";import{t as o}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";import{n as s}from"./body-parser-DkHKPkJ7.mjs";var c={method:`GET`,path:t=>e`/zones/${t.zone_id}/cloud_connector/rules`};function l(e){return e.usage(`$0 cloud-connector rules list
|
|
3
3
|
|
|
4
4
|
Retrieves the Cloud Connector rules configured for a zone. Rules define how traffic is routed to cloud services.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const u={command:`list`,describe:`Rules`,builder:l,handler:async e=>o({command:`cloud-connector rules list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf cloud-connector rules list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/cloud_connector/rules`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});e.zoneId=s;let l=await a(`Loading`,async()=>o.send(c,{zone_id:s}));r(l,{successLabel:`Loaded`})})};var d={method:`PUT`,path:t=>e`/zones/${t.zone_id}/cloud_connector/rules`,body:`json`};function f(e){return e.usage(`$0 cloud-connector rules update
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{i as n,n as r}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{i as n,n as r}from"./auth-MNz2D-PD.mjs";import{a as i,t as a}from"./context-q-6bMSL-.mjs";import{t as o}from"./output-Co4xdFf6.mjs";import{t as s}from"./dry-run-C2KjGX10.mjs";import{t as c}from"./progress-DaQ4MzBI.mjs";import{t as l}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";import{i as u,n as d,r as f,t as p}from"./body-parser-DkHKPkJ7.mjs";import{n as m,t as h}from"./input-validation-D7z60HJH.mjs";import{a as g,i as _,n as v}from"./prompt-KWYZvJWM.mjs";import{n as y,t as b}from"./raw-fetch-Cy09TjHc.mjs";function ee(e){return e.usage(`$0 cloudforce-one binary-storage create
|
|
3
3
|
|
|
4
4
|
Uploads a binary file to Cloudforce One's binary database for malware analysis and threat intelligence correlation.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Binary file to be uploaded to the database.`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`})}const te={command:`create`,describe:`Posts a file to Binary Storage`,builder:ee,handler:async e=>l({command:`cloudforce-one binary-storage create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf cloudforce-one binary-storage create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/cloudforce-one/binary`,pathParams:{},bodyKind:`multipart`,body:{body:e.body,file:e.file}});return}let l=await r(e),u=e.local?t:await a();if(e.accountId=u,e.file!==void 0||e.body!==void 0){let t=new FormData;if(e.file){let n=h(e.file);t.append(`file`,new Blob([n]),e.file.split(/[\\/]/).filter(Boolean).pop())}else e.body!==void 0&&t.append(`file`,e.body);let r=await c(`Creating`,async()=>n(l,`POST`,`/accounts/${u}/cloudforce-one/binary`,{body:t}));o(r,{successLabel:`Created`});return}if(e.body){let t=m(e.body,`body`,`binary`),r=await c(`Creating`,async()=>n(l,`POST`,`/accounts/${u}/cloudforce-one/binary`,{body:t,headers:{"Content-Type":`multipart/form-data`}}));o(r,{successLabel:`Created`});return}if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var ne={method:`GET`,path:t=>e`/accounts/${t.account_id}/cloudforce-one/binary/${t.hash}`,response:!1,errors:{400:`BadRequestError`}};function re(e){return e.usage(`$0 cloudforce-one binary-storage get <hash>
|
|
5
5
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-q-6bMSL-.mjs";import{n as r}from"./cloudflared-By8BzYXc.mjs";const i={command:`ssh-config`,describe:`Print an example SSH configuration for an Access application.`,builder:e=>e.option(`hostname`,{type:`string`,description:`Hostname of the Access application`}).option(`short-lived-cert`,{type:`boolean`,description:`Include short-lived certificate configuration`}),handler:async i=>{if(i.local)throw Error(`--local is not supported by cf access ssh-config.`);if(await t({mode:i.mode,local:i.local},()=>n())===`fedramp_high`)throw Error(`cf access ssh-config does not support FedRAMP because cloudflared does not include --fedramp in its generated SSH configuration.`);let a=[`access`,`ssh-config`];throw i.hostname&&a.push(`--hostname`,i.hostname),i[`short-lived-cert`]&&a.push(`--short-lived-cert`),new e(await r(a))}};export{i as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{x as e}from"./dist-DZRTPMMA.mjs";import{t}from"./chunk-DSGVRFIS-C5SqiTOz.mjs";import{i as n,n as r,t as i}from"./startup-profile-BOaseXnO.mjs";import{t as a}from"./output-Co4xdFf6.mjs";import{t as o}from"./progress-
|
|
2
|
+
import{x as e}from"./dist-DZRTPMMA.mjs";import{t}from"./chunk-DSGVRFIS-C5SqiTOz.mjs";import{i as n,n as r,t as i}from"./startup-profile-BOaseXnO.mjs";import{t as a}from"./output-Co4xdFf6.mjs";import{t as o}from"./progress-DaQ4MzBI.mjs";import{a as s,i as c,n as l,o as u,r as d,s as f}from"./build-i8l2qGVZ.mjs";import{t as p}from"./deploy-input-KK6yyBN_.mjs";import m from"node:path";import{writeFile as h}from"node:fs/promises";import{readBuildOutput as g}from"@cloudflare/build-output-utils";function _(e){return e.option(`outfile`,{type:`string`,description:`Output file for the startup CPU profile`,default:`worker-startup.cpuprofile`,requiresArg:!0}).option(`prebuilt`,{type:`boolean`,description:`Use existing Build Output Specification files without building`,default:!1}).option(`worker`,d)}const v={command:`check`,describe:`Profile a Worker's startup performance`,builder:_,handler:async d=>{if(d.local)throw Error(`--local is not supported by cf workers check.`);d.prebuilt||await l(d.mode,{output:d.quiet?`silent`:`stderr`,worker:d.worker});let{workers:_,rootConfig:v}=await g(process.cwd());u(d.mode,v.buildContext.mode);let y=s(_,d.worker),{wranglerConfig:b,builtConfig:x}=c(y,v),S=p(y,x);if(!S.resolvedEntryPointPath)throw new f(`Startup profiling requires a Worker entrypoint; assets-only projects cannot be profiled.`);if(S.bundleType===`commonjs`)throw new f(`Startup profiling does not support service-worker format Workers. Refer to https://developers.cloudflare.com/workers/reference/migrate-to-module-workers/ for migration guidance.`);let C=t({name:b.name??y.config.name??`worker`,main:{name:x.manifest?.mainModule??m.basename(S.resolvedEntryPointPath),filePath:S.resolvedEntryPointPath,content:S.content,type:S.bundleType},modules:S.modules,sourceMaps:S.sourceMaps,compatibility_date:b.compatibility_date,compatibility_flags:b.compatibility_flags??[],assets:void 0,containers:void 0,migrations:void 0,exports:void 0,keepVars:void 0,keepSecrets:void 0,logpush:void 0,placement:void 0,tail_consumers:void 0,streaming_tail_consumers:void 0,limits:void 0,annotations:void 0,observability:void 0,cache:void 0,package_dependencies:void 0},e(b),{dryRun:!0,unsafe:b.unsafe}),w=await r(C),T=d.quiet?await i(C):await o(`Profiling Worker startup`,()=>i(C)),E=n(T);await h(d.outfile,JSON.stringify(T)),a({bundle:{sizeBytes:w.size,gzipSizeBytes:w.gzipSize},startup:{profileWindowMs:E.profileWindow/1e3,sampledTimeMs:E.sampledTime/1e3,activeTimeMs:E.activeTime/1e3,garbageCollectionTimeMs:E.garbageCollectionTime/1e3,idleTimeMs:E.idleTime/1e3,sampleCount:E.sampleCount},profile:d.outfile,note:`This profile was measured locally. Use it to understand where startup time is spent, not to predict startup time on Cloudflare.`},{quiet:d.quiet})}};export{v as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-q-6bMSL-.mjs";import{n as r}from"./cloudflared-By8BzYXc.mjs";const i={command:`ssh-gen`,describe:`Generate a short-lived certificate for an Access SSH application.`,builder:e=>e.option(`hostname`,{type:`string`,description:`Hostname of the Access application`,demandOption:!0}),handler:async i=>{if(i.local)throw Error(`--local is not supported by cf access ssh-gen.`);let a=[`access`];throw await t({mode:i.mode,local:i.local},()=>n())===`fedramp_high`&&a.push(`--fedramp`),a.push(`ssh-gen`,`--hostname`,i.hostname),new e(await r(a))}};export{i as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-q-6bMSL-.mjs";import{n as r,t as i}from"./cloudflared-By8BzYXc.mjs";function a(e){return e.option(`hostname`,{type:`string`,demandOption:!0,description:`Hostname of the Access application`}).option(`destination`,{type:`string`,description:`Destination address of the target server`}).option(`url`,{type:`string`,description:`Local host and port to forward to the Cloudflare edge`}).option(`header`,{type:`string`,array:!0,description:`Additional request header; repeat for multiple headers`}).option(`service-token-id`,{type:`string`,description:`Access service token ID`}).option(`service-token-secret`,{type:`string`,description:`Access service token secret`}).option(`log-level`,{alias:`loglevel`,type:`string`,choices:i,description:`cloudflared log level`})}const o={command:`tcp`,aliases:[`ssh`,`rdp`,`smb`],describe:`Proxy a TCP connection through Access. The command is also available as ssh, rdp, and smb.`,builder:a,handler:async i=>{if(i.local)throw Error(`--local is not supported by cf access tcp.`);let a=[`access`];await t({mode:i.mode,local:i.local},()=>n())===`fedramp_high`&&a.push(`--fedramp`),a.push(`tcp`),a.push(`--hostname`,i.hostname),i.destination&&a.push(`--destination`,i.destination),i.url&&a.push(`--url`,i.url);for(let e of i.header??[])a.push(`--header`,e);i[`service-token-id`]&&a.push(`--service-token-id`,i[`service-token-id`]),i[`log-level`]&&a.push(`--loglevel`,i[`log-level`]);let o=i[`service-token-secret`]?{TUNNEL_SERVICE_TOKEN_SECRET:i[`service-token-secret`]}:void 0;throw new e(await r(a,{env:o}))}};export{o as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-q-6bMSL-.mjs";import{n as r}from"./cloudflared-By8BzYXc.mjs";const i={command:`login`,describe:`Authorize cloudflared and download an origin certificate for locally managed tunnels.`,handler:async i=>{if(i.local)throw Error(`--local is not supported by cf tunnels login.`);let a=[`tunnel`,`login`];throw await t({mode:i.mode,local:i.local},()=>n())===`fedramp_high`&&a.push(`--fedramp`),new e(await r(a))}};export{i as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-q-6bMSL-.mjs";import{n as r}from"./cloudflared-By8BzYXc.mjs";const i={command:`login <url>`,describe:`Authenticate with an Access application and store its JWT through cloudflared.`,builder:e=>e.positional(`url`,{type:`string`,description:`URL of the Access application`,demandOption:!0}),handler:async i=>{if(i.local)throw Error(`--local is not supported by cf access login.`);let a=[`access`];throw await t({mode:i.mode,local:i.local},()=>n())===`fedramp_high`&&a.push(`--fedramp`),a.push(`login`),i.quiet&&a.push(`--quiet`),a.push(i.url),new e(await r(a))}};export{i as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-q-6bMSL-.mjs";import{n as r}from"./cloudflared-By8BzYXc.mjs";const i={command:`token <url>`,describe:`Print a JWT for authenticating with an Access application.`,builder:e=>e.positional(`url`,{type:`string`,description:`URL of the Access application`,demandOption:!0}),handler:async i=>{if(i.local)throw Error(`--local is not supported by cf access token.`);let a=[`access`];throw await t({mode:i.mode,local:i.local},()=>n())===`fedramp_high`&&a.push(`--fedramp`),a.push(`token`,i.url),new e(await r(a))}};export{i as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./auth-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./auth-MNz2D-PD.mjs";import{t as r}from"./context-q-6bMSL-.mjs";import{t as i}from"./progress-DaQ4MzBI.mjs";import{t as a}from"./create-OXylMu6m.mjs";import{n as o}from"./cloudflared-By8BzYXc.mjs";const s=[`cloudflared`,`http`,`tcp`,`udp`],c=[`debug`,`info`,`warn`,`error`],l=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;function u(e,t){if(!l.test(e))throw Error(`${t} must be a valid UUID.`);return e}const d={command:`tail [tunnel-id]`,describe:`Stream logs from a remote cloudflared instance.`,builder:e=>e.positional(`tunnel-id`,{type:`string`,coerce:e=>u(e,`Tunnel ID`),description:`Tunnel UUID to stream logs from`}).option(`connector-id`,{type:`string`,coerce:e=>u(e,`--connector-id`),description:`Target a specific cloudflared connector`}).option(`event`,{type:`string`,choices:s,array:!0,description:`Filter by event type (may be repeated)`}).option(`level`,{type:`string`,choices:c,description:`Filter by log level`}).option(`sample`,{type:`number`,coerce:e=>{if(!Number.isFinite(e)||e<=0||e>1)throw Error(`--sample must be greater than 0.0 and no greater than 1.0.`);return e},description:`Sample log events by fraction greater than 0.0 and no greater than 1.0`}),handler:async s=>{if(s.local)throw Error(`--local is not supported by cf tunnels tail.`);let c=process.env.TUNNEL_MANAGEMENT_TOKEN;if(c!==void 0&&!c.trim())throw Error(`TUNNEL_MANAGEMENT_TOKEN must not be empty.`);if(c&&s[`tunnel-id`])throw Error(`Specify either a tunnel ID or TUNNEL_MANAGEMENT_TOKEN, not both.`);let l=c;if(!l){let e=s[`tunnel-id`];if(!e)throw Error(`Either a tunnel ID or TUNNEL_MANAGEMENT_TOKEN must be provided.`);l=await t({mode:s.mode,local:s.local},async()=>{let t=await n(s),o=await r();return i(`Fetching tunnel management token`,async()=>t.send(a,{account_id:o,tunnel_id:e,body:{resources:[`logs`]}}))})}let u=[`tail`,`--output`,`json`];if(s[`connector-id`]&&u.push(`--connector-id`,s[`connector-id`]),s.event)for(let e of s.event)u.push(`--event`,e);throw s.level&&u.push(`--level`,s.level),s.sample!==void 0&&u.push(`--sample`,String(s.sample)),s[`tunnel-id`]&&u.push(s[`tunnel-id`]),new e(await o(u,{env:{TUNNEL_MANAGEMENT_TOKEN:l}}))}};export{d as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import{n}from"./context-q-6bMSL-.mjs";import{n as r}from"./cloudflared-By8BzYXc.mjs";const i={command:`curl <url>`,describe:`Run curl against an Access-protected application with its JWT injected by cloudflared.`,builder:e=>e.parserConfiguration({"populate--":!0,"parse-positional-numbers":!1,"short-option-groups":!1}).option(`allow-request`,{alias:`ar`,type:`boolean`,description:`Continue the request when no Access token is available`}).positional(`url`,{type:`string`,description:`URL of the Access application`,demandOption:!0}),handler:async i=>{if(i.local)throw Error(`--local is not supported by cf access curl.`);let a=[`access`];throw await t({mode:i.mode,local:i.local},()=>n())===`fedramp_high`&&a.push(`--fedramp`),a.push(`curl`),i[`allow-request`]&&a.push(`--allow-request`),a.push(i.url,...(i[`--`]??[]).map(String)),new e(await r(a))}};export{i as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import"./api-eMuS5GI1.mjs";import{t as n}from"./path-DRw6Y-nd.mjs";import{n as r}from"./auth-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{r as t}from"./dotenv-usOKkeW7.mjs";import"./api-eMuS5GI1.mjs";import{t as n}from"./path-DRw6Y-nd.mjs";import{n as r}from"./auth-MNz2D-PD.mjs";import{r as i}from"./resolve-C3FmNlSO.mjs";import{t as a}from"./context-q-6bMSL-.mjs";import{t as o}from"./progress-DaQ4MzBI.mjs";import{t as s}from"./get-iPUHxD1r.mjs";import{n as c,t as l}from"./cloudflared-By8BzYXc.mjs";const u={method:`GET`,path:e=>n`/accounts/${e.account_id}/cfd_tunnel`,query:[`name`,`is_deleted`,`existed_at`,`uuid`,`was_active_at`,`was_inactive_at`,`include_prefix`,`exclude_prefix`,`status`,`per_page`,`page`]},d=1e3;async function f(e,t,n){if(i(n))return n;let r=0,a;for(let i=1;;i++){let o=await e.send(u,{account_id:t,name:n,is_deleted:!1,page:i,per_page:d}),s=o.result??[];for(let e of s)e.name===n&&(r++,a=e.id);let c=o.result_info?.per_page||d;if(s.length<c)break}if(r===0)throw Error(`"${n}" is neither the ID nor the name of any tunnel. Run \`cf tunnels list\` to see available tunnels.`);if(r>1)throw Error(`Found multiple tunnels named "${n}". Pass the tunnel UUID instead.`);if(!a)throw Error(`Tunnel "${n}" was found but has no ID. Pass the tunnel UUID instead.`);return a}async function p(e,t,n){let r=await e.send(s,{account_id:t,tunnel_id:n});if(typeof r!=`string`||r.length===0)throw Error(`The API returned an empty token for tunnel ${n}.`);return r}function m(e){return e.positional(`tunnel`,{type:`string`,description:`Tunnel name or UUID; required unless --token is provided`}).option(`token`,{type:`string`,description:`Tunnel token supplied directly to cloudflared`}).option(`log-level`,{type:`string`,choices:l,default:`info`,description:`cloudflared log level`})}const h={command:`run [tunnel]`,describe:`Run a named Cloudflare Tunnel using the cf-managed cloudflared binary.`,builder:m,handler:async n=>{if(n.local)throw Error(`--local is not supported by cf tunnels run.`);let i=n.token,s=n.tunnel;if(!i){if(!s)throw Error(`Either a tunnel name/UUID or --token must be provided.`);i=await t(n,async()=>{let e=await r(n),t=await a();return o(`Fetching tunnel token`,async()=>{let n=await f(e,t,s);return p(e,t,n)})})}let l=[`tunnel`,`--loglevel`,n[`log-level`]];throw l.push(`run`),new e(await c(l,{env:{TUNNEL_TOKEN:i}}))}};export{h as default};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{n as e,t}from"./metadata-Df5kCWJv.mjs";import{t as n}from"./run-
|
|
2
|
+
import{n as e,t}from"./metadata-Df5kCWJv.mjs";import{t as n}from"./run-Clc3P2u7.mjs";import r from"node:assert";function i(e,t){return`#compdef ${e}
|
|
3
3
|
compdef _${e} ${e}
|
|
4
4
|
|
|
5
5
|
# zsh completion for ${e} -*- shell-script -*-
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{n}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{n}from"./auth-MNz2D-PD.mjs";import{a as r,t as i}from"./context-q-6bMSL-.mjs";import{t as a}from"./output-Co4xdFf6.mjs";import{t as o}from"./dry-run-C2KjGX10.mjs";import{t as s}from"./progress-DaQ4MzBI.mjs";import{t as c}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";import{n as l,t as u}from"./body-parser-DkHKPkJ7.mjs";var d={method:`POST`,path:t=>e`/accounts/${t.account_id}/magic/connectors/${t.connector_id}/interrupts`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,409:`ConflictError`,500:`InternalServerError`}};function f(e){return e.usage(`$0 connector-interrupts create <connector-id>
|
|
3
3
|
|
|
4
4
|
Creates an interrupt for a Magic WAN Connector.`).positional(`connector-id`,{type:`string`,description:`Connector ID`,demandOption:!0}).option(`reboot-purge`,{type:`boolean`,description:`Purge connector state.`}).option(`restart-purge`,{type:`boolean`,description:`Purge connector state.`}).option(`shutdown-purge`,{type:`boolean`,description:`Purge connector state.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Interrupt action for a connector.`})}const p={command:`create <connector-id>`,describe:`Create Interrupt`,builder:f,handler:async e=>c({command:`connector-interrupts create`,classification:{safeFlags:[`reboot-purge`,`restart-purge`,`shutdown-purge`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf connector-interrupts create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/magic/connectors/${e[`connector-id`]==null?`<connector-id>`:encodeURIComponent(String(e[`connector-id`]))}/interrupts`,pathParams:{"connector-id":String(e[`connector-id`]??``)},bodyKind:`json`,body:e.body===void 0?u({reboot:{purge:e[`reboot-purge`]},restart:{purge:e[`restart-purge`]},shutdown:{purge:e[`shutdown-purge`]}}):l(e.body)});return}let c=await n(e),f=e.local?t:await i();if(e.accountId=f,e.body){let t=l(e.body),n=await s(`Creating`,async()=>c.send(d,{body:t,account_id:f,connector_id:e[`connector-id`]}));a(n,{successLabel:`Created`});return}let p=u({reboot:{purge:e[`reboot-purge`]},restart:{purge:e[`restart-purge`]},shutdown:{purge:e[`shutdown-purge`]}}),m=await s(`Creating`,async()=>c.send(d,{body:p,account_id:f,connector_id:e[`connector-id`]}));a(m,{successLabel:`Created`})})};var m={method:`GET`,path:t=>e`/accounts/${t.account_id}/magic/connectors/${t.connector_id}/interrupts`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,500:`InternalServerError`}};function h(e){return e.usage(`$0 connector-interrupts list
|
|
5
5
|
|
package/dist/{connector-telemetry-events-BQGBQwzR.mjs → connector-telemetry-events-C0GGCIQk.mjs}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{n}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{n}from"./auth-MNz2D-PD.mjs";import{a as r,t as i}from"./context-q-6bMSL-.mjs";import{t as a}from"./output-Co4xdFf6.mjs";import{t as o}from"./dry-run-C2KjGX10.mjs";import{t as s}from"./progress-DaQ4MzBI.mjs";import{t as c}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";var l={method:`GET`,path:t=>e`/accounts/${t.account_id}/magic/connectors/${t.connector_id}/telemetry/events/${t.event_t}.${t.event_n}`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,429:`TooManyRequestsError`,500:`InternalServerError`}};function u(e){return e.usage(`$0 connector-telemetry-events get <event-n>
|
|
3
3
|
|
|
4
4
|
Gets Magic WAN Connector Telemetry Event`).positional(`event-n`,{type:`string`,description:`Event n`,demandOption:!0}).option(`connector-id`,{type:`string`,description:`Connector ID`,demandOption:!0}).option(`event-t`,{type:`string`,description:`Event t`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const d={command:`get <event-n>`,describe:`Get Event`,builder:u,handler:async e=>c({command:`connector-telemetry-events get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf connector-telemetry-events get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/magic/connectors/${e[`connector-id`]==null?`<connector-id>`:encodeURIComponent(String(e[`connector-id`]))}/telemetry/events/${e[`event-t`]==null?`<event-t>`:encodeURIComponent(String(e[`event-t`]))}.${e[`event-n`]==null?`<event-n>`:encodeURIComponent(String(e[`event-n`]))}`,pathParams:{"connector-id":String(e[`connector-id`]??``),"event-t":String(e[`event-t`]??``),"event-n":String(e[`event-n`]??``)},bodyKind:`none`});return}let c=await n(e),u=e.local?t:await i();e.accountId=u;let d=await s(`Loading`,async()=>c.send(l,{account_id:u,connector_id:e[`connector-id`],event_t:e[`event-t`],event_n:e[`event-n`]}));a(d,{successLabel:`Loaded`})})};var f={method:`GET`,path:t=>e`/accounts/${t.account_id}/magic/connectors/${t.connector_id}/telemetry/events`,query:[`from`,`to`,`limit`,`cursor`,`k`],errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,429:`TooManyRequestsError`,500:`InternalServerError`}};function p(e){return e.usage(`$0 connector-telemetry-events list
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{n}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{n}from"./auth-MNz2D-PD.mjs";import{a as r,t as i}from"./context-q-6bMSL-.mjs";import{t as a}from"./output-Co4xdFf6.mjs";import{t as o}from"./dry-run-C2KjGX10.mjs";import{t as s}from"./progress-DaQ4MzBI.mjs";import{t as c}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";var l={method:`GET`,path:t=>e`/accounts/${t.account_id}/magic/connectors/${t.connector_id}/telemetry/snapshots/${t.snapshot_t}`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,429:`TooManyRequestsError`,500:`InternalServerError`}};function u(e){return e.usage(`$0 connector-telemetry-snapshots get <snapshot-t>
|
|
3
3
|
|
|
4
4
|
Gets Magic WAN Connector Telemetry Snapshot`).positional(`snapshot-t`,{type:`string`,description:`Snapshot t`,demandOption:!0}).option(`connector-id`,{type:`string`,description:`Connector ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const d={command:`get <snapshot-t>`,describe:`Get Snapshot`,builder:u,handler:async e=>c({command:`connector-telemetry-snapshots get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf connector-telemetry-snapshots get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/magic/connectors/${e[`connector-id`]==null?`<connector-id>`:encodeURIComponent(String(e[`connector-id`]))}/telemetry/snapshots/${e[`snapshot-t`]==null?`<snapshot-t>`:encodeURIComponent(String(e[`snapshot-t`]))}`,pathParams:{"connector-id":String(e[`connector-id`]??``),"snapshot-t":String(e[`snapshot-t`]??``)},bodyKind:`none`});return}let c=await n(e),u=e.local?t:await i();e.accountId=u;let d=await s(`Loading`,async()=>c.send(l,{account_id:u,connector_id:e[`connector-id`],snapshot_t:e[`snapshot-t`]}));a(d,{successLabel:`Loaded`})})};var f={method:`GET`,path:t=>e`/accounts/${t.account_id}/magic/connectors/${t.connector_id}/telemetry/snapshots`,query:[`from`,`to`,`limit`,`cursor`],errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,429:`TooManyRequestsError`,500:`InternalServerError`}};function p(e){return e.usage(`$0 connector-telemetry-snapshots list
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{n}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Dil4fTWX.mjs";import{n}from"./auth-MNz2D-PD.mjs";import{a as r,t as i}from"./context-q-6bMSL-.mjs";import{t as a}from"./output-Co4xdFf6.mjs";import{t as o}from"./dry-run-C2KjGX10.mjs";import{t as s}from"./progress-DaQ4MzBI.mjs";import{t as c}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";import{n as l,t as u}from"./body-parser-DkHKPkJ7.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{n as f}from"./prompt-KWYZvJWM.mjs";var p={method:`POST`,path:t=>e`/accounts/${t.account_id}/magic/connectors`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,409:`ConflictError`,500:`InternalServerError`}};function m(e){return e.usage(`$0 connectors create
|
|
3
3
|
|
|
4
4
|
Creates a Magic WAN Connector.`).option(`device-id`,{type:`string`,description:`The device.id field`}).option(`device-provision-license`,{type:`boolean`,description:`When true, create and provision a new licence key for the connector.`}).option(`device-serial-number`,{type:`string`,description:`The device.serial_number field`}).option(`activated`,{type:`boolean`,description:`The activated field`}).option(`interrupt-window-days-of-week`,{type:`string`,array:!0,description:`Allowed days of the week for upgrades. Default is all days.`}).option(`interrupt-window-duration-hours`,{type:`number`,description:`The interrupt_window_duration_hours field`}).option(`interrupt-window-embargo-dates`,{type:`string`,array:!0,description:`List of dates (YYYY-MM-DD) when upgrades are blocked.`}).option(`interrupt-window-hour-of-day`,{type:`number`,description:`The interrupt_window_hour_of_day field`}).option(`notes`,{type:`string`,description:`The notes field`}).option(`timezone`,{type:`string`,description:`The timezone field`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const h={command:`create`,describe:`Create Connector`,builder:m,handler:async e=>c({command:`connectors create`,classification:{safeFlags:[`device-provision-license`,`activated`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf connectors create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/magic/connectors`,pathParams:{},bodyKind:`json`,body:e.body===void 0?u({device:{id:d(e[`device-id`],`device-id`,`text`),provision_license:e[`device-provision-license`],serial_number:d(e[`device-serial-number`],`device-serial-number`,`text`)},activated:e.activated,interrupt_window_days_of_week:e[`interrupt-window-days-of-week`],interrupt_window_duration_hours:e[`interrupt-window-duration-hours`],interrupt_window_embargo_dates:e[`interrupt-window-embargo-dates`],interrupt_window_hour_of_day:e[`interrupt-window-hour-of-day`],notes:d(e.notes,`notes`,`text`),timezone:d(e.timezone,`timezone`,`text`)}):l(e.body)});return}let c=await n(e),f=e.local?t:await i();if(e.accountId=f,e.body){let t=l(e.body),n=await s(`Creating`,async()=>c.send(p,{body:t,account_id:f}));a(n,{successLabel:`Created`});return}let m=u({device:{id:d(e[`device-id`],`device-id`,`text`),provision_license:e[`device-provision-license`],serial_number:d(e[`device-serial-number`],`device-serial-number`,`text`)},activated:e.activated,interrupt_window_days_of_week:e[`interrupt-window-days-of-week`],interrupt_window_duration_hours:e[`interrupt-window-duration-hours`],interrupt_window_embargo_dates:e[`interrupt-window-embargo-dates`],interrupt_window_hour_of_day:e[`interrupt-window-hour-of-day`],notes:d(e.notes,`notes`,`text`),timezone:d(e.timezone,`timezone`,`text`)}),h=await s(`Creating`,async()=>c.send(p,{body:m,account_id:f}));a(h,{successLabel:`Created`})})};var g={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/magic/connectors/${t.connector_id}`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,500:`InternalServerError`}};function _(e){return e.usage(`$0 connectors delete <connector-id>
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{K as e}from"./dist-DZRTPMMA.mjs";import{s as t}from"./blocks-Bat9A8V_.mjs";import"./api-eMuS5GI1.mjs";import{t as n}from"./path-DRw6Y-nd.mjs";import{t as r}from"./hand-written-dry-run-B82fRl2N.mjs";import{t as i}from"./local-Dil4fTWX.mjs";import{n as a}from"./auth-
|
|
2
|
+
import{K as e}from"./dist-DZRTPMMA.mjs";import{s as t}from"./blocks-Bat9A8V_.mjs";import"./api-eMuS5GI1.mjs";import{t as n}from"./path-DRw6Y-nd.mjs";import{t as r}from"./hand-written-dry-run-B82fRl2N.mjs";import{t as i}from"./local-Dil4fTWX.mjs";import{n as a}from"./auth-MNz2D-PD.mjs";import{a as o,n as s,t as c}from"./context-q-6bMSL-.mjs";import{E as ee,S as te,T as l,_ as u,b as ne,f as d,h as f,p as re,s as p,t as m,u as ie,v as ae}from"./deploy-context-C0iVbWRG.mjs";import{t as h}from"./auth-token-Cw4c0y89.mjs";import{n as g}from"./request-headers-CqfJOkpO.mjs";import{t as _}from"./output-Co4xdFf6.mjs";import{t as v}from"./dry-run-C2KjGX10.mjs";import{t as y}from"./progress-DaQ4MzBI.mjs";import{n as b,t as x}from"./run-Clc3P2u7.mjs";import"./telemetry-Bdv5LZZs.mjs";import{n as S,r as C,t as w}from"./body-parser-DkHKPkJ7.mjs";import{n as T}from"./input-validation-D7z60HJH.mjs";import{a as E,i as D,n as O}from"./prompt-KWYZvJWM.mjs";var k={method:`POST`,path:e=>n`/accounts/${e.account_id}/containers/applications`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,500:`InternalServerError`}};function oe(e){return e.usage('$0 containers applications create\n\nCreate a Containers application. Use `scheduling_policy: "default"` for a scheduler-backed application. The Containers scheduler maintains the requested instance count and manages deployment configuration, placement, scaling, versions, and rollouts. Use `scheduling_policy: "durable_object"` for a Durable Object-managed application. Each Durable Object creates and manages the lifecycle of its container instance. Supply `name`, `scheduling_policy`, and `durable_objects`, with optional `configuration` and optional top-level `observability` settings. Deployment configuration, scaling, constraints, versions, and rollouts do not apply.').option(`configuration-command`,{type:`string`,array:!0,description:`The command that runs when the container starts, passed to the entrypoint.
|
|
3
3
|
You can override this at run-time. If you override only the command,
|
|
4
4
|
it gets passed to the default entrypoint specified in the image.
|
|
5
5
|
`}).option(`configuration-entrypoint`,{type:`string`,array:!0,description:`The entry point for the container, specifying the executable to run when the container starts.
|
|
@@ -75,4 +75,4 @@ Generates credentials for accessing a configured container image registry.`).pos
|
|
|
75
75
|
Delete a registry from the account, this will prevent Containers from pulling images from the registry.`).positional(`domain`,{type:`string`,description:`The domain to delete.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Ne={command:`delete <domain>`,describe:`Delete a registry from the account`,builder:Me,handler:async e=>x({command:`containers registries delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await o();v({command:`cf containers registries delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/containers/registries/${e.domain==null?`<domain>`:encodeURIComponent(String(e.domain))}`,pathParams:{domain:String(e.domain??``)},bodyKind:`none`});return}let t=await a(e),n=e.local?i:await c();if(e.accountId=n,!await O({force:!!e.force,message:`This operation deletes the registry configuration. Containers will no longer be able to pull images from it.`})){process.stderr.write(`Aborted.
|
|
76
76
|
`);return}let r=await y(`Deleting`,async()=>t.send(je,{account_id:n,domain:e.domain}));_(r,{successLabel:`Deleted`})})};var Pe={method:`GET`,path:e=>n`/accounts/${e.account_id}/containers/registries`,errors:{401:`UnauthorizedError`,500:`InternalServerError`}};function Fe(e){return e.usage(`$0 containers registries list
|
|
77
77
|
|
|
78
|
-
Get the list of configured registries in the account.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Ie={command:`list`,describe:`Get the list of configured registries in the account`,builder:Fe,handler:async e=>x({command:`containers registries list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await o();v({command:`cf containers registries list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/containers/registries`,pathParams:{},bodyKind:`none`});return}let t=await a(e),n=e.local?i:await c();e.accountId=n;let r=await y(`Loading`,async()=>t.send(Pe,{account_id:n}));_(r,{successLabel:`Loaded`})})},Z={command:`registries`,describe:`Manage Containers image registries`,builder:e=>e.command(De).command(Ne).command(Ie).command(Ae).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function Le(e){return e.positional(`path`,{type:`string`,demandOption:!0,description:`Directory containing the Dockerfile to build`}).option(`tag`,{alias:`t`,type:`string`,demandOption:!0,description:`Name and optional tag for the built image`}).option(`push`,{alias:`p`,type:`boolean`,default:!1,description:`Push the built image to Cloudflare's managed registry`}).option(`path-to-docker`,{type:`string`,description:`Path to the Docker binary if it is not on PATH`})}var Re=b({command:`build <path>`,describe:`Build a Container image`,builder:Le,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers build`.");let n={compliance_region:t.push?await s():`public`},r=t.push?await h():``,i=m(r);u({logger:i.logger,fetchResult:i.fetchResult,fetchPagedListResult:i.fetchPagedListResult}),t.push&&d(await c(),r,e(n)),await ie({PATH:t.path,tag:t.tag,push:t.push,pathToDocker:t[`path-to-docker`]},n)}},{command:`containers build`,classification:{safeFlags:[`push`],shortFlagAliases:{p:{canonical:`push`,type:`boolean`},t:{canonical:`tag`,type:`value`}}}});function ze(e){return e.option(`tag`,{alias:`t`,type:`string`,demandOption:!0,description:`Tag of the local image to push`}).option(`path-to-docker`,{type:`string`,description:`Path to the Docker binary if it is not on PATH`})}var Be=b({command:`push`,describe:`Push a local image to the Cloudflare managed registry`,builder:ze,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers push`.");let n=await h(),r=await c(),i={compliance_region:await s()},a=m(n);u({logger:a.logger,fetchResult:a.fetchResult,fetchPagedListResult:a.fetchPagedListResult}),d(r,n,e(i)),await te({TAG:t.tag,pathToDocker:t[`path-to-docker`]},r,i)}},{command:`containers push`,classification:{safeFlags:[],shortFlagAliases:{t:{canonical:`tag`,type:`value`}}}});function Ve(e){return e.positional(`id`,{type:`string`,demandOption:!0,description:`ID of the container instance`}).positional(`ssh-command`,{type:`string`,array:!0,description:`Command and arguments to run in the container`}).options(re).middleware(e=>{l(e)&&(e.quiet=!0)},!0).parserConfiguration({"populate--":!0,"unknown-options-as-args":!0,"parse-positional-numbers":!1})}const Q={command:`ssh <id> [ssh-command..]`,describe:`SSH into a container`,builder:Ve,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers ssh`.");let n=await h(),r=await c(),i={compliance_region:await s()},a=m(n);u({logger:a.logger,fetchResult:a.fetchResult}),p.HEADERS=g(),d(r,n,e(i)),await ee({...t,id:t.id,command:[...t[`ssh-command`]??[],...Array.isArray(t[`--`])?t[`--`].map(String):[]]})}},$=b(Q,{command:`containers ssh`,recordArgs:!1});var He={...$,handler:async e=>{if(l(e)){let{markCommandReported:t}=await import(`./telemetry-
|
|
78
|
+
Get the list of configured registries in the account.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Ie={command:`list`,describe:`Get the list of configured registries in the account`,builder:Fe,handler:async e=>x({command:`containers registries list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await o();v({command:`cf containers registries list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/containers/registries`,pathParams:{},bodyKind:`none`});return}let t=await a(e),n=e.local?i:await c();e.accountId=n;let r=await y(`Loading`,async()=>t.send(Pe,{account_id:n}));_(r,{successLabel:`Loaded`})})},Z={command:`registries`,describe:`Manage Containers image registries`,builder:e=>e.command(De).command(Ne).command(Ie).command(Ae).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function Le(e){return e.positional(`path`,{type:`string`,demandOption:!0,description:`Directory containing the Dockerfile to build`}).option(`tag`,{alias:`t`,type:`string`,demandOption:!0,description:`Name and optional tag for the built image`}).option(`push`,{alias:`p`,type:`boolean`,default:!1,description:`Push the built image to Cloudflare's managed registry`}).option(`path-to-docker`,{type:`string`,description:`Path to the Docker binary if it is not on PATH`})}var Re=b({command:`build <path>`,describe:`Build a Container image`,builder:Le,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers build`.");let n={compliance_region:t.push?await s():`public`},r=t.push?await h():``,i=m(r);u({logger:i.logger,fetchResult:i.fetchResult,fetchPagedListResult:i.fetchPagedListResult}),t.push&&d(await c(),r,e(n)),await ie({PATH:t.path,tag:t.tag,push:t.push,pathToDocker:t[`path-to-docker`]},n)}},{command:`containers build`,classification:{safeFlags:[`push`],shortFlagAliases:{p:{canonical:`push`,type:`boolean`},t:{canonical:`tag`,type:`value`}}}});function ze(e){return e.option(`tag`,{alias:`t`,type:`string`,demandOption:!0,description:`Tag of the local image to push`}).option(`path-to-docker`,{type:`string`,description:`Path to the Docker binary if it is not on PATH`})}var Be=b({command:`push`,describe:`Push a local image to the Cloudflare managed registry`,builder:ze,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers push`.");let n=await h(),r=await c(),i={compliance_region:await s()},a=m(n);u({logger:a.logger,fetchResult:a.fetchResult,fetchPagedListResult:a.fetchPagedListResult}),d(r,n,e(i)),await te({TAG:t.tag,pathToDocker:t[`path-to-docker`]},r,i)}},{command:`containers push`,classification:{safeFlags:[],shortFlagAliases:{t:{canonical:`tag`,type:`value`}}}});function Ve(e){return e.positional(`id`,{type:`string`,demandOption:!0,description:`ID of the container instance`}).positional(`ssh-command`,{type:`string`,array:!0,description:`Command and arguments to run in the container`}).options(re).middleware(e=>{l(e)&&(e.quiet=!0)},!0).parserConfiguration({"populate--":!0,"unknown-options-as-args":!0,"parse-positional-numbers":!1})}const Q={command:`ssh <id> [ssh-command..]`,describe:`SSH into a container`,builder:Ve,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers ssh`.");let n=await h(),r=await c(),i={compliance_region:await s()},a=m(n);u({logger:a.logger,fetchResult:a.fetchResult}),p.HEADERS=g(),d(r,n,e(i)),await ee({...t,id:t.id,command:[...t[`ssh-command`]??[],...Array.isArray(t[`--`])?t[`--`].map(String):[]]})}},$=b(Q,{command:`containers ssh`,recordArgs:!1});var He={...$,handler:async e=>{if(l(e)){let{markCommandReported:t}=await import(`./telemetry-DYjsavEr.mjs`);return t(),Q.handler(e)}return $.handler(e)}};const Ue={command:`containers`,describe:`Deploy and manage Containers applications on Cloudflare's global network`,builder:e=>e.command(r(Re,`preview`)).command(r(Be,`preview`)).command(r(He,`preview`)).command(ve).command(Te).command(Z).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{Ue as default};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{i as e,n as t,t as n}from"./source-mXUcrTVw.mjs";import{a as r}from"./dotenv-usOKkeW7.mjs";import{B as i,C as a,F as o,G as s,I as c,P as l,Q as u,S as d,T as f,U as p,V as m,W as h,Y as g,Z as _,b as v,f as y,it as b,k as x,n as S,o as ee,p as te,r as C,rt as w,u as T,x as ne,y as E}from"./dist-DZRTPMMA.mjs";import{D as re,M as D,N as O,O as ie,S as ae,T as k,_ as oe,a as se,d as ce,g as A,h as le,i as ue,j as de,l as fe,m as pe,n as me,p as he,r as ge,s as _e,t as ve,v as ye,w as be,y as xe}from"./chunk-2HLTAS5V-D7COzUOd.mjs";import{a as Se,c as Ce,i as we,o as j,r as Te,s as Ee,t as De}from"./chunk-DSGVRFIS-C5SqiTOz.mjs";import{C as Oe,D as ke,O as Ae,S as je,T as Me,a as Ne,d as Pe,f as Fe,k as Ie,m as Le,o as Re,r as ze,s as Be,u as Ve,v as He,w as Ue,x as We,y as Ge}from"./interactive-BW9T1D1q.mjs";import{C as Ke,D as qe,_ as Je,a as Ye,c as Xe,g as Ze,i as Qe,m as $e,n as et,o as tt,r as nt,w as rt,x as it,y as at}from"./deploy-context-ClvBD87y.mjs";import{s as ot}from"./build-sBpqm9ga.mjs";import{createRequire as st}from"node:module";import{setTimeout as ct}from"node:timers/promises";import{createReadStream as lt,mkdirSync as ut,readFileSync as dt,writeFileSync as ft}from"node:fs";import*as pt from"node:path";import mt,{extname as ht,isAbsolute as gt,resolve as _t,sep as vt}from"node:path";import yt,{URLSearchParams as bt}from"node:url";import{access as xt,readFile as St,readdir as Ct,stat as wt,writeFile as Tt}from"node:fs/promises";import M from"node:assert";import{isDeepStrictEqual as Et}from"node:util";import{Blob as Dt}from"node:buffer";import{gzipSync as Ot}from"node:zlib";import{createHash as kt}from"node:crypto";import{execSync as At}from"node:child_process";import{getFreshSourceMapSupport as jt,getNodeCompat as Mt}from"miniflare";import Nt from"node:readline";import{hash as Pt}from"blake3-wasm";import{convertToWranglerConfig as Ft}from"@cloudflare/config";st(import.meta.url||(typeof __filename==`string`?__filename:`/`));var N,P,It,Lt,Rt,zt,Bt,F=o();function Vt(e){F=o(e.cliPresentation),N=e.logger,P=e.fetchResult,It=e.fetchListResult,Lt=e.fetchPagedListResult,e.fetchKVGetValue,Rt=e.confirm,zt=e.prompt,Bt=e.select}j(Vt,`initDeployHelpersContext`);var Ht=/* @__PURE__ */ t(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=`~`;function i(){}Object.create&&(i.prototype=Object.create(null),new i().__proto__||(r=!1));function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function o(e,t,n,i,o){if(typeof n!=`function`)throw TypeError(`The listener must be a function`);var s=new a(n,i||e,o),c=r?r+t:t;return e._events[c]?e._events[c].fn?e._events[c]=[e._events[c],s]:e._events[c].push(s):(e._events[c]=s,e._eventsCount++),e}function s(e,t){--e._eventsCount===0?e._events=new i:delete e._events[t]}function c(){this._events=new i,this._eventsCount=0}c.prototype.eventNames=function(){var e=[],t,i;if(this._eventsCount===0)return e;for(i in t=this._events)n.call(t,i)&&e.push(r?i.slice(1):i);return Object.getOwnPropertySymbols?e.concat(Object.getOwnPropertySymbols(t)):e},c.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,a=n.length,o=Array(a);i<a;i++)o[i]=n[i].fn;return o},c.prototype.listenerCount=function(e){var t=r?r+e:e,n=this._events[t];return n?n.fn?1:n.length:0},c.prototype.emit=function(e,t,n,i,a,o){var s=r?r+e:e;if(!this._events[s])return!1;var c=this._events[s],l=arguments.length,u,d;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),l){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,i),!0;case 5:return c.fn.call(c.context,t,n,i,a),!0;case 6:return c.fn.call(c.context,t,n,i,a,o),!0}for(d=1,u=Array(l-1);d<l;d++)u[d-1]=arguments[d];c.fn.apply(c.context,u)}else{var f=c.length,p;for(d=0;d<f;d++)switch(c[d].once&&this.removeListener(e,c[d].fn,void 0,!0),l){case 1:c[d].fn.call(c[d].context);break;case 2:c[d].fn.call(c[d].context,t);break;case 3:c[d].fn.call(c[d].context,t,n);break;case 4:c[d].fn.call(c[d].context,t,n,i);break;default:if(!u)for(p=1,u=Array(l-1);p<l;p++)u[p-1]=arguments[p];c[d].fn.apply(c[d].context,u)}}return!0},c.prototype.on=function(e,t,n){return o(this,e,t,n,!1)},c.prototype.once=function(e,t,n){return o(this,e,t,n,!0)},c.prototype.removeListener=function(e,t,n,i){var a=r?r+e:e;if(!this._events[a])return this;if(!t)return s(this,a),this;var o=this._events[a];if(o.fn)o.fn===t&&(!i||o.once)&&(!n||o.context===n)&&s(this,a);else{for(var c=0,l=[],u=o.length;c<u;c++)(o[c].fn!==t||i&&!o[c].once||n&&o[c].context!==n)&&l.push(o[c]);l.length?this._events[a]=l.length===1?l[0]:l:s(this,a)}return this},c.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&s(this,t)):(this._events=new i,this._eventsCount=0),this},c.prototype.off=c.prototype.removeListener,c.prototype.addListener=c.prototype.on,c.prefixed=r,c.EventEmitter=c,t!==void 0&&(t.exports=c)})),Ut=m(),Wt=/* @__PURE__ */ e(Ht(),1),Gt=class e extends Error{name=`TimeoutError`;constructor(t,n){super(t,n),Error.captureStackTrace?.(this,e)}};const Kt=e=>e.reason??new DOMException(`This operation was aborted.`,`AbortError`);function qt(e,t){let{milliseconds:n,fallback:r,message:i,customTimers:a={setTimeout,clearTimeout},signal:o}=t,s,c,l=new Promise((t,l)=>{if(typeof n!=`number`||Math.sign(n)!==1)throw TypeError(`Expected \`milliseconds\` to be a positive number, got \`${n}\``);if(o?.aborted){l(Kt(o));return}if(o&&(c=()=>{l(Kt(o))},o.addEventListener(`abort`,c,{once:!0})),e.then(t,l),n===1/0)return;let u=new Gt;s=a.setTimeout.call(void 0,()=>{if(r){try{t(r())}catch(e){l(e)}return}typeof e.cancel==`function`&&e.cancel(),i===!1?t():i instanceof Error?l(i):(u.message=i??`Promise timed out after ${n} milliseconds`,l(u))},n)}).finally(()=>{l.clear(),c&&o&&o.removeEventListener(`abort`,c)});return l.clear=()=>{a.clearTimeout.call(void 0,s),s=void 0},l}function Jt(e,t,n){let r=0,i=e.length;for(;i>0;){let a=Math.trunc(i/2),o=r+a;n(e[o],t)<=0?(r=++o,i-=a+1):i=a}return r}var Yt=class{#e=[];enqueue(e,t){let{priority:n=0,id:r}=t??{},i={priority:n,id:r,run:e};if(this.size===0||this.#e[this.size-1].priority>=n){this.#e.push(i);return}let a=Jt(this.#e,i,(e,t)=>t.priority-e.priority);this.#e.splice(a,0,i)}setPriority(e,t){let n=this.#e.findIndex(t=>t.id===e);if(n===-1)throw ReferenceError(`No promise function with the id "${e}" exists in the queue.`);let[r]=this.#e.splice(n,1);this.enqueue(r.run,{priority:t,id:e})}dequeue(){return this.#e.shift()?.run}filter(e){return this.#e.filter(t=>t.priority===e.priority).map(e=>e.run)}get size(){return this.#e.length}},Xt=class extends Wt.default{#e;#t;#n=0;#r;#i=!1;#a=!1;#o;#s=0;#c=0;#l;#u;#d;#f;#p=0;#m;#h;#g=1n;#_=/* @__PURE__ */ new Map;timeout;constructor(e){if(super(),e={carryoverIntervalCount:!1,intervalCap:1/0,interval:0,concurrency:1/0,autoStart:!0,queueClass:Yt,...e},!(typeof e.intervalCap==`number`&&e.intervalCap>=1))throw TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${e.intervalCap?.toString()??``}\` (${typeof e.intervalCap})`);if(e.interval===void 0||!(Number.isFinite(e.interval)&&e.interval>=0))throw TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval?.toString()??``}\` (${typeof e.interval})`);if(this.#e=e.carryoverIntervalCount??e.carryoverConcurrencyCount??!1,this.#t=e.intervalCap===1/0||e.interval===0,this.#r=e.intervalCap,this.#o=e.interval,this.#d=new e.queueClass,this.#f=e.queueClass,this.concurrency=e.concurrency,e.timeout!==void 0&&!(Number.isFinite(e.timeout)&&e.timeout>0))throw TypeError(`Expected \`timeout\` to be a positive finite number, got \`${e.timeout}\` (${typeof e.timeout})`);this.timeout=e.timeout,this.#h=e.autoStart===!1,this.#M()}get#v(){return this.#t||this.#n<this.#r}get#y(){return this.#p<this.#m}#b(){this.#p--,this.#p===0&&this.emit(`pendingZero`),this.#E(),this.emit(`next`)}#x(){this.#O(),this.#D(),this.#u=void 0}get#S(){let e=Date.now();if(this.#l===void 0){let t=this.#s-e;if(t<0){if(this.#c>0){let t=e-this.#c;if(t<this.#o)return this.#C(this.#o-t),!0}this.#n=this.#e?this.#p:0}else return this.#C(t),!0}return!1}#C(e){this.#u===void 0&&(this.#u=setTimeout(()=>{this.#x()},e))}#w(){this.#l&&=(clearInterval(this.#l),void 0)}#T(){this.#u&&=(clearTimeout(this.#u),void 0)}#E(){if(this.#d.size===0)return this.#w(),this.emit(`empty`),this.#p===0&&(this.#T(),this.emit(`idle`)),!1;let e=!1;if(!this.#h){let t=!this.#S;if(this.#v&&this.#y){let n=this.#d.dequeue();this.#t||(this.#n++,this.#N()),this.emit(`active`),this.#c=Date.now(),n(),t&&this.#D(),e=!0}}return e}#D(){this.#t||this.#l!==void 0||(this.#l=setInterval(()=>{this.#O()},this.#o),this.#s=Date.now()+this.#o)}#O(){this.#n===0&&this.#p===0&&this.#l&&this.#w(),this.#n=this.#e?this.#p:0,this.#k(),this.#N()}#k(){for(;this.#E(););}get concurrency(){return this.#m}set concurrency(e){if(!(typeof e==`number`&&e>=1))throw TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this.#m=e,this.#k()}async#A(e){return new Promise((t,n)=>{e.addEventListener(`abort`,()=>{n(e.reason)},{once:!0})})}setPriority(e,t){if(typeof t!=`number`||!Number.isFinite(t))throw TypeError(`Expected \`priority\` to be a finite number, got \`${t}\` (${typeof t})`);this.#d.setPriority(e,t)}async add(e,t={}){return t.id??=(this.#g++).toString(),t={timeout:this.timeout,...t},new Promise((n,r)=>{let i=Symbol(`task-${t.id}`);this.#d.enqueue(async()=>{this.#p++,this.#_.set(i,{id:t.id,priority:t.priority??0,startTime:Date.now(),timeout:t.timeout});try{try{t.signal?.throwIfAborted()}catch(e){throw this.#t||this.#n--,this.#_.delete(i),e}let r=e({signal:t.signal});t.timeout&&(r=qt(Promise.resolve(r),{milliseconds:t.timeout,message:`Task timed out after ${t.timeout}ms (queue has ${this.#p} running, ${this.#d.size} waiting)`})),t.signal&&(r=Promise.race([r,this.#A(t.signal)]));let a=await r;n(a),this.emit(`completed`,a)}catch(e){r(e),this.emit(`error`,e)}finally{this.#_.delete(i),queueMicrotask(()=>{this.#b()})}},t),this.emit(`add`),this.#E()})}async addAll(e,t){return Promise.all(e.map(async e=>this.add(e,t)))}start(){return this.#h?(this.#h=!1,this.#k(),this):this}pause(){this.#h=!0}clear(){this.#d=new this.#f,this.#P()}async onEmpty(){this.#d.size!==0&&await this.#j(`empty`)}async onSizeLessThan(e){this.#d.size<e||await this.#j(`next`,()=>this.#d.size<e)}async onIdle(){(this.#p!==0||this.#d.size!==0)&&await this.#j(`idle`)}async onPendingZero(){this.#p!==0&&await this.#j(`pendingZero`)}async onRateLimit(){this.isRateLimited||await this.#j(`rateLimit`)}async onRateLimitCleared(){this.isRateLimited&&await this.#j(`rateLimitCleared`)}async onError(){return new Promise((e,t)=>{let n=e=>{this.off(`error`,n),t(e)};this.on(`error`,n)})}async#j(e,t){return new Promise(n=>{let r=()=>{(!t||t())&&(this.off(e,r),n())};this.on(e,r)})}get size(){return this.#d.size}sizeBy(e){return this.#d.filter(e).length}get pending(){return this.#p}get isPaused(){return this.#h}#M(){this.#t||(this.on(`add`,()=>{this.#d.size>0&&this.#N()}),this.on(`next`,()=>{this.#N()}))}#N(){this.#t||this.#a||(this.#a=!0,queueMicrotask(()=>{this.#a=!1,this.#P()}))}#P(){let e=this.#i,t=!this.#t&&this.#n>=this.#r&&this.#d.size>0;t!==e&&(this.#i=t,this.emit(t?`rateLimit`:`rateLimitCleared`))}get isRateLimited(){return this.#i}get isSaturated(){return this.#p===this.#m&&this.#d.size>0||this.isRateLimited&&this.#d.size>0}get runningTasks(){return[...this.#_.values()].map(e=>({...e}))}};const Zt=[`B`,`kB`,`MB`,`GB`,`TB`,`PB`,`EB`,`ZB`,`YB`],Qt=[`B`,`KiB`,`MiB`,`GiB`,`TiB`,`PiB`,`EiB`,`ZiB`,`YiB`],$t=[`b`,`kbit`,`Mbit`,`Gbit`,`Tbit`,`Pbit`,`Ebit`,`Zbit`,`Ybit`],en=[`b`,`kibit`,`Mibit`,`Gibit`,`Tibit`,`Pibit`,`Eibit`,`Zibit`,`Yibit`],tn=(e,t,n)=>{let r=e;return typeof t==`string`||Array.isArray(t)?r=e.toLocaleString(t,n):(t===!0||n!==void 0)&&(r=e.toLocaleString(void 0,n)),r};function nn(e,t){if(!Number.isFinite(e))throw TypeError(`Expected a finite number, got ${typeof e}: ${e}`);t={bits:!1,binary:!1,space:!0,...t};let n=t.bits?t.binary?en:$t:t.binary?Qt:Zt,r=t.space?` `:``;if(t.signed&&e===0)return` 0${r}${n[0]}`;let i=e<0,a=i?`-`:t.signed?`+`:``;i&&(e=-e);let o;if(t.minimumFractionDigits!==void 0&&(o={minimumFractionDigits:t.minimumFractionDigits}),t.maximumFractionDigits!==void 0&&(o={maximumFractionDigits:t.maximumFractionDigits,...o}),e<1)return a+tn(e,t.locale,o)+r+n[0];let s=Math.min(Math.floor(t.binary?Math.log(e)/Math.log(1024):Math.log10(e)/3),n.length-1);e/=(t.binary?1024:1e3)**s,o||(e=e.toPrecision(3));let c=tn(Number(e),t.locale,o),l=n[s];return a+c+r+l}var rn=r();st(import.meta.url||(typeof __filename==`string`?__filename:`/`));var an=we({"../../node_modules/.pnpm/ignore@5.3.1/node_modules/ignore/index.js"(e,t){function n(e){return Array.isArray(e)?e:[e]}j(n,`makeArray`);var r=``,i=` `,a=`\\`,o=/^\s+$/,s=/(?:[^\\]|^)\\$/,c=/^\\!/,l=/^\\#/,u=/\r?\n/g,d=/^\.*\/|^\.+$/,f=`/`,p=`node-ignore`;typeof Symbol<`u`&&(p=Symbol.for(`node-ignore`));var m=p,h=/* @__PURE__ */ j((e,t,n)=>Object.defineProperty(e,t,{value:n}),`define`),g=/([0-z])-([0-z])/g,_=/* @__PURE__ */ j(()=>!1,`RETURN_FALSE`),v=/* @__PURE__ */ j(e=>e.replace(g,(e,t,n)=>t.charCodeAt(0)<=n.charCodeAt(0)?e:r),`sanitizeRange`),y=/* @__PURE__ */ j(e=>{let{length:t}=e;return e.slice(0,t-t%2)},`cleanRangeBackSlash`),b=[[/^\uFEFF/,()=>r],[/\\?\s+$/,e=>e.indexOf(`\\`)===0?i:r],[/\\\s/g,()=>i],[/[\\$.|*+(){^]/g,e=>`\\${e}`],[/(?!\\)\?/g,()=>`[^/]`],[/^\//,()=>`^`],[/\//g,()=>`\\/`],[/^\^*\\\*\\\*\\\//,()=>`^(?:.*\\/)?`],[/^(?=[^^])/,/* @__PURE__ */ j(function(){return/\/(?!$)/.test(this)?`^`:`(?:^|\\/)`},`startingReplacer`)],[/\\\/\\\*\\\*(?=\\\/|$)/g,(e,t,n)=>t+6<n.length?`(?:\\/[^\\/]+)*`:`\\/.+`],[/(^|[^\\]+)(\\\*)+(?=.+)/g,(e,t,n)=>t+n.replace(/\\\*/g,`[^\\/]*`)],[/\\\\\\(?=[$.|*+(){^])/g,()=>a],[/\\\\/g,()=>a],[/(\\)?\[([^\]/]*?)(\\*)($|\])/g,(e,t,n,r,i)=>t===a?`\\[${n}${y(r)}${i}`:i===`]`&&r.length%2==0?`[${v(n)}${r}]`:`[]`],[/(?:[^*])$/,e=>/\/$/.test(e)?`${e}$`:`${e}(?=$|\\/$)`],[/(\^|\\\/)?\\\*$/,(e,t)=>`${t?`${t}[^/]+`:`[^/]*`}(?=$|\\/$)`]],x=/* @__PURE__ */ Object.create(null),S=/* @__PURE__ */ j((e,t)=>{let n=x[e];return n||(n=b.reduce((t,n)=>t.replace(n[0],n[1].bind(e)),e),x[e]=n),t?new RegExp(n,`i`):new RegExp(n)},`makeRegex`),ee=/* @__PURE__ */ j(e=>typeof e==`string`,`isString`),te=/* @__PURE__ */ j(e=>e&&ee(e)&&!o.test(e)&&!s.test(e)&&e.indexOf(`#`)!==0,`checkPattern`),C=/* @__PURE__ */ j(e=>e.split(u),`splitPattern`),w=class{static{j(this,`IgnoreRule`)}constructor(e,t,n,r){this.origin=e,this.pattern=t,this.negative=n,this.regex=r}},T=/* @__PURE__ */ j((e,t)=>{let n=e,r=!1;e.indexOf(`!`)===0&&(r=!0,e=e.substr(1)),e=e.replace(c,`!`).replace(l,`#`);let i=S(e,t);return new w(n,e,r,i)},`createRule`),ne=/* @__PURE__ */ j((e,t)=>{throw new t(e)},`throwError`),E=/* @__PURE__ */ j((e,t,n)=>ee(e)?e?!E.isNotRelative(e)||n(`path should be a \`path.relative()\`d string, but got "${t}"`,RangeError):n(`path must not be empty`,TypeError):n(`path must be a string, but got \`${t}\``,TypeError),`checkPath`),re=/* @__PURE__ */ j(e=>d.test(e),`isNotRelative`);E.isNotRelative=re,E.convert=e=>e;var D=class{static{j(this,`Ignore`)}constructor({ignorecase:e=!0,ignoreCase:t=e,allowRelativePaths:n=!1}={}){h(this,m,!0),this._rules=[],this._ignoreCase=t,this._allowRelativePaths=n,this._initCache()}_initCache(){this._ignoreCache=/* @__PURE__ */ Object.create(null),this._testCache=/* @__PURE__ */ Object.create(null)}_addPattern(e){if(e&&e[m]){this._rules=this._rules.concat(e._rules),this._added=!0;return}if(te(e)){let t=T(e,this._ignoreCase);this._added=!0,this._rules.push(t)}}add(e){return this._added=!1,n(ee(e)?C(e):e).forEach(this._addPattern,this),this._added&&this._initCache(),this}addPattern(e){return this.add(e)}_testOne(e,t){let n=!1,r=!1;return this._rules.forEach(i=>{let{negative:a}=i;r===a&&n!==r||a&&!n&&!r&&!t||i.regex.test(e)&&(n=!a,r=a)}),{ignored:n,unignored:r}}_test(e,t,n,r){let i=e&&E.convert(e);return E(i,e,this._allowRelativePaths?_:ne),this._t(i,t,n,r)}_t(e,t,n,r){if(e in t)return t[e];if(r||=e.split(f),r.pop(),!r.length)return t[e]=this._testOne(e,n);let i=this._t(r.join(f)+f,t,n,r);return t[e]=i.ignored?i:this._testOne(e,n)}ignores(e){return this._test(e,this._ignoreCache,!1).ignored}createFilter(){return e=>!this.ignores(e)}filter(e){return n(e).filter(this.createFilter())}test(e){return this._test(e,this._testCache,!0)}},O=/* @__PURE__ */ j(e=>new D(e),`factory`);if(O.isPathValid=/* @__PURE__ */ j(e=>E(e&&E.convert(e),e,_),`isPathValid`),O.default=O,t.exports=O,typeof process<`u`&&(process.env&&process.env.IGNORE_TEST_WIN32||process.platform===`win32`)){E.convert=/* @__PURE__ */ j(e=>/^\\\\\?\\/.test(e)||/["<>|\u0000-\u001F]+/u.test(e)?e:e.replace(/\\/g,`/`),`makePosix`);let e=/^[a-z]:\//i;E.isNotRelative=t=>e.test(t)||re(t)}}}),on=we({"../../node_modules/.pnpm/heap@0.2.7/node_modules/heap/lib/heap.js"(e,t){(function(){var n,r,i=Math.floor,a,o,s,c,l,u,d=Math.min,f,p,m,h,g;r=/* @__PURE__ */ j(function(e,t){return e<t?-1:+(e>t)},`defaultCmp`),u=/* @__PURE__ */ j(function(e,t,n,a,o){var s;if(n??=0,o??=r,n<0)throw Error(`lo must be non-negative`);for(a??=e.length;n<a;)s=i((n+a)/2),o(t,e[s])<0?a=s:n=s+1;return[].splice.apply(e,[n,n-n].concat(t)),t},`insort`),s=/* @__PURE__ */ j(function(e,t,n){return n??=r,e.push(t),h(e,0,e.length-1,n)},`heappush`),o=/* @__PURE__ */ j(function(e,t){var n,i;return t??=r,n=e.pop(),e.length?(i=e[0],e[0]=n,g(e,0,t)):i=n,i},`heappop`),l=/* @__PURE__ */ j(function(e,t,n){var i;return n??=r,i=e[0],e[0]=t,g(e,0,n),i},`heapreplace`),c=/* @__PURE__ */ j(function(e,t,n){var i;return n??=r,e.length&&n(e[0],t)<0&&(i=[e[0],t],t=i[0],e[0]=i[1],g(e,0,n)),t},`heappushpop`),a=/* @__PURE__ */ j(function(e,t){var n,a,o,s,c,l;for(t??=r,s=function(){l=[];for(var t=0,n=i(e.length/2);0<=n?t<n:t>n;0<=n?t++:t--)l.push(t);return l}.apply(this).reverse(),c=[],a=0,o=s.length;a<o;a++)n=s[a],c.push(g(e,n,t));return c},`heapify`),m=/* @__PURE__ */ j(function(e,t,n){var i;if(n??=r,i=e.indexOf(t),i!==-1)return h(e,0,i,n),g(e,i,n)},`updateItem`),f=/* @__PURE__ */ j(function(e,t,n){var i,o,s,l,u;if(n??=r,o=e.slice(0,t),!o.length)return o;for(a(o,n),u=e.slice(t),s=0,l=u.length;s<l;s++)i=u[s],c(o,i,n);return o.sort(n).reverse()},`nlargest`),p=/* @__PURE__ */ j(function(e,t,n){var i,s,c,l,f,p,m,h,g;if(n??=r,t*10<=e.length){if(c=e.slice(0,t).sort(n),!c.length)return c;for(s=c[c.length-1],m=e.slice(t),l=0,p=m.length;l<p;l++)i=m[l],n(i,s)<0&&(u(c,i,0,null,n),c.pop(),s=c[c.length-1]);return c}for(a(e,n),g=[],f=0,h=d(t,e.length);0<=h?f<h:f>h;0<=h?++f:--f)g.push(o(e,n));return g},`nsmallest`),h=/* @__PURE__ */ j(function(e,t,n,i){var a,o,s;for(i??=r,a=e[n];n>t;){if(s=n-1>>1,o=e[s],i(a,o)<0){e[n]=o,n=s;continue}break}return e[n]=a},`_siftdown`),g=/* @__PURE__ */ j(function(e,t,n){var i,a,o,s,c;for(n??=r,a=e.length,c=t,o=e[t],i=2*t+1;i<a;)s=i+1,s<a&&!(n(e[i],e[s])<0)&&(i=s),e[t]=e[i],t=i,i=2*t+1;return e[t]=o,h(e,c,t,n)},`_siftup`),n=function(){e.push=s,e.pop=o,e.replace=l,e.pushpop=c,e.heapify=a,e.updateItem=m,e.nlargest=f,e.nsmallest=p;function e(e){this.cmp=e??r,this.nodes=[]}return j(e,`Heap`),e.prototype.push=function(e){return s(this.nodes,e,this.cmp)},e.prototype.pop=function(){return o(this.nodes,this.cmp)},e.prototype.peek=function(){return this.nodes[0]},e.prototype.contains=function(e){return this.nodes.indexOf(e)!==-1},e.prototype.replace=function(e){return l(this.nodes,e,this.cmp)},e.prototype.pushpop=function(e){return c(this.nodes,e,this.cmp)},e.prototype.heapify=function(){return a(this.nodes,this.cmp)},e.prototype.updateItem=function(e){return m(this.nodes,e,this.cmp)},e.prototype.clear=function(){return this.nodes=[]},e.prototype.empty=function(){return this.nodes.length===0},e.prototype.size=function(){return this.nodes.length},e.prototype.clone=function(){var t=new e;return t.nodes=this.nodes.slice(0),t},e.prototype.toArray=function(){return this.nodes.slice(0)},e.prototype.insert=e.prototype.push,e.prototype.top=e.prototype.peek,e.prototype.front=e.prototype.peek,e.prototype.has=e.prototype.contains,e.prototype.copy=e.prototype.clone,e}(),(function(n,r){return typeof define==`function`&&define.amd?define([],r):typeof e==`object`?t.exports=r():n.Heap=r()})(this,function(){return n})}).call(e)}}),sn=we({"../../node_modules/.pnpm/heap@0.2.7/node_modules/heap/index.js"(e,t){t.exports=on()}}),cn=we({"../../node_modules/.pnpm/@ewoudenberg+difflib@0.1.0/node_modules/@ewoudenberg/difflib/lib/difflib.js"(e){(function(){var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=[].indexOf;({floor:h,max:_,min:v}=Math),n=sn(),p=Ee(`assert`),c=/* @__PURE__ */ j(function(e,t){return t?2*e/t:1},`_calculateRatio`),s=/* @__PURE__ */ j(function(e,t){var n,r,i,a,o;for([i,a]=[e.length,t.length],n=r=0,o=v(i,a);0<=o?r<o:r>o;n=0<=o?++r:--r){if(e[n]<t[n])return-1;if(e[n]>t[n])return 1}return i-a},`_arrayCmp`),f=/* @__PURE__ */ j(function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},`_has`),o=/* @__PURE__ */ j(function(e){for(var t,n=0,r=e.length;n<r;n++)if(t=e[n],t)return!0;return!1},`_any`),a=class{static{j(this,`SequenceMatcher`)}constructor(e,t=``,n=``,r=!0){this.isjunk=e,this.autojunk=r,this.a=this.b=null,this.setSeqs(t,n)}setSeqs(e,t){return this.setSeq1(e),this.setSeq2(t)}setSeq1(e){if(e!==this.a)return this.a=e,this.matchingBlocks=this.opcodes=null}setSeq2(e){if(e!==this.b)return this.b=e,this.matchingBlocks=this.opcodes=null,this.fullbcount=null,this._chainB()}_chainB(){var e=this.b,t,n,r,i,a,o,s,c,l,u,d;for(this.b2j=t=/* @__PURE__ */ new Map,r=s=0,c=e.length;s<c;r=++s)n=e[r],t.has(n)||t.set(n,[]),i=t.get(n),i.push(r);return o=/* @__PURE__ */ new Map,a=this.isjunk,a&&t.forEach(function(e,n){if(a(n))return o.set(n,!0),t.delete(n)}),d=/* @__PURE__ */ new Map,l=e.length,this.autojunk&&l>=200&&(u=h(l/100)+1,t.forEach(function(e,n){if(e.length>u)return d.set(n,!0),t.delete(n)})),this.isbjunk=function(e){return o.has(e)},this.isbpopular=function(e){return d.has(e)}}findLongestMatch(e,t,n,r){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x;for([i,a,o,d]=[this.a,this.b,this.b2j,this.isbjunk],[s,c,l]=[e,n,0],p={},u=g=b=e,x=t;b<=x?g<x:g>x;u=b<=x?++g:--g){for(y={},m=[],o.has(i[u])&&(m=o.get(i[u])),v=0,_=m.length;v<_;v++)if(f=m[v],!(f<n)){if(f>=r)break;h=y[f]=(p[f-1]||0)+1,h>l&&([s,c,l]=[u-h+1,f-h+1,h])}p=y}for(;s>e&&c>n&&!d(a[c-1])&&i[s-1]===a[c-1];)[s,c,l]=[s-1,c-1,l+1];for(;s+l<t&&c+l<r&&!d(a[c+l])&&i[s+l]===a[c+l];)l++;for(;s>e&&c>n&&d(a[c-1])&&i[s-1]===a[c-1];)[s,c,l]=[s-1,c-1,l+1];for(;s+l<t&&c+l<r&&d(a[c+l])&&i[s+l]===a[c+l];)l++;return[s,c,l]}getMatchingBlocks(){var e,t,n,r,i,a,o,c,l,u,d,f,p,m,h,g,_,v,y,b,x;if(this.matchingBlocks)return this.matchingBlocks;for([h,g]=[this.a.length,this.b.length],b=[[0,h,0,g]],v=[];b.length;)[t,e,r,n]=b.pop(),[i,c,d]=x=this.findLongestMatch(t,e,r,n),d&&(v.push(x),t<i&&r<c&&b.push([t,i,r,c]),i+d<e&&c+d<n&&b.push([i+d,e,c+d,n]));for(v.sort(s),a=l=f=0,y=[],m=0,_=v.length;m<_;m++)[o,u,p]=v[m],a+f===o&&l+f===u?f+=p:(f&&y.push([a,l,f]),[a,l,f]=[o,u,p]);return f&&y.push([a,l,f]),y.push([h,g,0]),this.matchingBlocks=y}getOpcodes(){var e,t,n,r,i,a,o,s,c,l;if(this.opcodes)return this.opcodes;for(r=i=0,this.opcodes=t=[],s=this.getMatchingBlocks(),a=0,o=s.length;a<o;a++)[e,n,c]=s[a],l=``,r<e&&i<n?l=`replace`:r<e?l=`delete`:i<n&&(l=`insert`),l&&t.push([l,r,e,i,n]),[r,i]=[e+c,n+c],c&&t.push([`equal`,e,r,n,i]);return t}getGroupedOpcodes(e=3){var t=this.getOpcodes(),n,r,i,a,o,s,c,l,u,d;for(t.length||(t=[[`equal`,0,1,0,1]]),t[0][0]===`equal`&&([d,i,a,o,s]=t[0],t[0]=[d,_(i,a-e),a,_(o,s-e),s]),t[t.length-1][0]===`equal`&&([d,i,a,o,s]=t[t.length-1],t[t.length-1]=[d,i,v(a,i+e),o,v(s,o+e)]),u=e+e,r=[],n=[],c=0,l=t.length;c<l;c++)[d,i,a,o,s]=t[c],d===`equal`&&a-i>u&&(n.push([d,i,v(a,i+e),o,v(s,o+e)]),r.push(n),n=[],[i,o]=[_(i,a-e),_(o,s-e)]),n.push([d,i,a,o,s]);return n.length&&(n.length!==1||n[0][0]!==`equal`)&&r.push(n),r}ratio(){var e,t,n,r=0,i=this.getMatchingBlocks();for(e=0,t=i.length;e<t;e++)n=i[e],r+=n[2];return c(r,this.a.length+this.b.length)}quickRatio(){var e,t,n,r,i,a,o,s,l,u,d;if(!this.fullbcount)for(this.fullbcount=n={},u=this.b,r=0,i=u.length;r<i;r++)t=u[r],n[t]=(n[t]||0)+1;for(n=this.fullbcount,e={},s=0,d=this.a,o=0,a=d.length;o<a;o++)t=d[o],l=f(e,t)?e[t]:n[t]||0,e[t]=l-1,l>0&&s++;return c(s,this.a.length+this.b.length)}realQuickRatio(){var e,t;return[e,t]=[this.a.length,this.b.length],c(v(e,t),e+t)}},g=/* @__PURE__ */ j(function(e,t,r=3,i=.6){var o,c,l,u,d,f,p,m,h;if(!(r>0))throw Error(`n must be > 0: (${r})`);if(!(0<=i&&i<=1))throw Error(`cutoff must be in [0.0, 1.0]: (${i})`);for(d=[],p=new a,p.setSeq2(e),o=0,c=t.length;o<c;o++)h=t[o],p.setSeq1(h),p.realQuickRatio()>=i&&p.quickRatio()>=i&&p.ratio()>=i&&d.push([p.ratio(),h]);for(d=n.nlargest(d,r,s),f=[],u=0,l=d.length;u<l;u++)[m,h]=d[u],f.push(h);return f},`getCloseMatches`),l=/* @__PURE__ */ j(function(e,t){var n,r;for([n,r]=[0,e.length];n<r&&e[n]===t;)n++;return n},`_countLeading`),t=class{static{j(this,`Differ`)}constructor(e,t){this.linejunk=e,this.charjunk=t}compare(e,t){var n,r,i,o,s=new a(this.linejunk,e,t),c,l,u,d,f,p=[],m,h=s.getOpcodes(),g;for(l=0,u=h.length;l<u;l++){switch([g,r,n,o,i]=h[l],g){case`replace`:c=this._fancyReplace(e,r,n,t,o,i);break;case`delete`:c=this._dump(`-`,e,r,n);break;case`insert`:c=this._dump(`+`,t,o,i);break;case`equal`:c=this._dump(` `,e,r,n);break;default:throw Error(`unknow tag (${g})`)}for(m=0,d=c.length;m<d;m++)f=c[m],p.push(f)}return p}_dump(e,t,n,r){var i,a,o,s,c=[];for(i=a=o=n,s=r;o<=s?a<s:a>s;i=o<=s?++a:--a)c.push(`${e} ${t[i]}`);return c}_plainReplace(e,t,n,r,i,a){var o,s,c,l,u,d,f,m,h,g;for(p(t<n&&i<a),a-i<n-t?(o=this._dump(`+`,r,i,a),g=this._dump(`-`,e,t,n)):(o=this._dump(`-`,e,t,n),g=this._dump(`+`,r,i,a)),f=[],h=[o,g],c=0,l=h.length;c<l;c++)for(s=h[c],m=0,u=s.length;m<u;m++)d=s[m],f.push(d);return f}_fancyReplace(e,t,n,r,i,o){var s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,C,w,T,ne,E,re,D,O,ie,ae,k,oe,se,ce,A,le,ue,de,fe,pe,me,he,ge,_e,ve,ye,be;for([p,x]=[.74,.75],b=new a(this.charjunk),[S,ee]=[null,null],k=[],C=w=ue=i,de=o;ue<=de?w<de:w>de;C=ue<=de?++w:--w)for(g=r[C],b.setSeq2(g),te=oe=fe=t,pe=n;fe<=pe?oe<pe:oe>pe;te=fe<=pe?++oe:--oe){if(c=e[te],c===g){S===null&&([S,ee]=[te,C]);continue}b.setSeq1(c),b.realQuickRatio()>p&&b.quickRatio()>p&&b.ratio()>p&&([p,m,h]=[b.ratio(),te,C])}if(p<x){if(S===null){for(me=this._plainReplace(e,t,n,r,i,o),se=0,E=me.length;se<E;se++)ae=me[se],k.push(ae);return k}[m,h,p]=[S,ee,1]}else S=null;for(he=this._fancyHelper(e,t,m,r,i,h),ce=0,re=he.length;ce<re;ce++)ae=he[ce],k.push(ae);if([s,f]=[e[m],r[h]],S===null){for(d=y=``,b.setSeqs(s,f),ge=b.getOpcodes(),A=0,D=ge.length;A<D;A++)switch([be,l,u,_,v]=ge[A],[T,ne]=[u-l,v-_],be){case`replace`:d+=Array(T+1).join(`^`),y+=Array(ne+1).join(`^`);break;case`delete`:d+=Array(T+1).join(`-`);break;case`insert`:y+=Array(ne+1).join(`+`);break;case`equal`:d+=Array(T+1).join(` `),y+=Array(ne+1).join(` `);break;default:throw Error(`unknow tag (${be})`)}for(_e=this._qformat(s,f,d,y),le=0,O=_e.length;le<O;le++)ae=_e[le],k.push(ae)}else k.push(` `+s);for(ve=this._fancyHelper(e,m+1,n,r,h+1,o),ye=0,ie=ve.length;ye<ie;ye++)ae=ve[ye],k.push(ae);return k}_fancyHelper(e,t,n,r,i,a){var o=[];return t<n?o=i<a?this._fancyReplace(e,t,n,r,i,a):this._dump(`-`,e,t,n):i<a&&(o=this._dump(`+`,r,i,a)),o}_qformat(e,t,n,r){var i,a=[];return i=v(l(e,` `),l(t,` `)),i=v(i,l(n.slice(0,i),` `)),i=v(i,l(r.slice(0,i),` `)),n=n.slice(i).replace(/\s+$/,``),r=r.slice(i).replace(/\s+$/,``),a.push(`- `+e),n.length&&a.push(`? ${Array(i+1).join(` `)}${n}
|
|
2
|
+
import{i as e,n as t,t as n}from"./source-mXUcrTVw.mjs";import{a as r}from"./dotenv-usOKkeW7.mjs";import{B as i,C as a,F as o,G as s,I as c,P as l,Q as u,S as d,T as f,U as p,V as m,W as h,Y as g,Z as _,b as v,f as y,it as b,k as x,n as S,o as ee,p as te,r as C,rt as w,u as T,x as ne,y as E}from"./dist-DZRTPMMA.mjs";import{D as re,M as D,N as O,O as ie,S as ae,T as k,_ as oe,a as se,d as ce,g as A,h as le,i as ue,j as de,l as fe,m as pe,n as me,p as he,r as ge,s as _e,t as ve,v as ye,w as be,y as xe}from"./chunk-2HLTAS5V-D7COzUOd.mjs";import{a as Se,c as Ce,i as we,o as j,r as Te,s as Ee,t as De}from"./chunk-DSGVRFIS-C5SqiTOz.mjs";import{C as Oe,D as ke,O as Ae,S as je,T as Me,a as Ne,d as Pe,f as Fe,k as Ie,m as Le,o as Re,r as ze,s as Be,u as Ve,v as He,w as Ue,x as We,y as Ge}from"./interactive-BW9T1D1q.mjs";import{C as Ke,D as qe,_ as Je,a as Ye,c as Xe,g as Ze,i as Qe,m as $e,n as et,o as tt,r as nt,w as rt,x as it,y as at}from"./deploy-context-C0iVbWRG.mjs";import{s as ot}from"./build-i8l2qGVZ.mjs";import{createRequire as st}from"node:module";import{setTimeout as ct}from"node:timers/promises";import{createReadStream as lt,mkdirSync as ut,readFileSync as dt,writeFileSync as ft}from"node:fs";import*as pt from"node:path";import mt,{extname as ht,isAbsolute as gt,resolve as _t,sep as vt}from"node:path";import yt,{URLSearchParams as bt}from"node:url";import{access as xt,readFile as St,readdir as Ct,stat as wt,writeFile as Tt}from"node:fs/promises";import M from"node:assert";import{isDeepStrictEqual as Et}from"node:util";import{Blob as Dt}from"node:buffer";import{gzipSync as Ot}from"node:zlib";import{createHash as kt}from"node:crypto";import{execSync as At}from"node:child_process";import{getFreshSourceMapSupport as jt,getNodeCompat as Mt}from"miniflare";import Nt from"node:readline";import{hash as Pt}from"blake3-wasm";import{convertToWranglerConfig as Ft}from"@cloudflare/config";st(import.meta.url||(typeof __filename==`string`?__filename:`/`));var N,P,It,Lt,Rt,zt,Bt,F=o();function Vt(e){F=o(e.cliPresentation),N=e.logger,P=e.fetchResult,It=e.fetchListResult,Lt=e.fetchPagedListResult,e.fetchKVGetValue,Rt=e.confirm,zt=e.prompt,Bt=e.select}j(Vt,`initDeployHelpersContext`);var Ht=/* @__PURE__ */ t(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=`~`;function i(){}Object.create&&(i.prototype=Object.create(null),new i().__proto__||(r=!1));function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function o(e,t,n,i,o){if(typeof n!=`function`)throw TypeError(`The listener must be a function`);var s=new a(n,i||e,o),c=r?r+t:t;return e._events[c]?e._events[c].fn?e._events[c]=[e._events[c],s]:e._events[c].push(s):(e._events[c]=s,e._eventsCount++),e}function s(e,t){--e._eventsCount===0?e._events=new i:delete e._events[t]}function c(){this._events=new i,this._eventsCount=0}c.prototype.eventNames=function(){var e=[],t,i;if(this._eventsCount===0)return e;for(i in t=this._events)n.call(t,i)&&e.push(r?i.slice(1):i);return Object.getOwnPropertySymbols?e.concat(Object.getOwnPropertySymbols(t)):e},c.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,a=n.length,o=Array(a);i<a;i++)o[i]=n[i].fn;return o},c.prototype.listenerCount=function(e){var t=r?r+e:e,n=this._events[t];return n?n.fn?1:n.length:0},c.prototype.emit=function(e,t,n,i,a,o){var s=r?r+e:e;if(!this._events[s])return!1;var c=this._events[s],l=arguments.length,u,d;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),l){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,i),!0;case 5:return c.fn.call(c.context,t,n,i,a),!0;case 6:return c.fn.call(c.context,t,n,i,a,o),!0}for(d=1,u=Array(l-1);d<l;d++)u[d-1]=arguments[d];c.fn.apply(c.context,u)}else{var f=c.length,p;for(d=0;d<f;d++)switch(c[d].once&&this.removeListener(e,c[d].fn,void 0,!0),l){case 1:c[d].fn.call(c[d].context);break;case 2:c[d].fn.call(c[d].context,t);break;case 3:c[d].fn.call(c[d].context,t,n);break;case 4:c[d].fn.call(c[d].context,t,n,i);break;default:if(!u)for(p=1,u=Array(l-1);p<l;p++)u[p-1]=arguments[p];c[d].fn.apply(c[d].context,u)}}return!0},c.prototype.on=function(e,t,n){return o(this,e,t,n,!1)},c.prototype.once=function(e,t,n){return o(this,e,t,n,!0)},c.prototype.removeListener=function(e,t,n,i){var a=r?r+e:e;if(!this._events[a])return this;if(!t)return s(this,a),this;var o=this._events[a];if(o.fn)o.fn===t&&(!i||o.once)&&(!n||o.context===n)&&s(this,a);else{for(var c=0,l=[],u=o.length;c<u;c++)(o[c].fn!==t||i&&!o[c].once||n&&o[c].context!==n)&&l.push(o[c]);l.length?this._events[a]=l.length===1?l[0]:l:s(this,a)}return this},c.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&s(this,t)):(this._events=new i,this._eventsCount=0),this},c.prototype.off=c.prototype.removeListener,c.prototype.addListener=c.prototype.on,c.prefixed=r,c.EventEmitter=c,t!==void 0&&(t.exports=c)})),Ut=m(),Wt=/* @__PURE__ */ e(Ht(),1),Gt=class e extends Error{name=`TimeoutError`;constructor(t,n){super(t,n),Error.captureStackTrace?.(this,e)}};const Kt=e=>e.reason??new DOMException(`This operation was aborted.`,`AbortError`);function qt(e,t){let{milliseconds:n,fallback:r,message:i,customTimers:a={setTimeout,clearTimeout},signal:o}=t,s,c,l=new Promise((t,l)=>{if(typeof n!=`number`||Math.sign(n)!==1)throw TypeError(`Expected \`milliseconds\` to be a positive number, got \`${n}\``);if(o?.aborted){l(Kt(o));return}if(o&&(c=()=>{l(Kt(o))},o.addEventListener(`abort`,c,{once:!0})),e.then(t,l),n===1/0)return;let u=new Gt;s=a.setTimeout.call(void 0,()=>{if(r){try{t(r())}catch(e){l(e)}return}typeof e.cancel==`function`&&e.cancel(),i===!1?t():i instanceof Error?l(i):(u.message=i??`Promise timed out after ${n} milliseconds`,l(u))},n)}).finally(()=>{l.clear(),c&&o&&o.removeEventListener(`abort`,c)});return l.clear=()=>{a.clearTimeout.call(void 0,s),s=void 0},l}function Jt(e,t,n){let r=0,i=e.length;for(;i>0;){let a=Math.trunc(i/2),o=r+a;n(e[o],t)<=0?(r=++o,i-=a+1):i=a}return r}var Yt=class{#e=[];enqueue(e,t){let{priority:n=0,id:r}=t??{},i={priority:n,id:r,run:e};if(this.size===0||this.#e[this.size-1].priority>=n){this.#e.push(i);return}let a=Jt(this.#e,i,(e,t)=>t.priority-e.priority);this.#e.splice(a,0,i)}setPriority(e,t){let n=this.#e.findIndex(t=>t.id===e);if(n===-1)throw ReferenceError(`No promise function with the id "${e}" exists in the queue.`);let[r]=this.#e.splice(n,1);this.enqueue(r.run,{priority:t,id:e})}dequeue(){return this.#e.shift()?.run}filter(e){return this.#e.filter(t=>t.priority===e.priority).map(e=>e.run)}get size(){return this.#e.length}},Xt=class extends Wt.default{#e;#t;#n=0;#r;#i=!1;#a=!1;#o;#s=0;#c=0;#l;#u;#d;#f;#p=0;#m;#h;#g=1n;#_=/* @__PURE__ */ new Map;timeout;constructor(e){if(super(),e={carryoverIntervalCount:!1,intervalCap:1/0,interval:0,concurrency:1/0,autoStart:!0,queueClass:Yt,...e},!(typeof e.intervalCap==`number`&&e.intervalCap>=1))throw TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${e.intervalCap?.toString()??``}\` (${typeof e.intervalCap})`);if(e.interval===void 0||!(Number.isFinite(e.interval)&&e.interval>=0))throw TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval?.toString()??``}\` (${typeof e.interval})`);if(this.#e=e.carryoverIntervalCount??e.carryoverConcurrencyCount??!1,this.#t=e.intervalCap===1/0||e.interval===0,this.#r=e.intervalCap,this.#o=e.interval,this.#d=new e.queueClass,this.#f=e.queueClass,this.concurrency=e.concurrency,e.timeout!==void 0&&!(Number.isFinite(e.timeout)&&e.timeout>0))throw TypeError(`Expected \`timeout\` to be a positive finite number, got \`${e.timeout}\` (${typeof e.timeout})`);this.timeout=e.timeout,this.#h=e.autoStart===!1,this.#M()}get#v(){return this.#t||this.#n<this.#r}get#y(){return this.#p<this.#m}#b(){this.#p--,this.#p===0&&this.emit(`pendingZero`),this.#E(),this.emit(`next`)}#x(){this.#O(),this.#D(),this.#u=void 0}get#S(){let e=Date.now();if(this.#l===void 0){let t=this.#s-e;if(t<0){if(this.#c>0){let t=e-this.#c;if(t<this.#o)return this.#C(this.#o-t),!0}this.#n=this.#e?this.#p:0}else return this.#C(t),!0}return!1}#C(e){this.#u===void 0&&(this.#u=setTimeout(()=>{this.#x()},e))}#w(){this.#l&&=(clearInterval(this.#l),void 0)}#T(){this.#u&&=(clearTimeout(this.#u),void 0)}#E(){if(this.#d.size===0)return this.#w(),this.emit(`empty`),this.#p===0&&(this.#T(),this.emit(`idle`)),!1;let e=!1;if(!this.#h){let t=!this.#S;if(this.#v&&this.#y){let n=this.#d.dequeue();this.#t||(this.#n++,this.#N()),this.emit(`active`),this.#c=Date.now(),n(),t&&this.#D(),e=!0}}return e}#D(){this.#t||this.#l!==void 0||(this.#l=setInterval(()=>{this.#O()},this.#o),this.#s=Date.now()+this.#o)}#O(){this.#n===0&&this.#p===0&&this.#l&&this.#w(),this.#n=this.#e?this.#p:0,this.#k(),this.#N()}#k(){for(;this.#E(););}get concurrency(){return this.#m}set concurrency(e){if(!(typeof e==`number`&&e>=1))throw TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this.#m=e,this.#k()}async#A(e){return new Promise((t,n)=>{e.addEventListener(`abort`,()=>{n(e.reason)},{once:!0})})}setPriority(e,t){if(typeof t!=`number`||!Number.isFinite(t))throw TypeError(`Expected \`priority\` to be a finite number, got \`${t}\` (${typeof t})`);this.#d.setPriority(e,t)}async add(e,t={}){return t.id??=(this.#g++).toString(),t={timeout:this.timeout,...t},new Promise((n,r)=>{let i=Symbol(`task-${t.id}`);this.#d.enqueue(async()=>{this.#p++,this.#_.set(i,{id:t.id,priority:t.priority??0,startTime:Date.now(),timeout:t.timeout});try{try{t.signal?.throwIfAborted()}catch(e){throw this.#t||this.#n--,this.#_.delete(i),e}let r=e({signal:t.signal});t.timeout&&(r=qt(Promise.resolve(r),{milliseconds:t.timeout,message:`Task timed out after ${t.timeout}ms (queue has ${this.#p} running, ${this.#d.size} waiting)`})),t.signal&&(r=Promise.race([r,this.#A(t.signal)]));let a=await r;n(a),this.emit(`completed`,a)}catch(e){r(e),this.emit(`error`,e)}finally{this.#_.delete(i),queueMicrotask(()=>{this.#b()})}},t),this.emit(`add`),this.#E()})}async addAll(e,t){return Promise.all(e.map(async e=>this.add(e,t)))}start(){return this.#h?(this.#h=!1,this.#k(),this):this}pause(){this.#h=!0}clear(){this.#d=new this.#f,this.#P()}async onEmpty(){this.#d.size!==0&&await this.#j(`empty`)}async onSizeLessThan(e){this.#d.size<e||await this.#j(`next`,()=>this.#d.size<e)}async onIdle(){(this.#p!==0||this.#d.size!==0)&&await this.#j(`idle`)}async onPendingZero(){this.#p!==0&&await this.#j(`pendingZero`)}async onRateLimit(){this.isRateLimited||await this.#j(`rateLimit`)}async onRateLimitCleared(){this.isRateLimited&&await this.#j(`rateLimitCleared`)}async onError(){return new Promise((e,t)=>{let n=e=>{this.off(`error`,n),t(e)};this.on(`error`,n)})}async#j(e,t){return new Promise(n=>{let r=()=>{(!t||t())&&(this.off(e,r),n())};this.on(e,r)})}get size(){return this.#d.size}sizeBy(e){return this.#d.filter(e).length}get pending(){return this.#p}get isPaused(){return this.#h}#M(){this.#t||(this.on(`add`,()=>{this.#d.size>0&&this.#N()}),this.on(`next`,()=>{this.#N()}))}#N(){this.#t||this.#a||(this.#a=!0,queueMicrotask(()=>{this.#a=!1,this.#P()}))}#P(){let e=this.#i,t=!this.#t&&this.#n>=this.#r&&this.#d.size>0;t!==e&&(this.#i=t,this.emit(t?`rateLimit`:`rateLimitCleared`))}get isRateLimited(){return this.#i}get isSaturated(){return this.#p===this.#m&&this.#d.size>0||this.isRateLimited&&this.#d.size>0}get runningTasks(){return[...this.#_.values()].map(e=>({...e}))}};const Zt=[`B`,`kB`,`MB`,`GB`,`TB`,`PB`,`EB`,`ZB`,`YB`],Qt=[`B`,`KiB`,`MiB`,`GiB`,`TiB`,`PiB`,`EiB`,`ZiB`,`YiB`],$t=[`b`,`kbit`,`Mbit`,`Gbit`,`Tbit`,`Pbit`,`Ebit`,`Zbit`,`Ybit`],en=[`b`,`kibit`,`Mibit`,`Gibit`,`Tibit`,`Pibit`,`Eibit`,`Zibit`,`Yibit`],tn=(e,t,n)=>{let r=e;return typeof t==`string`||Array.isArray(t)?r=e.toLocaleString(t,n):(t===!0||n!==void 0)&&(r=e.toLocaleString(void 0,n)),r};function nn(e,t){if(!Number.isFinite(e))throw TypeError(`Expected a finite number, got ${typeof e}: ${e}`);t={bits:!1,binary:!1,space:!0,...t};let n=t.bits?t.binary?en:$t:t.binary?Qt:Zt,r=t.space?` `:``;if(t.signed&&e===0)return` 0${r}${n[0]}`;let i=e<0,a=i?`-`:t.signed?`+`:``;i&&(e=-e);let o;if(t.minimumFractionDigits!==void 0&&(o={minimumFractionDigits:t.minimumFractionDigits}),t.maximumFractionDigits!==void 0&&(o={maximumFractionDigits:t.maximumFractionDigits,...o}),e<1)return a+tn(e,t.locale,o)+r+n[0];let s=Math.min(Math.floor(t.binary?Math.log(e)/Math.log(1024):Math.log10(e)/3),n.length-1);e/=(t.binary?1024:1e3)**s,o||(e=e.toPrecision(3));let c=tn(Number(e),t.locale,o),l=n[s];return a+c+r+l}var rn=r();st(import.meta.url||(typeof __filename==`string`?__filename:`/`));var an=we({"../../node_modules/.pnpm/ignore@5.3.1/node_modules/ignore/index.js"(e,t){function n(e){return Array.isArray(e)?e:[e]}j(n,`makeArray`);var r=``,i=` `,a=`\\`,o=/^\s+$/,s=/(?:[^\\]|^)\\$/,c=/^\\!/,l=/^\\#/,u=/\r?\n/g,d=/^\.*\/|^\.+$/,f=`/`,p=`node-ignore`;typeof Symbol<`u`&&(p=Symbol.for(`node-ignore`));var m=p,h=/* @__PURE__ */ j((e,t,n)=>Object.defineProperty(e,t,{value:n}),`define`),g=/([0-z])-([0-z])/g,_=/* @__PURE__ */ j(()=>!1,`RETURN_FALSE`),v=/* @__PURE__ */ j(e=>e.replace(g,(e,t,n)=>t.charCodeAt(0)<=n.charCodeAt(0)?e:r),`sanitizeRange`),y=/* @__PURE__ */ j(e=>{let{length:t}=e;return e.slice(0,t-t%2)},`cleanRangeBackSlash`),b=[[/^\uFEFF/,()=>r],[/\\?\s+$/,e=>e.indexOf(`\\`)===0?i:r],[/\\\s/g,()=>i],[/[\\$.|*+(){^]/g,e=>`\\${e}`],[/(?!\\)\?/g,()=>`[^/]`],[/^\//,()=>`^`],[/\//g,()=>`\\/`],[/^\^*\\\*\\\*\\\//,()=>`^(?:.*\\/)?`],[/^(?=[^^])/,/* @__PURE__ */ j(function(){return/\/(?!$)/.test(this)?`^`:`(?:^|\\/)`},`startingReplacer`)],[/\\\/\\\*\\\*(?=\\\/|$)/g,(e,t,n)=>t+6<n.length?`(?:\\/[^\\/]+)*`:`\\/.+`],[/(^|[^\\]+)(\\\*)+(?=.+)/g,(e,t,n)=>t+n.replace(/\\\*/g,`[^\\/]*`)],[/\\\\\\(?=[$.|*+(){^])/g,()=>a],[/\\\\/g,()=>a],[/(\\)?\[([^\]/]*?)(\\*)($|\])/g,(e,t,n,r,i)=>t===a?`\\[${n}${y(r)}${i}`:i===`]`&&r.length%2==0?`[${v(n)}${r}]`:`[]`],[/(?:[^*])$/,e=>/\/$/.test(e)?`${e}$`:`${e}(?=$|\\/$)`],[/(\^|\\\/)?\\\*$/,(e,t)=>`${t?`${t}[^/]+`:`[^/]*`}(?=$|\\/$)`]],x=/* @__PURE__ */ Object.create(null),S=/* @__PURE__ */ j((e,t)=>{let n=x[e];return n||(n=b.reduce((t,n)=>t.replace(n[0],n[1].bind(e)),e),x[e]=n),t?new RegExp(n,`i`):new RegExp(n)},`makeRegex`),ee=/* @__PURE__ */ j(e=>typeof e==`string`,`isString`),te=/* @__PURE__ */ j(e=>e&&ee(e)&&!o.test(e)&&!s.test(e)&&e.indexOf(`#`)!==0,`checkPattern`),C=/* @__PURE__ */ j(e=>e.split(u),`splitPattern`),w=class{static{j(this,`IgnoreRule`)}constructor(e,t,n,r){this.origin=e,this.pattern=t,this.negative=n,this.regex=r}},T=/* @__PURE__ */ j((e,t)=>{let n=e,r=!1;e.indexOf(`!`)===0&&(r=!0,e=e.substr(1)),e=e.replace(c,`!`).replace(l,`#`);let i=S(e,t);return new w(n,e,r,i)},`createRule`),ne=/* @__PURE__ */ j((e,t)=>{throw new t(e)},`throwError`),E=/* @__PURE__ */ j((e,t,n)=>ee(e)?e?!E.isNotRelative(e)||n(`path should be a \`path.relative()\`d string, but got "${t}"`,RangeError):n(`path must not be empty`,TypeError):n(`path must be a string, but got \`${t}\``,TypeError),`checkPath`),re=/* @__PURE__ */ j(e=>d.test(e),`isNotRelative`);E.isNotRelative=re,E.convert=e=>e;var D=class{static{j(this,`Ignore`)}constructor({ignorecase:e=!0,ignoreCase:t=e,allowRelativePaths:n=!1}={}){h(this,m,!0),this._rules=[],this._ignoreCase=t,this._allowRelativePaths=n,this._initCache()}_initCache(){this._ignoreCache=/* @__PURE__ */ Object.create(null),this._testCache=/* @__PURE__ */ Object.create(null)}_addPattern(e){if(e&&e[m]){this._rules=this._rules.concat(e._rules),this._added=!0;return}if(te(e)){let t=T(e,this._ignoreCase);this._added=!0,this._rules.push(t)}}add(e){return this._added=!1,n(ee(e)?C(e):e).forEach(this._addPattern,this),this._added&&this._initCache(),this}addPattern(e){return this.add(e)}_testOne(e,t){let n=!1,r=!1;return this._rules.forEach(i=>{let{negative:a}=i;r===a&&n!==r||a&&!n&&!r&&!t||i.regex.test(e)&&(n=!a,r=a)}),{ignored:n,unignored:r}}_test(e,t,n,r){let i=e&&E.convert(e);return E(i,e,this._allowRelativePaths?_:ne),this._t(i,t,n,r)}_t(e,t,n,r){if(e in t)return t[e];if(r||=e.split(f),r.pop(),!r.length)return t[e]=this._testOne(e,n);let i=this._t(r.join(f)+f,t,n,r);return t[e]=i.ignored?i:this._testOne(e,n)}ignores(e){return this._test(e,this._ignoreCache,!1).ignored}createFilter(){return e=>!this.ignores(e)}filter(e){return n(e).filter(this.createFilter())}test(e){return this._test(e,this._testCache,!0)}},O=/* @__PURE__ */ j(e=>new D(e),`factory`);if(O.isPathValid=/* @__PURE__ */ j(e=>E(e&&E.convert(e),e,_),`isPathValid`),O.default=O,t.exports=O,typeof process<`u`&&(process.env&&process.env.IGNORE_TEST_WIN32||process.platform===`win32`)){E.convert=/* @__PURE__ */ j(e=>/^\\\\\?\\/.test(e)||/["<>|\u0000-\u001F]+/u.test(e)?e:e.replace(/\\/g,`/`),`makePosix`);let e=/^[a-z]:\//i;E.isNotRelative=t=>e.test(t)||re(t)}}}),on=we({"../../node_modules/.pnpm/heap@0.2.7/node_modules/heap/lib/heap.js"(e,t){(function(){var n,r,i=Math.floor,a,o,s,c,l,u,d=Math.min,f,p,m,h,g;r=/* @__PURE__ */ j(function(e,t){return e<t?-1:+(e>t)},`defaultCmp`),u=/* @__PURE__ */ j(function(e,t,n,a,o){var s;if(n??=0,o??=r,n<0)throw Error(`lo must be non-negative`);for(a??=e.length;n<a;)s=i((n+a)/2),o(t,e[s])<0?a=s:n=s+1;return[].splice.apply(e,[n,n-n].concat(t)),t},`insort`),s=/* @__PURE__ */ j(function(e,t,n){return n??=r,e.push(t),h(e,0,e.length-1,n)},`heappush`),o=/* @__PURE__ */ j(function(e,t){var n,i;return t??=r,n=e.pop(),e.length?(i=e[0],e[0]=n,g(e,0,t)):i=n,i},`heappop`),l=/* @__PURE__ */ j(function(e,t,n){var i;return n??=r,i=e[0],e[0]=t,g(e,0,n),i},`heapreplace`),c=/* @__PURE__ */ j(function(e,t,n){var i;return n??=r,e.length&&n(e[0],t)<0&&(i=[e[0],t],t=i[0],e[0]=i[1],g(e,0,n)),t},`heappushpop`),a=/* @__PURE__ */ j(function(e,t){var n,a,o,s,c,l;for(t??=r,s=function(){l=[];for(var t=0,n=i(e.length/2);0<=n?t<n:t>n;0<=n?t++:t--)l.push(t);return l}.apply(this).reverse(),c=[],a=0,o=s.length;a<o;a++)n=s[a],c.push(g(e,n,t));return c},`heapify`),m=/* @__PURE__ */ j(function(e,t,n){var i;if(n??=r,i=e.indexOf(t),i!==-1)return h(e,0,i,n),g(e,i,n)},`updateItem`),f=/* @__PURE__ */ j(function(e,t,n){var i,o,s,l,u;if(n??=r,o=e.slice(0,t),!o.length)return o;for(a(o,n),u=e.slice(t),s=0,l=u.length;s<l;s++)i=u[s],c(o,i,n);return o.sort(n).reverse()},`nlargest`),p=/* @__PURE__ */ j(function(e,t,n){var i,s,c,l,f,p,m,h,g;if(n??=r,t*10<=e.length){if(c=e.slice(0,t).sort(n),!c.length)return c;for(s=c[c.length-1],m=e.slice(t),l=0,p=m.length;l<p;l++)i=m[l],n(i,s)<0&&(u(c,i,0,null,n),c.pop(),s=c[c.length-1]);return c}for(a(e,n),g=[],f=0,h=d(t,e.length);0<=h?f<h:f>h;0<=h?++f:--f)g.push(o(e,n));return g},`nsmallest`),h=/* @__PURE__ */ j(function(e,t,n,i){var a,o,s;for(i??=r,a=e[n];n>t;){if(s=n-1>>1,o=e[s],i(a,o)<0){e[n]=o,n=s;continue}break}return e[n]=a},`_siftdown`),g=/* @__PURE__ */ j(function(e,t,n){var i,a,o,s,c;for(n??=r,a=e.length,c=t,o=e[t],i=2*t+1;i<a;)s=i+1,s<a&&!(n(e[i],e[s])<0)&&(i=s),e[t]=e[i],t=i,i=2*t+1;return e[t]=o,h(e,c,t,n)},`_siftup`),n=function(){e.push=s,e.pop=o,e.replace=l,e.pushpop=c,e.heapify=a,e.updateItem=m,e.nlargest=f,e.nsmallest=p;function e(e){this.cmp=e??r,this.nodes=[]}return j(e,`Heap`),e.prototype.push=function(e){return s(this.nodes,e,this.cmp)},e.prototype.pop=function(){return o(this.nodes,this.cmp)},e.prototype.peek=function(){return this.nodes[0]},e.prototype.contains=function(e){return this.nodes.indexOf(e)!==-1},e.prototype.replace=function(e){return l(this.nodes,e,this.cmp)},e.prototype.pushpop=function(e){return c(this.nodes,e,this.cmp)},e.prototype.heapify=function(){return a(this.nodes,this.cmp)},e.prototype.updateItem=function(e){return m(this.nodes,e,this.cmp)},e.prototype.clear=function(){return this.nodes=[]},e.prototype.empty=function(){return this.nodes.length===0},e.prototype.size=function(){return this.nodes.length},e.prototype.clone=function(){var t=new e;return t.nodes=this.nodes.slice(0),t},e.prototype.toArray=function(){return this.nodes.slice(0)},e.prototype.insert=e.prototype.push,e.prototype.top=e.prototype.peek,e.prototype.front=e.prototype.peek,e.prototype.has=e.prototype.contains,e.prototype.copy=e.prototype.clone,e}(),(function(n,r){return typeof define==`function`&&define.amd?define([],r):typeof e==`object`?t.exports=r():n.Heap=r()})(this,function(){return n})}).call(e)}}),sn=we({"../../node_modules/.pnpm/heap@0.2.7/node_modules/heap/index.js"(e,t){t.exports=on()}}),cn=we({"../../node_modules/.pnpm/@ewoudenberg+difflib@0.1.0/node_modules/@ewoudenberg/difflib/lib/difflib.js"(e){(function(){var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=[].indexOf;({floor:h,max:_,min:v}=Math),n=sn(),p=Ee(`assert`),c=/* @__PURE__ */ j(function(e,t){return t?2*e/t:1},`_calculateRatio`),s=/* @__PURE__ */ j(function(e,t){var n,r,i,a,o;for([i,a]=[e.length,t.length],n=r=0,o=v(i,a);0<=o?r<o:r>o;n=0<=o?++r:--r){if(e[n]<t[n])return-1;if(e[n]>t[n])return 1}return i-a},`_arrayCmp`),f=/* @__PURE__ */ j(function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},`_has`),o=/* @__PURE__ */ j(function(e){for(var t,n=0,r=e.length;n<r;n++)if(t=e[n],t)return!0;return!1},`_any`),a=class{static{j(this,`SequenceMatcher`)}constructor(e,t=``,n=``,r=!0){this.isjunk=e,this.autojunk=r,this.a=this.b=null,this.setSeqs(t,n)}setSeqs(e,t){return this.setSeq1(e),this.setSeq2(t)}setSeq1(e){if(e!==this.a)return this.a=e,this.matchingBlocks=this.opcodes=null}setSeq2(e){if(e!==this.b)return this.b=e,this.matchingBlocks=this.opcodes=null,this.fullbcount=null,this._chainB()}_chainB(){var e=this.b,t,n,r,i,a,o,s,c,l,u,d;for(this.b2j=t=/* @__PURE__ */ new Map,r=s=0,c=e.length;s<c;r=++s)n=e[r],t.has(n)||t.set(n,[]),i=t.get(n),i.push(r);return o=/* @__PURE__ */ new Map,a=this.isjunk,a&&t.forEach(function(e,n){if(a(n))return o.set(n,!0),t.delete(n)}),d=/* @__PURE__ */ new Map,l=e.length,this.autojunk&&l>=200&&(u=h(l/100)+1,t.forEach(function(e,n){if(e.length>u)return d.set(n,!0),t.delete(n)})),this.isbjunk=function(e){return o.has(e)},this.isbpopular=function(e){return d.has(e)}}findLongestMatch(e,t,n,r){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x;for([i,a,o,d]=[this.a,this.b,this.b2j,this.isbjunk],[s,c,l]=[e,n,0],p={},u=g=b=e,x=t;b<=x?g<x:g>x;u=b<=x?++g:--g){for(y={},m=[],o.has(i[u])&&(m=o.get(i[u])),v=0,_=m.length;v<_;v++)if(f=m[v],!(f<n)){if(f>=r)break;h=y[f]=(p[f-1]||0)+1,h>l&&([s,c,l]=[u-h+1,f-h+1,h])}p=y}for(;s>e&&c>n&&!d(a[c-1])&&i[s-1]===a[c-1];)[s,c,l]=[s-1,c-1,l+1];for(;s+l<t&&c+l<r&&!d(a[c+l])&&i[s+l]===a[c+l];)l++;for(;s>e&&c>n&&d(a[c-1])&&i[s-1]===a[c-1];)[s,c,l]=[s-1,c-1,l+1];for(;s+l<t&&c+l<r&&d(a[c+l])&&i[s+l]===a[c+l];)l++;return[s,c,l]}getMatchingBlocks(){var e,t,n,r,i,a,o,c,l,u,d,f,p,m,h,g,_,v,y,b,x;if(this.matchingBlocks)return this.matchingBlocks;for([h,g]=[this.a.length,this.b.length],b=[[0,h,0,g]],v=[];b.length;)[t,e,r,n]=b.pop(),[i,c,d]=x=this.findLongestMatch(t,e,r,n),d&&(v.push(x),t<i&&r<c&&b.push([t,i,r,c]),i+d<e&&c+d<n&&b.push([i+d,e,c+d,n]));for(v.sort(s),a=l=f=0,y=[],m=0,_=v.length;m<_;m++)[o,u,p]=v[m],a+f===o&&l+f===u?f+=p:(f&&y.push([a,l,f]),[a,l,f]=[o,u,p]);return f&&y.push([a,l,f]),y.push([h,g,0]),this.matchingBlocks=y}getOpcodes(){var e,t,n,r,i,a,o,s,c,l;if(this.opcodes)return this.opcodes;for(r=i=0,this.opcodes=t=[],s=this.getMatchingBlocks(),a=0,o=s.length;a<o;a++)[e,n,c]=s[a],l=``,r<e&&i<n?l=`replace`:r<e?l=`delete`:i<n&&(l=`insert`),l&&t.push([l,r,e,i,n]),[r,i]=[e+c,n+c],c&&t.push([`equal`,e,r,n,i]);return t}getGroupedOpcodes(e=3){var t=this.getOpcodes(),n,r,i,a,o,s,c,l,u,d;for(t.length||(t=[[`equal`,0,1,0,1]]),t[0][0]===`equal`&&([d,i,a,o,s]=t[0],t[0]=[d,_(i,a-e),a,_(o,s-e),s]),t[t.length-1][0]===`equal`&&([d,i,a,o,s]=t[t.length-1],t[t.length-1]=[d,i,v(a,i+e),o,v(s,o+e)]),u=e+e,r=[],n=[],c=0,l=t.length;c<l;c++)[d,i,a,o,s]=t[c],d===`equal`&&a-i>u&&(n.push([d,i,v(a,i+e),o,v(s,o+e)]),r.push(n),n=[],[i,o]=[_(i,a-e),_(o,s-e)]),n.push([d,i,a,o,s]);return n.length&&(n.length!==1||n[0][0]!==`equal`)&&r.push(n),r}ratio(){var e,t,n,r=0,i=this.getMatchingBlocks();for(e=0,t=i.length;e<t;e++)n=i[e],r+=n[2];return c(r,this.a.length+this.b.length)}quickRatio(){var e,t,n,r,i,a,o,s,l,u,d;if(!this.fullbcount)for(this.fullbcount=n={},u=this.b,r=0,i=u.length;r<i;r++)t=u[r],n[t]=(n[t]||0)+1;for(n=this.fullbcount,e={},s=0,d=this.a,o=0,a=d.length;o<a;o++)t=d[o],l=f(e,t)?e[t]:n[t]||0,e[t]=l-1,l>0&&s++;return c(s,this.a.length+this.b.length)}realQuickRatio(){var e,t;return[e,t]=[this.a.length,this.b.length],c(v(e,t),e+t)}},g=/* @__PURE__ */ j(function(e,t,r=3,i=.6){var o,c,l,u,d,f,p,m,h;if(!(r>0))throw Error(`n must be > 0: (${r})`);if(!(0<=i&&i<=1))throw Error(`cutoff must be in [0.0, 1.0]: (${i})`);for(d=[],p=new a,p.setSeq2(e),o=0,c=t.length;o<c;o++)h=t[o],p.setSeq1(h),p.realQuickRatio()>=i&&p.quickRatio()>=i&&p.ratio()>=i&&d.push([p.ratio(),h]);for(d=n.nlargest(d,r,s),f=[],u=0,l=d.length;u<l;u++)[m,h]=d[u],f.push(h);return f},`getCloseMatches`),l=/* @__PURE__ */ j(function(e,t){var n,r;for([n,r]=[0,e.length];n<r&&e[n]===t;)n++;return n},`_countLeading`),t=class{static{j(this,`Differ`)}constructor(e,t){this.linejunk=e,this.charjunk=t}compare(e,t){var n,r,i,o,s=new a(this.linejunk,e,t),c,l,u,d,f,p=[],m,h=s.getOpcodes(),g;for(l=0,u=h.length;l<u;l++){switch([g,r,n,o,i]=h[l],g){case`replace`:c=this._fancyReplace(e,r,n,t,o,i);break;case`delete`:c=this._dump(`-`,e,r,n);break;case`insert`:c=this._dump(`+`,t,o,i);break;case`equal`:c=this._dump(` `,e,r,n);break;default:throw Error(`unknow tag (${g})`)}for(m=0,d=c.length;m<d;m++)f=c[m],p.push(f)}return p}_dump(e,t,n,r){var i,a,o,s,c=[];for(i=a=o=n,s=r;o<=s?a<s:a>s;i=o<=s?++a:--a)c.push(`${e} ${t[i]}`);return c}_plainReplace(e,t,n,r,i,a){var o,s,c,l,u,d,f,m,h,g;for(p(t<n&&i<a),a-i<n-t?(o=this._dump(`+`,r,i,a),g=this._dump(`-`,e,t,n)):(o=this._dump(`-`,e,t,n),g=this._dump(`+`,r,i,a)),f=[],h=[o,g],c=0,l=h.length;c<l;c++)for(s=h[c],m=0,u=s.length;m<u;m++)d=s[m],f.push(d);return f}_fancyReplace(e,t,n,r,i,o){var s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,C,w,T,ne,E,re,D,O,ie,ae,k,oe,se,ce,A,le,ue,de,fe,pe,me,he,ge,_e,ve,ye,be;for([p,x]=[.74,.75],b=new a(this.charjunk),[S,ee]=[null,null],k=[],C=w=ue=i,de=o;ue<=de?w<de:w>de;C=ue<=de?++w:--w)for(g=r[C],b.setSeq2(g),te=oe=fe=t,pe=n;fe<=pe?oe<pe:oe>pe;te=fe<=pe?++oe:--oe){if(c=e[te],c===g){S===null&&([S,ee]=[te,C]);continue}b.setSeq1(c),b.realQuickRatio()>p&&b.quickRatio()>p&&b.ratio()>p&&([p,m,h]=[b.ratio(),te,C])}if(p<x){if(S===null){for(me=this._plainReplace(e,t,n,r,i,o),se=0,E=me.length;se<E;se++)ae=me[se],k.push(ae);return k}[m,h,p]=[S,ee,1]}else S=null;for(he=this._fancyHelper(e,t,m,r,i,h),ce=0,re=he.length;ce<re;ce++)ae=he[ce],k.push(ae);if([s,f]=[e[m],r[h]],S===null){for(d=y=``,b.setSeqs(s,f),ge=b.getOpcodes(),A=0,D=ge.length;A<D;A++)switch([be,l,u,_,v]=ge[A],[T,ne]=[u-l,v-_],be){case`replace`:d+=Array(T+1).join(`^`),y+=Array(ne+1).join(`^`);break;case`delete`:d+=Array(T+1).join(`-`);break;case`insert`:y+=Array(ne+1).join(`+`);break;case`equal`:d+=Array(T+1).join(` `),y+=Array(ne+1).join(` `);break;default:throw Error(`unknow tag (${be})`)}for(_e=this._qformat(s,f,d,y),le=0,O=_e.length;le<O;le++)ae=_e[le],k.push(ae)}else k.push(` `+s);for(ve=this._fancyHelper(e,m+1,n,r,h+1,o),ye=0,ie=ve.length;ye<ie;ye++)ae=ve[ye],k.push(ae);return k}_fancyHelper(e,t,n,r,i,a){var o=[];return t<n?o=i<a?this._fancyReplace(e,t,n,r,i,a):this._dump(`-`,e,t,n):i<a&&(o=this._dump(`+`,r,i,a)),o}_qformat(e,t,n,r){var i,a=[];return i=v(l(e,` `),l(t,` `)),i=v(i,l(n.slice(0,i),` `)),i=v(i,l(r.slice(0,i),` `)),n=n.slice(i).replace(/\s+$/,``),r=r.slice(i).replace(/\s+$/,``),a.push(`- `+e),n.length&&a.push(`? ${Array(i+1).join(` `)}${n}
|
|
3
3
|
`),a.push(`+ `+t),r.length&&a.push(`? ${Array(i+1).join(` `)}${r}
|
|
4
4
|
`),a}},i=/* @__PURE__ */ j(function(e,t=/^\s*#?\s*$/){return t.test(e)},`IS_LINE_JUNK`),r=/* @__PURE__ */ j(function(e,t=` `){return S.call(t,e)>=0},`IS_CHARACTER_JUNK`),d=/* @__PURE__ */ j(function(e,t){var n=e+1,r=t-e;return r===1?`${n}`:(r||n--,`${n},${r}`)},`_formatRangeUnified`),x=/* @__PURE__ */ j(function(e,t,{fromfile:n,tofile:r,fromfiledate:i,tofiledate:o,n:s,lineterm:c}={}){var l,u,f,p,m,h,g,_,v,y,b,x,S,ee,te,C,w,T,ne,E,re,D,O,ie,ae,k,oe,se,ce;for(n??=``,r??=``,i??=``,o??=``,s??=3,c??=`
|
|
5
5
|
`,T=[],oe=!1,O=new a(null,e,t).getGroupedOpcodes(),y=0,x=O.length;y<x;y++)for(m=O[y],oe||(oe=!0,p=i?` ${i}`:``,ce=o?` ${o}`:``,T.push(`--- ${n}${p}${c}`),T.push(`+++ ${r}${ce}${c}`)),[f,b]=[m[0],m[m.length-1]],l=d(f[1],b[2]),u=d(f[3],b[4]),T.push(`@@ -${l} +${u} @@${c}`),ne=0,S=m.length;ne<S;ne++){if([se,h,g,_,v]=m[ne],se===`equal`){for(ie=e.slice(h,g),E=0,ee=ie.length;E<ee;E++)w=ie[E],T.push(` `+w);continue}if(se===`replace`||se===`delete`)for(ae=e.slice(h,g),re=0,te=ae.length;re<te;re++)w=ae[re],T.push(`-`+w);if(se===`replace`||se===`insert`)for(k=t.slice(_,v),D=0,C=k.length;D<C;D++)w=k[D],T.push(`+`+w)}return T},`unifiedDiff`),u=/* @__PURE__ */ j(function(e,t){var n=e+1,r=t-e;return r||n--,r<=1?`${n}`:`${n},${n+r-1}`},`_formatRangeContext`),m=/* @__PURE__ */ j(function(e,t,{fromfile:n,tofile:r,fromfiledate:i,tofiledate:s,n:c,lineterm:l}={}){var d,f,p,m,h,g,_,v,y,b,x,S,ee,te,C,w,T,ne,E,re,D,O,ie,ae,k,oe,se,ce,A,le;for(n??=``,r??=``,i??=``,s??=``,c??=3,l??=`
|