cf 1.0.0-beta.26 → 1.0.0-beta.28
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/_meta/commands.json +7373 -4926
- package/dist/_meta/hand-written-commands.json +2 -2
- package/dist/_meta/schemas.json +11614 -4465
- package/dist/abuse-reports-D9edOyag.mjs +24 -0
- package/dist/{access-DCOOmDC5.mjs → access-CKCCSrrU.mjs} +1 -1
- package/dist/{accounts-HC6XuIwP.mjs → accounts-CNb9U9bK.mjs} +33 -27
- package/dist/{acm-DYgr6SAR.mjs → acm-CdKTAToZ.mjs} +3 -3
- package/dist/{addressing-BS66pJ_a.mjs → addressing-eZI_C-b0.mjs} +18 -18
- package/dist/{agent-memory-BbXdueL0.mjs → agent-memory-BBHCEE7h.mjs} +7 -7
- package/dist/{ai-BiIKznNv.mjs → ai-Csl_QNwv.mjs} +7 -7
- package/dist/ai-audit-DlqWsQi-.mjs +6 -0
- package/dist/{ai-gateway-rlYCbts5.mjs → ai-gateway-Lj4On37s.mjs} +13 -13
- package/dist/ai-search-BxyhS3X7.mjs +74 -0
- package/dist/{ai-security-BUwS6kVh.mjs → ai-security-DvU2iYkY.mjs} +3 -3
- package/dist/{alerting-BSzuvFk1.mjs → alerting-r0G2X9y9.mjs} +10 -10
- package/dist/analytics-C6bfqm-W.mjs +17 -0
- package/dist/analytics-engine-BlIecoOe.mjs +4 -0
- package/dist/api-Dnt6lRJG.mjs +3 -0
- package/dist/{api-security-BBxEJjGv.mjs → api-security-DZ7GWOqD.mjs} +26 -26
- package/dist/argo-Bh0_cj49.mjs +14 -0
- package/dist/{artifacts-B9g9aPrk.mjs → artifacts-VZJWVq_6.mjs} +16 -16
- package/dist/{audit-logs-BhJs-OS2.mjs → audit-logs-B8cGL4B9.mjs} +1 -1
- package/dist/auth-B-h0BHg7.mjs +2 -0
- package/dist/auth-B6tswVxH.mjs +2 -0
- package/dist/{auth-C50SqX9F.mjs → auth-clmqFEWU.mjs} +3 -3
- package/dist/{auth-token-DvNoIhRL.mjs → auth-token-DW4dJVdj.mjs} +1 -1
- package/dist/{autoconfig-ldsgXxa6.mjs → autoconfig-C0ynlGHf.mjs} +23 -23
- package/dist/{basin-catalog-CtKFiH-n.mjs → basin-catalog-TehR1sKZ.mjs} +11 -11
- package/dist/billing-B2KusU6g.mjs +22 -0
- package/dist/{blocks-DnNrvi8s.mjs → blocks-BFulF68V.mjs} +1 -1
- package/dist/body-parser-DoewLePl.mjs +2 -0
- package/dist/body-unions-DNs981Ia.mjs +2 -0
- package/dist/bot-management-CXHXgrQC.mjs +9 -0
- package/dist/{botnet-feed-lD9s2oLA.mjs → botnet-feed-UyK7Rfp6.mjs} +1 -1
- package/dist/brand-protection-kv1ba80i.mjs +14 -0
- package/dist/browser-run-D-vRoZmf.mjs +40 -0
- package/dist/build-BzJGqb2o.mjs +2 -0
- package/dist/build-FFxzigo4.mjs +2 -0
- package/dist/{builds-D3mAH87h.mjs → builds-BbxINHRP.mjs} +27 -27
- package/dist/cache-BacNNtLu.mjs +36 -0
- package/dist/{cf-CpC4giTf.mjs → cf-BQ_LRiut.mjs} +2 -2
- package/dist/{chunk-DSGVRFIS-vdfri8fR.mjs → chunk-DSGVRFIS-BaNZNW-M.mjs} +1 -1
- package/dist/chunk-SOBRPAPT-QTjnHSNs.mjs +363 -0
- package/dist/{cli-Cm4Twas4.mjs → cli-B7vslRfu.mjs} +1 -1
- package/dist/{client-side-security-BRn7KBpu.mjs → client-side-security-bzB9JosR.mjs} +6 -6
- package/dist/{cloud-connector-DqkOIRDr.mjs → cloud-connector-BHtf37R5.mjs} +2 -2
- package/dist/{cloudflared-DDp_8PTK.mjs → cloudflared-QDdHMUEY.mjs} +1 -1
- package/dist/{cloudforce-one-B9k8vhso.mjs → cloudforce-one-DWBPQDA3.mjs} +126 -124
- package/dist/{command--Y_QAiU2.mjs → command-AVwd7XjE.mjs} +1 -1
- package/dist/{command-DlI7Z_7j.mjs → command-B87T_f2f.mjs} +1 -1
- package/dist/{command-QHmV62Fv.mjs → command-CEHhi3t0.mjs} +1 -1
- package/dist/{command-B-_ba4rQ.mjs → command-CYmQE79n.mjs} +1 -1
- package/dist/{command-DsOv6z9q.mjs → command-CbxXc5IW.mjs} +1 -1
- package/dist/{command-BKNQsGqu.mjs → command-Ce8CVLth.mjs} +1 -1
- package/dist/{command-MxFFWqMg.mjs → command-CqDudQZs.mjs} +1 -1
- package/dist/{command-BV8-laJK.mjs → command-D4YcwpVp.mjs} +1 -1
- package/dist/{command-BVz2aES3.mjs → command-D895kdlh.mjs} +1 -1
- package/dist/{command-yOG9VUtq.mjs → command-D9Qyi1B0.mjs} +1 -1
- package/dist/{command-CfOqnqlN.mjs → command-DeutqL1n.mjs} +1 -1
- package/dist/{command-Dn39o5xQ.mjs → command-Dl9ICrRK.mjs} +1 -1
- package/dist/{command-CN8NFLs2.mjs → command-DtCSe8Hy.mjs} +1 -1
- package/dist/{command-BsCFkho-.mjs → command-DwzVtmb3.mjs} +1 -1
- package/dist/{command-CQMRxiDz.mjs → command-wtBubtZ4.mjs} +1 -1
- package/dist/{completions-BA52jTea.mjs → completions-BvdKtzsX.mjs} +1 -1
- package/dist/{connector-interrupts-zL7pxPn6.mjs → connector-interrupts-dUPW6Ya_.mjs} +2 -2
- package/dist/{connector-telemetry-events-PL4Fqqvu.mjs → connector-telemetry-events-DWVCqnhn.mjs} +1 -1
- package/dist/{connector-telemetry-snapshots-DyBSuEFB.mjs → connector-telemetry-snapshots-CeMP3qeI.mjs} +1 -1
- package/dist/{connectors-D8H6rQz9.mjs → connectors-DZFGNw3i.mjs} +4 -4
- package/dist/{containers-D4sa-Eoy.mjs → containers-B06OGOEB.mjs} +212 -212
- package/dist/{containers-Db-eWudu.mjs → containers-DCzQCo79.mjs} +8 -8
- package/dist/{content-scan-DUVq09i8.mjs → content-scan-XhnNJqXf.mjs} +4 -4
- package/dist/{context-BvLXzoMs.mjs → context-BY1Eh_Qe.mjs} +1 -1
- package/dist/{cps-CqaRliZZ.mjs → cps-CohlxvuN.mjs} +2 -2
- package/dist/create-DmLDMvrj.mjs +2 -0
- package/dist/{csam-scanner-DsXvOOsZ.mjs → csam-scanner-BV4bHq8v.mjs} +2 -4
- package/dist/custom-csrs-BVdMQjYq.mjs +18 -0
- package/dist/{custom-hostnames-Cj_csfo_.mjs → custom-hostnames-r-CxhSa1.mjs} +5 -5
- package/dist/custom-nameservers-CapMDyly.mjs +12 -0
- package/dist/custom-pages-BVIniWfq.mjs +38 -0
- package/dist/d1-nJCOJZb8.mjs +50 -0
- package/dist/{delegate-CMfEjvHn.mjs → delegate-CcL6RoGw.mjs} +1 -1
- package/dist/delegate.mjs +1 -1
- package/dist/{deploy-DDbmxkiX.mjs → deploy-DJMnWFNk.mjs} +1 -1
- package/dist/{deploy-context-DsEVu7bf.mjs → deploy-context-YCW3eqP1.mjs} +15 -15
- package/dist/{deploy-input-BA_3Q2Xu.mjs → deploy-input-CQLBXFEB.mjs} +1 -1
- package/dist/{dev-BS156bim.mjs → dev-GsYHvMah.mjs} +1 -1
- package/dist/{diagnostics-BmkQnSEb.mjs → diagnostics-C3nqxsAO.mjs} +4 -4
- package/dist/{dist-DehXZozc.mjs → dist-D-ihn_mV.mjs} +42 -33
- package/dist/{dls-DciZC_gQ.mjs → dls-N1x8sAK3.mjs} +3 -3
- package/dist/{dns-C2YPspGN.mjs → dns-DATWP-PF.mjs} +36 -30
- package/dist/{dns-firewall-CRfde07f.mjs → dns-firewall-n3Y2ui6W.mjs} +8 -8
- package/dist/{docs-CYjyBA8q.mjs → docs-CRc_WOXh.mjs} +1 -1
- package/dist/{dry-run-gy0Hl9xo.mjs → dry-run-kJbjn4kG.mjs} +1 -1
- package/dist/{durable-objects-DcI97y4p.mjs → durable-objects-DHK9w-vO.mjs} +2 -2
- package/dist/{email-auth-CMCQAu99.mjs → email-auth-ptdqNSTZ.mjs} +1 -1
- package/dist/email-domains-uL22-zRY.mjs +14 -0
- package/dist/{email-routing-7p9dr5Ue.mjs → email-routing-CV43rMJC.mjs} +15 -13
- package/dist/{email-security-Bu0fAYh-.mjs → email-security-DK_SJ0yi.mjs} +38 -38
- package/dist/{email-sending-OpMZNaHZ.mjs → email-sending-CTQafGec.mjs} +17 -17
- package/dist/{error-sanitization-DG8WSzHe.mjs → error-sanitization-BkgtZ0Vx.mjs} +1 -1
- package/dist/error-sanitization-D069tpKk.mjs +2 -0
- package/dist/{errors-C5RGao2J.mjs → errors-VG1mgwJl.mjs} +1 -1
- package/dist/{field-extractors-BfsNjd0e.mjs → field-extractors-jcZ_bAGc.mjs} +2 -2
- package/dist/{firewall-CJ-VIOk1.mjs → firewall-CW-fAI9m.mjs} +30 -14
- package/dist/{flagship-C5PTR1ND.mjs → flagship-RiLnDwfJ.mjs} +8 -8
- package/dist/{fraud-B7hwBheX.mjs → fraud-DvfBBTe8.mjs} +2 -2
- package/dist/get-3XNn0upb.mjs +2 -0
- package/dist/global-options-DiKj2cQy.mjs +2 -0
- package/dist/{google-tag-gateway-D7iFDVEa.mjs → google-tag-gateway-C5WYsSXv.mjs} +2 -2
- package/dist/{healthchecks-B4jTcKV7.mjs → healthchecks-BA1fmzTm.mjs} +5 -5
- package/dist/{hyperdrive-1432DM-p.mjs → hyperdrive-Ch6klUp3.mjs} +4 -4
- package/dist/iam-LlGEzRCq.mjs +62 -0
- package/dist/{images-Ttea4khD.mjs → images-C5WqUXkK.mjs} +11 -11
- package/dist/index.mjs +1 -1
- package/dist/{init-BeYrAg7Q.mjs → init-EVsjBrOz.mjs} +2 -2
- package/dist/{intel-CJznBf5n.mjs → intel-vcWyslaX.mjs} +18 -19
- package/dist/{interactive-DsU8VDvK.mjs → interactive-BCDFSPtq.mjs} +1 -1
- package/dist/{internal-DOho_iA0.mjs → internal-BhV9WjLp.mjs} +1 -1
- package/dist/{ips-BgNoRwFN.mjs → ips-CqHjVsqd.mjs} +1 -1
- package/dist/{k2-Cj1ORHul.mjs → k2-CZT2Pd5J.mjs} +2 -2
- package/dist/kv-Ipa7dnvF.mjs +12 -0
- package/dist/{lazy-command-DeTzOWvU.mjs → lazy-command-DbKVgdGT.mjs} +1 -1
- package/dist/{leaked-credential-checks-21Wc7OqL.mjs → leaked-credential-checks-EzT4TTjO.mjs} +4 -4
- package/dist/{live-BfrWKfq8.mjs → live-C9L1bNuE.mjs} +1 -1
- package/dist/load-balancers-Cb3VkSfc.mjs +84 -0
- package/dist/local-D5Vq6ooZ.mjs +2 -0
- package/dist/{local-CvzO-cQH.mjs → local-DIJ7SIKC.mjs} +1 -1
- package/dist/{local-runtime-DOpR_Tnc.mjs → local-runtime-BZjgkacr.mjs} +1 -1
- package/dist/{login-CVWkMh1L.mjs → login-DG5ebyab.mjs} +1 -1
- package/dist/login-DRJugxya.mjs +2 -0
- package/dist/logpush-C5Gw7F_9.mjs +68 -0
- package/dist/logs-y3REfHbb.mjs +51 -0
- package/dist/magic-network-monitoring-BZBGZB6M.mjs +34 -0
- package/dist/{magic-transit-BhP424T-.mjs → magic-transit-BPV_POf5.mjs} +129 -129
- package/dist/{managed-defense-6l_B3hn_.mjs → managed-defense-BaUBSUcz.mjs} +3 -3
- package/dist/{managed-transforms-D7FMBsnq.mjs → managed-transforms-CjkjLzMC.mjs} +2 -2
- package/dist/{mcp-BUOfMkBP.mjs → mcp-RPtrISTy.mjs} +6 -6
- package/dist/{mesh-B1RrhAT1.mjs → mesh-DZ4QHBPE.mjs} +5 -5
- package/dist/{migrate-BTU8AvlP.mjs → migrate-CRIUqGi2.mjs} +1 -1
- package/dist/{monetization-Da3ooFLC.mjs → monetization-CVZqM8Xo.mjs} +9 -5
- package/dist/{network-CjhSzhMm.mjs → network-DLt2JUo1.mjs} +15 -15
- package/dist/{network-interconnects-DEQD6GM8.mjs → network-interconnects-9nS5jL__.mjs} +10 -10
- package/dist/o11y-ySxrnP1Z.mjs +88 -0
- package/dist/{oauth-Dnog5v-Q.mjs → oauth-CFVUl-Wv.mjs} +1 -1
- package/dist/{oauth-DdXkpU44.mjs → oauth-Cidoyxfp.mjs} +1 -1
- package/dist/observability-C-KNh__y.mjs +4 -0
- package/dist/ohttp-gateway-B5nCl4s3.mjs +8 -0
- package/dist/organizations-DbeeWUL4.mjs +71 -0
- package/dist/output-BZQEl3mK.mjs +2 -0
- package/dist/package-B7RgwuFR.mjs +2 -0
- package/dist/{page-rules-D2eFbKWb.mjs → page-rules-DRw763O1.mjs} +4 -4
- package/dist/{pages-DYZDvWK6.mjs → pages-DfQnxiTk.mjs} +12 -12
- package/dist/{pay-per-crawl-CgPFv5HT.mjs → pay-per-crawl-EHYtSKxX.mjs} +13 -13
- package/dist/{pay-per-use-BIQrsrTy.mjs → pay-per-use-wdEhl8k4.mjs} +14 -12
- package/dist/{pipelines-D6pkhlpm.mjs → pipelines-DbyrI6F4.mjs} +11 -11
- package/dist/precursor-Dx8lN4UJ.mjs +4 -0
- package/dist/previews-DEVNSip2.mjs +6 -0
- package/dist/{progress-B-CVX0kn.mjs → progress-yvPscjYg.mjs} +1 -1
- package/dist/{prompt-DJF_Rs5S.mjs → prompt-CEpZ-lQZ.mjs} +1 -1
- package/dist/{queues-DaqLO-UO.mjs → queues-DgMc7Z6A.mjs} +18 -18
- package/dist/{r2-DDIU9JN3.mjs → r2-BpTVicIq.mjs} +43 -43
- package/dist/{radar-D59qCgld.mjs → radar-DW-S1VUh.mjs} +11 -11
- package/dist/{raw-fetch-BrOxDN9k.mjs → raw-fetch-Cl5spWC3.mjs} +1 -1
- package/dist/{ready-DgE08svD.mjs → ready-d0li0X6r.mjs} +1 -1
- package/dist/realtime-DMKHLYF4.mjs +170 -0
- package/dist/registrar-D23gfKBi.mjs +43 -0
- package/dist/{registrar-sandbox-uzs3eOKk.mjs → registrar-sandbox-lVLB1-mC.mjs} +4 -4
- package/dist/{reporting-Dx2YTick.mjs → reporting-WX8P3Y0k.mjs} +2 -2
- package/dist/{request-headers-DHzBX7dQ.mjs → request-headers-C0FpeBhz.mjs} +1 -1
- package/dist/{request-tracers-B49cBKkj.mjs → request-tracers-qd7XOAka.mjs} +2 -2
- package/dist/resource-sharing-B2ZSt_cA.mjs +36 -0
- package/dist/{rules-CjgLSlUC.mjs → rules-CB0QQTB3.mjs} +5 -5
- package/dist/rulesets-DmqwixUC.mjs +42 -0
- package/dist/{rum-vPEpMS_h.mjs → rum-BZ_24qZU.mjs} +9 -9
- package/dist/{run-BZ6Fj3jQ.mjs → run-BOKI1uWa.mjs} +1 -1
- package/dist/run-DBqOjD1P.mjs +2 -0
- package/dist/{schema-DuLIZRhA.mjs → schema-Dj9STsWI.mjs} +1 -1
- package/dist/{schema-cache-C_rvto6Y.mjs → schema-cache-5NkOj7Y3.mjs} +1 -1
- package/dist/schema-flags-CXm9iIv6.mjs +4 -0
- package/dist/{scim-BA7XbsSu.mjs → scim-DchxaJfE.mjs} +8 -8
- package/dist/{secrets-store-MEUNt1Ph.mjs → secrets-store-oAft1cFE.mjs} +5 -5
- package/dist/security-insights-DMm0qg_m.mjs +62 -0
- package/dist/{security-txt-DikhnR2L.mjs → security-txt-CIt0494b.mjs} +2 -2
- package/dist/{session-BOnam-Wv.mjs → session-vzNfUhPl.mjs} +1 -1
- package/dist/{shared-DmmWSObC.mjs → shared-MK-_lkbn.mjs} +1 -1
- package/dist/{signed-url-C-24KbWB.mjs → signed-url-gNangfwc.mjs} +1 -1
- package/dist/{smart-shield-DPqLMz7M.mjs → smart-shield-Boy_qbqd.mjs} +6 -6
- package/dist/{snippets-Bi3Uq1DF.mjs → snippets-DdoDYXW-.mjs} +3 -3
- package/dist/{spawn-C3hzWVrJ.mjs → spawn-B5F4OIHG.mjs} +1 -1
- package/dist/{spectrum-BaWKMoAl.mjs → spectrum-DLYIHelC.mjs} +3 -3
- package/dist/{speed-DShjlpAs.mjs → speed-DugG9Tm9.mjs} +2 -2
- package/dist/{sql-DCoFf15T.mjs → sql-Bb56llsb.mjs} +2 -2
- package/dist/src-BoSDeQ9m.mjs +133 -0
- package/dist/{ssl-C4nt4pJK.mjs → ssl-Bg4X3WGk.mjs} +24 -24
- package/dist/startup-profile-DQVkZZpb.mjs +2 -0
- package/dist/{startup-profile-CFJ_Lu1c.mjs → startup-profile-DZL2DC44.mjs} +1 -1
- package/dist/state-DW3QZtfh.mjs +2 -0
- package/dist/{state-DmjHXZat.mjs → state-mr5ux1Nb.mjs} +1 -1
- package/dist/{stream-CpZbnSpH.mjs → stream-BuZYDbNR.mjs} +21 -21
- package/dist/{tags-BIjQ3Kjh.mjs → tags-SKz2odE_.mjs} +12 -6
- package/dist/{telemetry-BDhqOpUw.mjs → telemetry-B4zmCpT0.mjs} +1 -1
- package/dist/telemetry-DkDUr4KK.mjs +2 -0
- package/dist/tenant-custom-nameservers-BhkhBerL.mjs +8 -0
- package/dist/tenants-DD-GMq0K.mjs +13 -0
- package/dist/{tools-C-vmgYSv.mjs → tools-KW_4hvzY.mjs} +1 -1
- package/dist/{tunnels-CXAO2CeL.mjs → tunnels-D90ztENM.mjs} +6 -6
- package/dist/{turnstile-Ctm0rs0q.mjs → turnstile-DhSU_Xar.mjs} +4 -4
- package/dist/ui-xjCox-gU.mjs +2 -0
- package/dist/{update-check-D_Wtw0_D.mjs → update-check-CRttabfu.mjs} +1 -1
- package/dist/{update-check-Dc7cRFlx.mjs → update-check-HltjTMDE.mjs} +1 -1
- package/dist/update-check-worker.mjs +1 -1
- package/dist/{url-normalization-DOfc2Q7a.mjs → url-normalization-K7gkmPvG.mjs} +2 -2
- package/dist/{url-scanner-J8M3X2tR.mjs → url-scanner-BRdWwka4.mjs} +3 -3
- package/dist/{user-BaF0qvvO.mjs → user-Cmb1_Wu5.mjs} +50 -52
- package/dist/{vectorize-D5qiggZU.mjs → vectorize-BTBerJME.mjs} +11 -11
- package/dist/verify-B9ILCohg.mjs +2 -0
- package/dist/verify-BCuWaO-L.mjs +2 -0
- package/dist/version-6Bpy6Bgt.mjs +2 -0
- package/dist/{waiting-rooms-BdmAq7ul.mjs → waiting-rooms-LymmKIGr.mjs} +16 -14
- package/dist/{web-assets-BySw_Tme.mjs → web-assets-LHPQsrnY.mjs} +21 -21
- package/dist/{web3-BKkKf1RF.mjs → web3-BsOio0Ae.mjs} +12 -12
- package/dist/workers-BnLiOjZf.mjs +39 -0
- package/dist/{workers-builds-CVJ4FqzB.mjs → workers-builds-sKpITeRk.mjs} +4 -4
- package/dist/{workers-for-platforms-mzdtmr6r.mjs → workers-for-platforms-BGp6yr6P.mjs} +9 -9
- package/dist/workers-vpc-D8lefWDo.mjs +12 -0
- package/dist/{workflows-Cr957c4U.mjs → workflows-B-ZIG3y7.mjs} +22 -22
- package/dist/{wrangler-migration-DZV7-4Fp.mjs → wrangler-migration-6E6wT_LZ.mjs} +67 -58
- package/dist/zaraz-BBKki5WS.mjs +22 -0
- package/dist/{zero-trust-BVCvQJ4e.mjs → zero-trust-BZDXM5r6.mjs} +487 -409
- package/dist/{zones-BzyjOT10.mjs → zones-B-UV_DGE.mjs} +24 -24
- package/package.json +16 -16
- package/dist/abuse-reports-zPrsxbRz.mjs +0 -24
- package/dist/ai-audit-DI4Rw2wl.mjs +0 -6
- package/dist/ai-search-QOenIzDL.mjs +0 -74
- package/dist/analytics-CQ-Yt1mm.mjs +0 -17
- package/dist/analytics-engine-CdrY5-95.mjs +0 -4
- package/dist/api-X3wKppsT.mjs +0 -3
- package/dist/argo-BiefH8wc.mjs +0 -14
- package/dist/auth-Czzy5Rs_.mjs +0 -2
- package/dist/auth-D5Yj9eYU.mjs +0 -2
- package/dist/billing-BrLJqlOf.mjs +0 -22
- package/dist/body-parser-BKcZS9iJ.mjs +0 -2
- package/dist/bot-management-BSBVuKc0.mjs +0 -9
- package/dist/brand-protection-Byoa1hvj.mjs +0 -26
- package/dist/browser-run-BSVANGzU.mjs +0 -40
- package/dist/build-CPKxZ3kL.mjs +0 -2
- package/dist/build-Dwd1_7o0.mjs +0 -2
- package/dist/cache-0xCdyNg9.mjs +0 -36
- package/dist/chunk-3PJ54H4K-CY8EY_n2.mjs +0 -363
- package/dist/create-BtmuVqVL.mjs +0 -2
- package/dist/custom-csrs-Dl_daAbX.mjs +0 -10
- package/dist/custom-nameservers-Bw2P7F_W.mjs +0 -8
- package/dist/custom-pages-CJ7ecSX6.mjs +0 -20
- package/dist/d1-BsWI546w.mjs +0 -89
- package/dist/email-domains-1Nx60ETD.mjs +0 -12
- package/dist/error-sanitization-B025CygB.mjs +0 -2
- package/dist/get-Be821dio.mjs +0 -2
- package/dist/iam-DuZenYtc.mjs +0 -48
- package/dist/kv-CTyuvcAz.mjs +0 -12
- package/dist/load-balancers-DMTsh-9q.mjs +0 -72
- package/dist/local-CWTti4ot.mjs +0 -2
- package/dist/login-Djz5mvHJ.mjs +0 -2
- package/dist/logpush-OMhp7VgE.mjs +0 -44
- package/dist/logs-BSyyNwso.mjs +0 -35
- package/dist/magic-cloud-networking-DD29yMnE.mjs +0 -68
- package/dist/magic-network-monitoring-DRRvSrDP.mjs +0 -34
- package/dist/o11y-DeNxXxcp.mjs +0 -86
- package/dist/oauth-clients-UnbMcHkx.mjs +0 -14
- package/dist/oauth-scopes-DbtnZVO4.mjs +0 -4
- package/dist/organization-IsxVyWol.mjs +0 -73
- package/dist/organizations-p8Mgo8A7.mjs +0 -4
- package/dist/origin-post-quantum-encryption-Bwysyttf.mjs +0 -6
- package/dist/output-BJEgbI0G.mjs +0 -2
- package/dist/package-BOE_De2L.mjs +0 -2
- package/dist/precursor-B35P8h6h.mjs +0 -4
- package/dist/previews-B1mqjXaJ.mjs +0 -6
- package/dist/realtime-DWjdrDzv.mjs +0 -168
- package/dist/registrar-uYOU1U27.mjs +0 -43
- package/dist/resource-sharing-CIsLVAcK.mjs +0 -36
- package/dist/rulesets-C7_aZA7m.mjs +0 -34
- package/dist/run-D4-K_cbQ.mjs +0 -2
- package/dist/schema-flags-Cr6kleor.mjs +0 -4
- package/dist/security-insights-ZKtey62s.mjs +0 -40
- package/dist/src-jyCTFHcS.mjs +0 -131
- package/dist/startup-profile-D_Qjgca1.mjs +0 -2
- package/dist/state-C7lNNN31.mjs +0 -2
- package/dist/telemetry-BZdRnr26.mjs +0 -2
- package/dist/tenant-CqYoylyU.mjs +0 -10
- package/dist/tenant-custom-nameservers-DDzzdyY3.mjs +0 -8
- package/dist/ui-BUCBQ3Sq.mjs +0 -2
- package/dist/version-DNcdABcr.mjs +0 -2
- package/dist/workers-TS0oQ-XH.mjs +0 -39
- package/dist/workers-vpc-xB1hHFPd.mjs +0 -12
- package/dist/zaraz-C8__FhOh.mjs +0 -22
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{r as e,t}from"./rolldown-runtime-BNtqjh-B.mjs";import{n,t as r}from"./ansi-styles-kSC6bEIq.mjs";import{t as i}from"./lazy-command-DbKVgdGT.mjs";import{n as a}from"./metadata-Df5kCWJv.mjs";import{r as o}from"./theme-BGHWSKCw.mjs";import{t as s}from"./agent-context-Dtyy4aKL.mjs";import{t as c}from"./args-BAOHroBC.mjs";import{t as l}from"./cli-exit-CstFZ1eJ.mjs";import{n as u,t as d}from"./dotenv-DKRemNCH.mjs";import{n as f}from"./version-6Bpy6Bgt.mjs";import{r as p}from"./blocks-BFulF68V.mjs";import{n as m,t as h}from"./session-vzNfUhPl.mjs";import{n as g}from"./errors-VG1mgwJl.mjs";import{n as _,r as v,t as y}from"./global-options-DiKj2cQy.mjs";import{t as b}from"./hand-written-dry-run-B82fRl2N.mjs";import{i as ee}from"./local-DIJ7SIKC.mjs";import{a as te}from"./project-settings-nBMEx1f-.mjs";import{a as ne,n as x,t as S}from"./lifecycle-oud60haK.mjs";import"./ui-xjCox-gU.mjs";import{createRequire as C}from"node:module";import{setTimeout as re}from"node:timers/promises";import{notStrictEqual as w,strictEqual as ie}from"assert";import{basename as ae,dirname as oe,extname as se,join as ce,normalize as le,relative as ue,resolve as T}from"path";import{readFileSync as de,readdirSync as fe,statSync as E,writeFile as pe}from"fs";import{format as me,inspect as he}from"util";import{fileURLToPath as ge}from"url";import{readFileSync as _e,readdirSync as ve}from"node:fs";const ye={right:Ce,center:we};var be=class{constructor(e){this.width=e.width,this.wrap=e.wrap??!0,this.rows=[]}span(...e){let t=this.div(...e);t.span=!0}resetOutput(){this.rows=[]}div(...e){if(e.length===0&&this.div(``),this.wrap&&this.shouldApplyLayoutDSL(...e)&&typeof e[0]==`string`)return this.applyLayoutDSL(e[0]);let t=e.map(e=>typeof e==`string`?this.colFromString(e):e);return this.rows.push(t),t}shouldApplyLayoutDSL(...e){return e.length===1&&typeof e[0]==`string`&&/[\t\n]/.test(e[0])}applyLayoutDSL(e){let t=e.split(`
|
|
3
|
+
`).map(e=>e.split(` `)),n=0;return t.forEach(e=>{e.length>1&&O.stringWidth(e[0])>n&&(n=Math.min(Math.floor(this.width*.5),O.stringWidth(e[0])))}),t.forEach(e=>{this.div(...e.map((t,r)=>({text:t.trim(),padding:this.measurePadding(t),width:r===0&&e.length>1?n:void 0})))}),this.rows[this.rows.length-1]}colFromString(e){return{text:e,padding:this.measurePadding(e)}}measurePadding(e){let t=O.stripAnsi(e);return[0,t.match(/\s*$/)[0].length,0,t.match(/^\s*/)[0].length]}toString(){let e=[];return this.rows.forEach(t=>{this.rowToString(t,e)}),e.filter(e=>!e.hidden).map(e=>e.text).join(`
|
|
4
|
+
`)}rowToString(e,t){return this.rasterize(e).forEach((n,r)=>{let i=``;n.forEach((n,a)=>{let{width:o}=e[a],s=this.negatePadding(e[a]),c=n;if(s>O.stringWidth(n)&&(c+=` `.repeat(s-O.stringWidth(n))),e[a].align&&e[a].align!==`left`&&this.wrap){let t=ye[e[a].align];c=t(c,s),O.stringWidth(c)<s&&(c+=` `.repeat((o||0)-O.stringWidth(c)-1))}let l=e[a].padding||[0,0,0,0];l[3]&&(i+=` `.repeat(l[3])),i+=D(e[a],c,`| `),i+=c,i+=D(e[a],c,` |`),l[1]&&(i+=` `.repeat(l[1])),r===0&&t.length>0&&(i=this.renderInline(i,t[t.length-1]))}),t.push({text:i.replace(/ +$/,``),span:e.span})}),t}renderInline(e,t){let n=e.match(/^ */),r=n?n[0].length:0,i=t.text,a=O.stringWidth(i.trimRight());return t.span?this.wrap?r<a?e:(t.hidden=!0,i.trimRight()+` `.repeat(r-a)+e.trimLeft()):(t.hidden=!0,i+e):e}rasterize(e){let t=[],n=this.columnWidths(e),r;return e.forEach((e,i)=>{e.width=n[i],r=this.wrap?O.wrap(e.text,this.negatePadding(e),{hard:!0}).split(`
|
|
5
|
+
`):e.text.split(`
|
|
6
|
+
`),e.border&&(r.unshift(`.`+`-`.repeat(this.negatePadding(e)+2)+`.`),r.push(`'`+`-`.repeat(this.negatePadding(e)+2)+`'`)),e.padding&&(r.unshift(...Array(e.padding[0]||0).fill(``)),r.push(...Array(e.padding[2]||0).fill(``))),r.forEach((e,n)=>{t[n]||t.push([]);let r=t[n];for(let e=0;e<i;e++)r[e]===void 0&&r.push(``);r.push(e)})}),t}negatePadding(e){let t=e.width||0;return e.padding&&(t-=(e.padding[3]||0)+(e.padding[1]||0)),e.border&&(t-=4),t}columnWidths(e){if(!this.wrap)return e.map(e=>e.width||O.stringWidth(e.text));let t=e.length,n=this.width,r=e.map(e=>{if(e.width)return t--,n-=e.width,e.width}),i=t?Math.floor(n/t):0;return r.map((t,n)=>t===void 0?Math.max(i,xe(e[n])):t)}};function D(e,t,n){return e.border?/[.']-+[.']/.test(t)?``:t.trim().length===0?` `:n:``}function xe(e){let t=e.padding||[],n=1+(t[3]||0)+(t[1]||0);return e.border?n+4:n}function Se(){return typeof process==`object`&&process.stdout&&process.stdout.columns?process.stdout.columns:80}function Ce(e,t){e=e.trim();let n=O.stringWidth(e);return n<t?` `.repeat(t-n)+e:e}function we(e,t){e=e.trim();let n=O.stringWidth(e);return n>=t?e:` `.repeat(t-n>>1)+e}let O;function Te(e,t){return O=t,new be({width:e?.width||Se(),wrap:e?.wrap})}const Ee=[161,161,164,164,167,168,170,170,173,174,176,180,182,186,188,191,198,198,208,208,215,216,222,225,230,230,232,234,236,237,240,240,242,243,247,250,252,252,254,254,257,257,273,273,275,275,283,283,294,295,299,299,305,307,312,312,319,322,324,324,328,331,333,333,338,339,358,359,363,363,462,462,464,464,466,466,468,468,470,470,472,472,474,474,476,476,593,593,609,609,708,708,711,711,713,715,717,717,720,720,728,731,733,733,735,735,768,879,913,929,931,937,945,961,963,969,1025,1025,1040,1103,1105,1105,8208,8208,8211,8214,8216,8217,8220,8221,8224,8226,8228,8231,8240,8240,8242,8243,8245,8245,8251,8251,8254,8254,8308,8308,8319,8319,8321,8324,8364,8364,8451,8451,8453,8453,8457,8457,8467,8467,8470,8470,8481,8482,8486,8486,8491,8491,8531,8532,8539,8542,8544,8555,8560,8569,8585,8585,8592,8601,8632,8633,8658,8658,8660,8660,8679,8679,8704,8704,8706,8707,8711,8712,8715,8715,8719,8719,8721,8721,8725,8725,8730,8730,8733,8736,8739,8739,8741,8741,8743,8748,8750,8750,8756,8759,8764,8765,8776,8776,8780,8780,8786,8786,8800,8801,8804,8807,8810,8811,8814,8815,8834,8835,8838,8839,8853,8853,8857,8857,8869,8869,8895,8895,8978,8978,9312,9449,9451,9547,9552,9587,9600,9615,9618,9621,9632,9633,9635,9641,9650,9651,9654,9655,9660,9661,9664,9665,9670,9672,9675,9675,9678,9681,9698,9701,9711,9711,9733,9734,9737,9737,9742,9743,9756,9756,9758,9758,9792,9792,9794,9794,9824,9825,9827,9829,9831,9834,9836,9837,9839,9839,9886,9887,9919,9919,9926,9933,9935,9939,9941,9953,9955,9955,9960,9961,9963,9969,9972,9972,9974,9977,9979,9980,9982,9983,10045,10045,10102,10111,11094,11097,12872,12879,57344,63743,65024,65039,65533,65533,127232,127242,127248,127277,127280,127337,127344,127373,127375,127376,127387,127404,917760,917999,983040,1048573,1048576,1114109],De=[12288,12288,65281,65376,65504,65510],Oe=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],ke=(e,t)=>{let n=0,r=Math.floor(e.length/2)-1;for(;n<=r;){let i=Math.floor((n+r)/2),a=i*2;if(t<e[a])r=i-1;else if(t>e[a+1])n=i+1;else return!0}return!1},Ae=19968,[je,Me]=/* #__PURE__ */ Ne(Oe);function Ne(e){let t=e[0],n=e[1];for(let r=0;r<e.length;r+=2){let i=e[r],a=e[r+1];if(Ae>=i&&Ae<=a)return[i,a];a-i>n-t&&(t=i,n=a)}return[t,n]}const Pe=e=>e<161||e>1114109?!1:ke(Ee,e),Fe=e=>e<12288||e>65510?!1:ke(De,e),Ie=e=>e>=je&&e<=Me?!0:e<4352||e>262141?!1:ke(Oe,e);function Le(e){if(!Number.isSafeInteger(e))throw TypeError(`Expected a code point, got \`${typeof e}\`.`)}function Re(e,{ambiguousAsWide:t=!1}={}){return Le(e),Fe(e)||Ie(e)||t&&Pe(e)?2:1}var ze=/* @__PURE__ */ e((/* @__PURE__ */ t(((e,t)=>{t.exports=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g})))(),1);const Be=new Intl.Segmenter,Ve=/^\p{Default_Ignorable_Code_Point}$/u;function He(e,t={}){if(typeof e!=`string`||e.length===0)return 0;let{ambiguousIsNarrow:r=!0,countAnsiEscapeCodes:i=!1}=t;if(i||(e=n(e)),e.length===0)return 0;let a=0,o={ambiguousAsWide:!r};for(let{segment:t}of Be.segment(e)){let e=t.codePointAt(0);e<=31||e>=127&&e<=159||e>=8203&&e<=8207||e===65279||e>=768&&e<=879||e>=6832&&e<=6911||e>=7616&&e<=7679||e>=8400&&e<=8447||e>=65056&&e<=65071||e>=55296&&e<=57343||e>=65024&&e<=65039||Ve.test(t)||((0,ze.default)().test(t)?a+=2:a+=Re(e,o))}return a}const Ue=/* @__PURE__ */ new Set([`\x1B`,``]),We=`]8;;`,Ge=e=>`${Ue.values().next().value}[${e}m`,Ke=e=>`${Ue.values().next().value}${We}${e}`,qe=e=>e.split(` `).map(e=>He(e)),Je=(e,t,r)=>{let i=[...t],a=!1,o=!1,s=He(n(e.at(-1)));for(let[t,n]of i.entries()){let c=He(n);s+c<=r?e[e.length-1]+=n:(e.push(n),s=0),Ue.has(n)&&(a=!0,o=i.slice(t+1,t+1+4).join(``)===We),a?o?n===`\x07`&&(a=!1,o=!1):n===`m`&&(a=!1):(s+=c,s===r&&t<i.length-1&&(e.push(``),s=0))}!s&&e.at(-1).length>0&&e.length>1&&(e[e.length-2]+=e.pop())},Ye=e=>{let t=e.split(` `),n=t.length;for(;n>0&&!(He(t[n-1])>0);)n--;return n===t.length?e:t.slice(0,n).join(` `)+t.slice(n).join(``)},Xe=(e,t,n={})=>{if(n.trim!==!1&&e.trim()===``)return``;let i=``,a,o,s=qe(e),c=[``];for(let[r,i]of e.split(` `).entries()){n.trim!==!1&&(c[c.length-1]=c.at(-1).trimStart());let e=He(c.at(-1));if(r!==0&&(e>=t&&(n.wordWrap===!1||n.trim===!1)&&(c.push(``),e=0),(e>0||n.trim===!1)&&(c[c.length-1]+=` `,e++)),n.hard&&s[r]>t){let n=t-e,a=1+Math.floor((s[r]-n-1)/t);Math.floor((s[r]-1)/t)<a&&c.push(``),Je(c,i,t)}else{if(e+s[r]>t&&e>0&&s[r]>0){if(n.wordWrap===!1&&e<t){Je(c,i,t);continue}c.push(``)}e+s[r]>t&&n.wordWrap===!1?Je(c,i,t):c[c.length-1]+=i}}n.trim!==!1&&(c=c.map(e=>Ye(e)));let l=c.join(`
|
|
7
|
+
`),u=[...l],d=0;for(let[e,t]of u.entries()){if(i+=t,Ue.has(t)){let{groups:e}=RegExp(`(?:\\[(?<code>\\d+)m|\\${We}(?<uri>.*))`).exec(l.slice(d))||{groups:{}};if(e.code!==void 0){let t=Number.parseFloat(e.code);a=t===39?void 0:t}else e.uri!==void 0&&(o=e.uri.length===0?void 0:e.uri)}let n=r.codes.get(Number(a));u[e+1]===`
|
|
8
|
+
`?(o&&(i+=Ke(``)),a&&n&&(i+=Ge(n))):t===`
|
|
9
|
+
`&&(a&&n&&(i+=Ge(a)),o&&(i+=Ke(o))),d+=t.length}return i};function Ze(e,t,n){return String(e).normalize().replaceAll(`\r
|
|
10
|
+
`,`
|
|
11
|
+
`).split(`
|
|
12
|
+
`).map(e=>Xe(e,t,n)).join(`
|
|
13
|
+
`)}function Qe(e){return Te(e,{stringWidth:He,stripAnsi:n,wrap:Ze})}function $e(e,t){let n=T(`.`,e),r;for(E(n).isDirectory()||(n=oe(n));;){if(r=t(n,fe(n)),r)return T(n,r);if(n=oe(r=n),r===n)break}}
|
|
14
|
+
/**
|
|
15
|
+
* @license
|
|
16
|
+
* Copyright (c) 2016, Contributors
|
|
17
|
+
* SPDX-License-Identifier: ISC
|
|
18
|
+
*/
|
|
19
|
+
function et(e){if((e===e.toLowerCase()||e===e.toUpperCase())&&(e=e.toLowerCase()),e.indexOf(`-`)===-1&&e.indexOf(`_`)===-1)return e;{let t=``,n=!1,r=e.match(/^-+/);for(let i=r?r[0].length:0;i<e.length;i++){let r=e.charAt(i);n&&(n=!1,r=r.toUpperCase()),i!==0&&(r===`-`||r===`_`)?n=!0:r!==`-`&&r!==`_`&&(t+=r)}return t}}function tt(e,t){let n=e.toLowerCase();t||=`-`;let r=``;for(let i=0;i<e.length;i++){let a=n.charAt(i),o=e.charAt(i);r+=a!==o&&i>0?`${t}${n.charAt(i)}`:o}return r}function nt(e){return e==null?!1:typeof e==`number`||/^0x[0-9a-f]+$/i.test(e)?!0:!/^0[^.]/.test(e)&&/^[-]?(?:\d+(?:\.\d*)?|\.\d+)(e[-+]?\d+)?$/.test(e)}
|
|
20
|
+
/**
|
|
21
|
+
* @license
|
|
22
|
+
* Copyright (c) 2016, Contributors
|
|
23
|
+
* SPDX-License-Identifier: ISC
|
|
24
|
+
*/
|
|
25
|
+
function rt(e){if(Array.isArray(e))return e.map(e=>typeof e==`string`?e:e+``);e=e.trim();let t=0,n=null,r=null,i=null,a=[];for(let o=0;o<e.length;o++)n=r,r=e.charAt(o),r===` `&&!i?n!==` `&&t++:(r===i?i=null:r!==`'`&&r!==`"`||i||(i=r),a[t]||(a[t]=``),a[t]+=r);return a}
|
|
26
|
+
/**
|
|
27
|
+
* @license
|
|
28
|
+
* Copyright (c) 2016, Contributors
|
|
29
|
+
* SPDX-License-Identifier: ISC
|
|
30
|
+
*/
|
|
31
|
+
var k;(function(e){e.BOOLEAN=`boolean`,e.STRING=`string`,e.NUMBER=`number`,e.ARRAY=`array`})(k||={});
|
|
32
|
+
/**
|
|
33
|
+
* @license
|
|
34
|
+
* Copyright (c) 2016, Contributors
|
|
35
|
+
* SPDX-License-Identifier: ISC
|
|
36
|
+
*/
|
|
37
|
+
let A;var it=class{constructor(e){A=e}parse(e,t){let n=Object.assign({alias:void 0,array:void 0,boolean:void 0,config:void 0,configObjects:void 0,configuration:void 0,coerce:void 0,count:void 0,default:void 0,envPrefix:void 0,narg:void 0,normalize:void 0,string:void 0,number:void 0,__:void 0,key:void 0},t),r=rt(e),i=typeof e==`string`,a=at(Object.assign(Object.create(null),n.alias)),o=Object.assign({"boolean-negation":!0,"camel-case-expansion":!0,"combine-arrays":!1,"dot-notation":!0,"duplicate-arguments-array":!0,"flatten-duplicate-arrays":!0,"greedy-arrays":!0,"halt-at-non-option":!1,"nargs-eats-options":!1,"negation-prefix":`no-`,"parse-numbers":!0,"parse-positional-numbers":!0,"populate--":!1,"set-placeholder-key":!1,"short-option-groups":!0,"strip-aliased":!1,"strip-dashed":!1,"unknown-options-as-args":!1},n.configuration),s=Object.assign(Object.create(null),n.default),c=n.configObjects||[],l=n.envPrefix,u=o[`populate--`],d=u?`--`:`_`,f=Object.create(null),p=Object.create(null),m=n.__||A.format,h={aliases:Object.create(null),arrays:Object.create(null),bools:Object.create(null),strings:Object.create(null),numbers:Object.create(null),counts:Object.create(null),normalize:Object.create(null),configs:Object.create(null),nargs:Object.create(null),coercions:Object.create(null),keys:[]},g=/^-([0-9]+(\.[0-9]+)?|\.[0-9]+)$/,_=RegExp(`^--`+o[`negation-prefix`]+`(.+)`);[].concat(n.array||[]).filter(Boolean).forEach(function(e){let t=typeof e==`object`?e.key:e,n=Object.keys(e).map(function(e){return{boolean:`bools`,string:`strings`,number:`numbers`}[e]}).filter(Boolean).pop();n&&(h[n][t]=!0),h.arrays[t]=!0,h.keys.push(t)}),[].concat(n.boolean||[]).filter(Boolean).forEach(function(e){h.bools[e]=!0,h.keys.push(e)}),[].concat(n.string||[]).filter(Boolean).forEach(function(e){h.strings[e]=!0,h.keys.push(e)}),[].concat(n.number||[]).filter(Boolean).forEach(function(e){h.numbers[e]=!0,h.keys.push(e)}),[].concat(n.count||[]).filter(Boolean).forEach(function(e){h.counts[e]=!0,h.keys.push(e)}),[].concat(n.normalize||[]).filter(Boolean).forEach(function(e){h.normalize[e]=!0,h.keys.push(e)}),typeof n.narg==`object`&&Object.entries(n.narg).forEach(([e,t])=>{typeof t==`number`&&(h.nargs[e]=t,h.keys.push(e))}),typeof n.coerce==`object`&&Object.entries(n.coerce).forEach(([e,t])=>{typeof t==`function`&&(h.coercions[e]=t,h.keys.push(e))}),n.config!==void 0&&(Array.isArray(n.config)||typeof n.config==`string`?[].concat(n.config).filter(Boolean).forEach(function(e){h.configs[e]=!0}):typeof n.config==`object`&&Object.entries(n.config).forEach(([e,t])=>{(typeof t==`boolean`||typeof t==`function`)&&(h.configs[e]=t)})),fe(n.key,a,n.default,h.arrays),Object.keys(s).forEach(function(e){(h.aliases[e]||[]).forEach(function(t){s[t]=s[e]})});let v=null;xe();let y=[],b=Object.assign(Object.create(null),{_:[]}),ee={};for(let e=0;e<r.length;e++){let t=r[e],n=t.replace(/^-{3,}/,`---`),i,a,s,c,l,u;if(t!==`--`&&/^-/.test(t)&&ge(t))te(t);else if(n.match(/^---+(=|$)/)){te(t);continue}else if(t.match(/^--.+=/)||!o[`short-option-groups`]&&t.match(/^-.+=/))c=t.match(/^--?([^=]+)=([\s\S]*)$/),c!==null&&Array.isArray(c)&&c.length>=3&&(E(c[1],h.arrays)?e=x(e,c[1],r,c[2]):E(c[1],h.nargs)===!1?S(c[1],c[2],!0):e=ne(e,c[1],r,c[2]));else if(t.match(_)&&o[`boolean-negation`])c=t.match(_),c!==null&&Array.isArray(c)&&c.length>=2&&(a=c[1],S(a,E(a,h.arrays)?[!1]:!1));else if(t.match(/^--.+/)||!o[`short-option-groups`]&&t.match(/^-[^-]+/))c=t.match(/^--?(.+)/),c!==null&&Array.isArray(c)&&c.length>=2&&(a=c[1],E(a,h.arrays)?e=x(e,a,r):E(a,h.nargs)===!1?(l=r[e+1],l!==void 0&&(!l.match(/^-/)||l.match(g))&&!E(a,h.bools)&&!E(a,h.counts)||/^(true|false)$/.test(l)?(S(a,l),e++):S(a,ve(a))):e=ne(e,a,r));else if(t.match(/^-.\..+=/))c=t.match(/^-([^=]+)=([\s\S]*)$/),c!==null&&Array.isArray(c)&&c.length>=3&&S(c[1],c[2]);else if(t.match(/^-.\..+/)&&!t.match(g))l=r[e+1],c=t.match(/^-(.\..+)/),c!==null&&Array.isArray(c)&&c.length>=2&&(a=c[1],l!==void 0&&!l.match(/^-/)&&!E(a,h.bools)&&!E(a,h.counts)?(S(a,l),e++):S(a,ve(a)));else if(t.match(/^-[^-]+/)&&!t.match(g)){s=t.slice(1,-1).split(``),i=!1;for(let n=0;n<s.length;n++){if(l=t.slice(n+2),s[n+1]&&s[n+1]===`=`){u=t.slice(n+3),a=s[n],E(a,h.arrays)?e=x(e,a,r,u):E(a,h.nargs)===!1?S(a,u):e=ne(e,a,r,u),i=!0;break}if(l===`-`)S(s[n],l);else{if(/[A-Za-z]/.test(s[n])&&/^-?\d+(\.\d*)?(e-?\d+)?$/.test(l)&&E(l,h.bools)===!1||s[n+1]&&s[n+1].match(/\W/)){S(s[n],l),i=!0;break}S(s[n],ve(s[n]))}}a=t.slice(-1)[0],!i&&a!==`-`&&(E(a,h.arrays)?e=x(e,a,r):E(a,h.nargs)===!1?(l=r[e+1],l!==void 0&&(!/^(-|--)[^-]/.test(l)||l.match(g))&&!E(a,h.bools)&&!E(a,h.counts)||/^(true|false)$/.test(l)?(S(a,l),e++):S(a,ve(a))):e=ne(e,a,r))}else if(t.match(/^-[0-9]$/)&&t.match(g)&&E(t.slice(1),h.bools))a=t.slice(1),S(a,ve(a));else if(t===`--`){y=r.slice(e+1);break}else if(o[`halt-at-non-option`]){y=r.slice(e);break}else te(t)}se(b,!0),se(b,!1),ie(b),oe(),ue(b,h.aliases,s,!0),ce(b),o[`set-placeholder-key`]&&le(b),Object.keys(h.counts).forEach(function(e){T(b,e.split(`.`))||S(e,0)}),u&&y.length&&(b[d]=[]),y.forEach(function(e){b[d].push(e)}),o[`camel-case-expansion`]&&o[`strip-dashed`]&&Object.keys(b).filter(e=>e!==`--`&&e.includes(`-`)).forEach(e=>{delete b[e]}),o[`strip-aliased`]&&[].concat(...Object.keys(a).map(e=>a[e])).forEach(e=>{o[`camel-case-expansion`]&&e.includes(`-`)&&delete b[e.split(`.`).map(e=>et(e)).join(`.`)],delete b[e]});function te(e){let t=w(`_`,e);(typeof t==`string`||typeof t==`number`)&&b._.push(t)}function ne(e,t,n,r){let i,a=E(t,h.nargs);if(a=typeof a!=`number`||isNaN(a)?1:a,a===0)return D(r)||(v=Error(m(`Argument unexpected for: %s`,t))),S(t,ve(t)),e;let s=+!D(r);if(o[`nargs-eats-options`])n.length-(e+1)+s<a&&(v=Error(m(`Not enough arguments following: %s`,t))),s=a;else{for(i=e+1;i<n.length&&(!n[i].match(/^-[^0-9]/)||n[i].match(g)||ge(n[i]));i++)s++;s<a&&(v=Error(m(`Not enough arguments following: %s`,t)))}let c=Math.min(s,a);for(!D(r)&&c>0&&(S(t,r),c--),i=e+1;i<c+e+1;i++)S(t,n[i]);return e+c}function x(e,t,n,r){let a=[],c=r||n[e+1],l=E(t,h.nargs);if(E(t,h.bools)&&!/^(true|false)$/.test(c))a.push(!0);else if(D(c)||D(r)&&/^-/.test(c)&&!g.test(c)&&!ge(c)){if(s[t]!==void 0){let e=s[t];a=Array.isArray(e)?e:[e]}}else{D(r)||a.push(re(t,r,!0));for(let r=e+1;r<n.length&&!(!o[`greedy-arrays`]&&a.length>0||l&&typeof l==`number`&&a.length>=l||(c=n[r],/^-/.test(c)&&!g.test(c)&&!ge(c)));r++)e=r,a.push(re(t,c,i))}return typeof l==`number`&&(l&&a.length<l||isNaN(l)&&a.length===0)&&(v=Error(m(`Not enough arguments following: %s`,t))),S(t,a),e}function S(e,t,n=i){/-/.test(e)&&o[`camel-case-expansion`]&&C(e,e.split(`.`).map(function(e){return et(e)}).join(`.`));let r=re(e,t,n),a=e.split(`.`);de(b,a,r),h.aliases[e]&&h.aliases[e].forEach(function(e){let t=e.split(`.`);de(b,t,r)}),a.length>1&&o[`dot-notation`]&&(h.aliases[a[0]]||[]).forEach(function(t){let n=t.split(`.`),i=[].concat(a);i.shift(),n=n.concat(i),(h.aliases[e]||[]).includes(n.join(`.`))||de(b,n,r)}),E(e,h.normalize)&&!E(e,h.arrays)&&[e].concat(h.aliases[e]||[]).forEach(function(e){Object.defineProperty(ee,e,{enumerable:!0,get(){return t},set(e){t=typeof e==`string`?A.normalize(e):e}})})}function C(e,t){h.aliases[e]&&h.aliases[e].length||(h.aliases[e]=[t],f[t]=!0),h.aliases[t]&&h.aliases[t].length||C(t,e)}function re(e,t,n){n&&(t=ct(t)),(E(e,h.bools)||E(e,h.counts))&&typeof t==`string`&&(t=t===`true`);let r=Array.isArray(t)?t.map(function(t){return w(e,t)}):w(e,t);return E(e,h.counts)&&(D(r)||typeof r==`boolean`)&&(r=ot()),E(e,h.normalize)&&E(e,h.arrays)&&(r=Array.isArray(t)?t.map(e=>A.normalize(e)):A.normalize(t)),r}function w(e,t){return!o[`parse-positional-numbers`]&&e===`_`||!E(e,h.strings)&&!E(e,h.bools)&&!Array.isArray(t)&&(nt(t)&&o[`parse-numbers`]&&Number.isSafeInteger(Math.floor(parseFloat(`${t}`)))||!D(t)&&E(e,h.numbers))&&(t=Number(t)),t}function ie(e){let t=Object.create(null);ue(t,h.aliases,s),Object.keys(h.configs).forEach(function(n){let r=e[n]||t[n];if(r)try{let e=null,t=A.resolve(A.cwd(),r),i=h.configs[n];if(typeof i==`function`){try{e=i(t)}catch(t){e=t}if(e instanceof Error){v=e;return}}else e=A.require(t);ae(e)}catch(t){t.name===`PermissionDenied`?v=t:e[n]&&(v=Error(m(`Invalid JSON config file: %s`,r)))}})}function ae(e,t){Object.keys(e).forEach(function(n){let r=e[n],i=t?t+`.`+n:n;typeof r==`object`&&r&&!Array.isArray(r)&&o[`dot-notation`]?ae(r,i):(!T(b,i.split(`.`))||E(i,h.arrays)&&o[`combine-arrays`])&&S(i,r)})}function oe(){c!==void 0&&c.forEach(function(e){ae(e)})}function se(e,t){if(l===void 0)return;let n=typeof l==`string`?l:``,r=A.env();Object.keys(r).forEach(function(i){if(n===``||i.lastIndexOf(n,0)===0){let a=i.split(`__`).map(function(e,t){return t===0&&(e=e.substring(n.length)),et(e)});(t&&h.configs[a.join(`.`)]||!t)&&!T(e,a)&&S(a.join(`.`),r[i])}})}function ce(e){let t,n=/* @__PURE__ */ new Set;Object.keys(e).forEach(function(r){if(!n.has(r)&&(t=E(r,h.coercions),typeof t==`function`))try{let i=w(r,t(e[r]));[].concat(h.aliases[r]||[],r).forEach(t=>{n.add(t),e[t]=i})}catch(e){v=e}})}function le(e){return h.keys.forEach(t=>{~t.indexOf(`.`)||e[t]===void 0&&(e[t]=void 0)}),e}function ue(e,t,n,r=!1){Object.keys(n).forEach(function(i){T(e,i.split(`.`))||(de(e,i.split(`.`),n[i]),r&&(p[i]=!0),(t[i]||[]).forEach(function(t){T(e,t.split(`.`))||de(e,t.split(`.`),n[i])}))})}function T(e,t){let n=e;o[`dot-notation`]||(t=[t.join(`.`)]),t.slice(0,-1).forEach(function(e){n=n[e]||{}});let r=t[t.length-1];return typeof n==`object`&&r in n}function de(e,t,n){let r=e;o[`dot-notation`]||(t=[t.join(`.`)]),t.slice(0,-1).forEach(function(e){e=st(e),typeof r==`object`&&r[e]===void 0&&(r[e]={}),typeof r[e]!=`object`||Array.isArray(r[e])?(Array.isArray(r[e])?r[e].push({}):r[e]=[r[e],{}],r=r[e][r[e].length-1]):r=r[e]});let i=st(t[t.length-1]),a=E(t.join(`.`),h.arrays),s=Array.isArray(n),c=o[`duplicate-arguments-array`];!c&&E(i,h.nargs)&&(c=!0,(!D(r[i])&&h.nargs[i]===1||Array.isArray(r[i])&&r[i].length===h.nargs[i])&&(r[i]=void 0)),n===ot()?r[i]=ot(r[i]):Array.isArray(r[i])?c&&a&&s?r[i]=o[`flatten-duplicate-arrays`]?r[i].concat(n):(Array.isArray(r[i][0])?r[i]:[r[i]]).concat([n]):!c&&!!a==!!s?r[i]=n:r[i]=r[i].concat([n]):r[i]===void 0&&a?r[i]=s?n:[n]:c&&!(r[i]===void 0||E(i,h.counts)||E(i,h.bools))?r[i]=[r[i],n]:r[i]=n}function fe(...e){e.forEach(function(e){Object.keys(e||{}).forEach(function(e){h.aliases[e]||(h.aliases[e]=[].concat(a[e]||[]),h.aliases[e].concat(e).forEach(function(t){if(/-/.test(t)&&o[`camel-case-expansion`]){let n=et(t);n!==e&&h.aliases[e].indexOf(n)===-1&&(h.aliases[e].push(n),f[n]=!0)}}),h.aliases[e].concat(e).forEach(function(t){if(t.length>1&&/[A-Z]/.test(t)&&o[`camel-case-expansion`]){let n=tt(t,`-`);n!==e&&h.aliases[e].indexOf(n)===-1&&(h.aliases[e].push(n),f[n]=!0)}}),h.aliases[e].forEach(function(t){h.aliases[t]=[e].concat(h.aliases[e].filter(function(e){return t!==e}))}))})})}function E(e,t){let n=[].concat(h.aliases[e]||[],e),r=Object.keys(t),i=n.find(e=>r.includes(e));return i?t[i]:!1}function pe(e){let t=Object.keys(h);return[].concat(t.map(e=>h[e])).some(function(t){return Array.isArray(t)?t.includes(e):t[e]})}function me(e,...t){return[].concat(...t).some(function(t){let n=e.match(t);return n&&pe(n[1])})}function he(e){if(e.match(g)||!e.match(/^-[^-]+/))return!1;let t=!0,n,r=e.slice(1).split(``);for(let i=0;i<r.length;i++){if(n=e.slice(i+2),!pe(r[i])){t=!1;break}if(r[i+1]&&r[i+1]===`=`||n===`-`||/[A-Za-z]/.test(r[i])&&/^-?\d+(\.\d*)?(e-?\d+)?$/.test(n)||r[i+1]&&r[i+1].match(/\W/))break}return t}function ge(e){return o[`unknown-options-as-args`]&&_e(e)}function _e(e){return e=e.replace(/^-{3,}/,`--`),e.match(g)||he(e)?!1:!me(e,/^-+([^=]+?)=[\s\S]*$/,_,/^-+([^=]+?)$/,/^-+([^=]+?)-$/,/^-+([^=]+?\d+)$/,/^-+([^=]+?)\W+.*$/)}function ve(e){return!E(e,h.bools)&&!E(e,h.counts)&&`${e}`in s?s[e]:ye(be(e))}function ye(e){return{[k.BOOLEAN]:!0,[k.STRING]:``,[k.NUMBER]:void 0,[k.ARRAY]:[]}[e]}function be(e){let t=k.BOOLEAN;return E(e,h.strings)?t=k.STRING:E(e,h.numbers)?t=k.NUMBER:E(e,h.bools)?t=k.BOOLEAN:E(e,h.arrays)&&(t=k.ARRAY),t}function D(e){return e===void 0}function xe(){Object.keys(h.counts).find(e=>E(e,h.arrays)?(v=Error(m(`Invalid configuration: %s, opts.count excludes opts.array.`,e)),!0):E(e,h.nargs)?(v=Error(m(`Invalid configuration: %s, opts.count excludes opts.narg.`,e)),!0):!1)}return{aliases:Object.assign({},h.aliases),argv:Object.assign(ee,b),configuration:o,defaulted:Object.assign({},p),error:v,newAliases:Object.assign({},f)}}};function at(e){let t=[],n=Object.create(null),r=!0;for(Object.keys(e).forEach(function(n){t.push([].concat(e[n],n))});r;){r=!1;for(let e=0;e<t.length;e++)for(let n=e+1;n<t.length;n++)if(t[e].filter(function(e){return t[n].indexOf(e)!==-1}).length){t[e]=t[e].concat(t[n]),t.splice(n,1),r=!0;break}}return t.forEach(function(e){e=e.filter(function(e,t,n){return n.indexOf(e)===t});let t=e.pop();t!==void 0&&typeof t==`string`&&(n[t]=e)}),n}function ot(e){return e===void 0?1:e+1}function st(e){return e===`__proto__`?`___proto___`:e}function ct(e){return typeof e==`string`&&(e[0]===`'`||e[0]===`"`)&&e[e.length-1]===e[0]?e.substring(1,e.length-1):e}
|
|
38
|
+
/**
|
|
39
|
+
* @fileoverview Main entrypoint for libraries using yargs-parser in Node.js
|
|
40
|
+
*
|
|
41
|
+
* @license
|
|
42
|
+
* Copyright (c) 2016, Contributors
|
|
43
|
+
* SPDX-License-Identifier: ISC
|
|
44
|
+
*/
|
|
45
|
+
const lt=process&&process.env&&process.env.YARGS_MIN_NODE_VERSION?Number(process.env.YARGS_MIN_NODE_VERSION):20,ut=(process==null?void 0:process.versions)?.node??(process==null?void 0:process.version)?.slice(1);if(ut&&Number(ut.match(/^([^.]+)/)[1])<lt)throw Error(`yargs parser supports a minimum Node.js version of ${lt}. Read our version support policy: https://github.com/yargs/yargs-parser#supported-nodejs-versions`);const dt=process?process.env:{},ft=C?C(import.meta.url):void 0,pt=new it({cwd:process.cwd,env:()=>dt,format:me,normalize:le,resolve:T,require:e=>{if(ft!==void 0)return ft(e);if(e.match(/\.json$/))return JSON.parse(de(e,`utf8`));throw Error(`only .json config files are supported in ESM`)}}),mt=function(e,t){return pt.parse(e.slice(),t).argv};mt.detailed=function(e,t){return pt.parse(e.slice(),t)},mt.camelCase=et,mt.decamelize=tt,mt.looksLikeNumber=nt;function ht(){return+!gt()}function gt(){return _t()&&!process.defaultApp}function _t(){return!!process.versions.electron}function vt(e){return e.slice(ht()+1)}function yt(){return process.argv[ht()]}const bt=new Intl.Segmenter,xt=/[^\p{Default_Ignorable_Code_Point}\p{Control}\p{Format}\p{Nonspacing_Mark}\p{Enclosing_Mark}\p{Surrogate}]/v,St=/\p{Spacing_Mark}/v,Ct=/^\p{RGI_Emoji}$/v,wt=/^[\d#*]\u20E3$/,Tt=/\p{Extended_Pictographic}/gu;function Et(e){if(e.length>50)return!1;if(wt.test(e))return!0;if(e.includes(``)){let t=e.match(Tt);return t!==null&&t.length>=2}return!1}function Dt(e){let t=e.search(xt);return t===-1?void 0:e.slice(t)}function Ot(e){return e>=4352&&e<=4447||e>=43360&&e<=43388}function kt(e){return e>=4448&&e<=4519||e>=55216&&e<=55238}function At(e){return e>=4520&&e<=4607||e>=55243&&e<=55291}function jt(e){return Ot(e)||kt(e)||At(e)}function Mt(e,t){let n=[];for(let t of e)xt.test(t)&&n.push(t.codePointAt(0));if(n.length===0)return;let r=0;for(let e=0;e<n.length;e++){let i=n[e];if(!jt(i)){if(r===0)return;for(let i=e;i<n.length;i++)r+=Re(n[i],t);return r}Ot(i)&&kt(n[e+1])?(r+=2,e+=At(n[e+2])?2:1):r+=Re(i,t)}return r}function Nt(e,t){let n=0,r=!0;for(let i of e)r?r=!1:(St.test(i)||i>=``&&i<=``)&&(n+=Re(i.codePointAt(0),t));return n}function Pt(e,t={}){if(typeof e!=`string`||e.length===0)return 0;let{ambiguousIsNarrow:r=!0,countAnsiEscapeCodes:i=!1}=t,a=e;if(!i&&(a.includes(`\x1B`)||a.includes(``))&&(a=n(a)),a.length===0)return 0;if(/^[\u0020-\u007E]*$/.test(a))return a.length;let o=0,s={ambiguousAsWide:!r};for(let{segment:e}of bt.segment(a)){let t=Dt(e);if(t===void 0)continue;if(Ct.test(e)||Et(e)){o+=2;continue}let n=Mt(t,s);if(n!==void 0){o+=n;continue}let r=t.codePointAt(0);o+=Re(r,s),o+=Nt(t,s)}return o}var Ft={fs:{readFileSync:de,writeFile:pe},format:me,resolve:T,exists:e=>{try{return E(e).isFile()}catch{return!1}}};let j;var It=class{constructor(e){e||={},this.directory=e.directory||`./locales`,this.updateFiles=typeof e.updateFiles!=`boolean`||e.updateFiles,this.locale=e.locale||`en`,this.fallbackToLanguage=typeof e.fallbackToLanguage!=`boolean`||e.fallbackToLanguage,this.cache=Object.create(null),this.writeQueue=[]}__(...e){if(typeof arguments[0]!=`string`)return this._taggedLiteral(arguments[0],...arguments);let t=e.shift(),n=function(){};return typeof e[e.length-1]==`function`&&(n=e.pop()),n||=function(){},this.cache[this.locale]||this._readLocaleFile(),!this.cache[this.locale][t]&&this.updateFiles?(this.cache[this.locale][t]=t,this._enqueueWrite({directory:this.directory,locale:this.locale,cb:n})):n(),j.format.apply(j.format,[this.cache[this.locale][t]||t].concat(e))}__n(){let e=Array.prototype.slice.call(arguments),t=e.shift(),n=e.shift(),r=e.shift(),i=function(){};typeof e[e.length-1]==`function`&&(i=e.pop()),this.cache[this.locale]||this._readLocaleFile();let a=r===1?t:n;this.cache[this.locale][t]&&(a=this.cache[this.locale][t][r===1?`one`:`other`]),!this.cache[this.locale][t]&&this.updateFiles?(this.cache[this.locale][t]={one:t,other:n},this._enqueueWrite({directory:this.directory,locale:this.locale,cb:i})):i();let o=[a];return~a.indexOf(`%d`)&&o.push(r),j.format.apply(j.format,o.concat(e))}setLocale(e){this.locale=e}getLocale(){return this.locale}updateLocale(e){this.cache[this.locale]||this._readLocaleFile();for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(this.cache[this.locale][t]=e[t])}_taggedLiteral(e,...t){let n=``;return e.forEach(function(e,r){let i=t[r+1];n+=e,i!==void 0&&(n+=`%s`)}),this.__.apply(this,[n].concat([].slice.call(t,1)))}_enqueueWrite(e){this.writeQueue.push(e),this.writeQueue.length===1&&this._processWriteQueue()}_processWriteQueue(){let e=this,t=this.writeQueue[0],n=t.directory,r=t.locale,i=t.cb,a=this._resolveLocaleFile(n,r),o=JSON.stringify(this.cache[r],null,2);j.fs.writeFile(a,o,`utf-8`,function(t){e.writeQueue.shift(),e.writeQueue.length>0&&e._processWriteQueue(),i(t)})}_readLocaleFile(){let e={},t=this._resolveLocaleFile(this.directory,this.locale);try{j.fs.readFileSync&&(e=JSON.parse(j.fs.readFileSync(t,`utf-8`)))}catch(n){if(n instanceof SyntaxError&&(n.message=`syntax error in `+t),n.code===`ENOENT`)e={};else throw n}this.cache[this.locale]=e}_resolveLocaleFile(e,t){let n=j.resolve(e,`./`,t+`.json`);if(this.fallbackToLanguage&&!this._fileExistsSync(n)&&~t.lastIndexOf(`_`)){let r=j.resolve(e,`./`,t.split(`_`)[0]+`.json`);this._fileExistsSync(r)&&(n=r)}return n}_fileExistsSync(e){return j.exists(e)}};function Lt(e,t){j=t;let n=new It(e);return{__:n.__.bind(n),__n:n.__n.bind(n),setLocale:n.setLocale.bind(n),getLocale:n.getLocale.bind(n),updateLocale:n.updateLocale.bind(n),locale:n.locale}}const Rt=e=>Lt(e,Ft);var zt=/* @__PURE__ */ e((/* @__PURE__ */ t(((e,t)=>{t.exports=function(e){if(e===void 0&&(e=2),e>=Error.stackTraceLimit)throw TypeError("getCallerFile(position) requires position be less then Error.stackTraceLimit but position was: `"+e+"` and Error.stackTraceLimit was: `"+Error.stackTraceLimit+"`");var t=Error.prepareStackTrace;Error.prepareStackTrace=function(e,t){return t};var n=(/* @__PURE__ */ Error()).stack;if(Error.prepareStackTrace=t,typeof n==`object`&&n)return n[e]?n[e].getFileName():void 0}})))(),1);const Bt=ge(import.meta.url),Vt=Bt.substring(0,Bt.lastIndexOf(`node_modules`)),Ht=C(import.meta.url);var Ut={assert:{notStrictEqual:w,strictEqual:ie},cliui:Qe,findUp:$e,getEnv:e=>process.env[e],inspect:he,getProcessArgvBin:yt,mainFilename:Vt||process.cwd(),Parser:mt,path:{basename:ae,dirname:oe,extname:se,relative:ue,resolve:T,join:ce},process:{argv:()=>process.argv,cwd:process.cwd,emitWarning:(e,t)=>process.emitWarning(e,t),execPath:()=>process.execPath,exit:e=>{process.exit(e)},nextTick:process.nextTick,stdColumns:process.stdout.columns===void 0?null:process.stdout.columns},readFileSync:_e,readdirSync:ve,require:Ht,getCallerFile:()=>{let e=(0,zt.default)(3);return e.match(/^file:\/\//)?ge(e):e},stringWidth:Pt,y18n:Rt({directory:T(Bt,`../../../locales`),updateFiles:!1})};function M(e,t,n,r){n.assert.notStrictEqual(e,t,r)}function Wt(e,t){t.assert.strictEqual(typeof e,`string`)}function Gt(e){return Object.keys(e)}function N(e){return!!e&&!!e.then&&typeof e.then==`function`}var P=class e extends Error{constructor(t){super(t||`yargs error`),this.name=`YError`,Error.captureStackTrace&&Error.captureStackTrace(this,e)}};function Kt(e){let t=e.replace(/\s{2,}/g,` `).split(/\s+(?![^[]*]|[^<]*>)/),n=/\.*[\][<>]/g,r=t.shift();if(!r)throw Error(`No command found in: ${e}`);let i={cmd:r.replace(n,``),demanded:[],optional:[]};return t.forEach((e,r)=>{let a=!1;e=e.replace(/\s/g,``),/\.+[\]>]/.test(e)&&r===t.length-1&&(a=!0),/^\[/.test(e)?i.optional.push({cmd:e.replace(n,``).split(`|`),variadic:a}):i.demanded.push({cmd:e.replace(n,``).split(`|`),variadic:a})}),i}const qt=[`first`,`second`,`third`,`fourth`,`fifth`,`sixth`];function F(e,t,n){function r(){return typeof e==`object`?[{demanded:[],optional:[]},e,t]:[Kt(`cmd ${e}`),t,n]}try{let e=0,[t,n,i]=r(),a=[].slice.call(n);for(;a.length&&a[a.length-1]===void 0;)a.pop();let o=i||a.length;if(o<t.demanded.length)throw new P(`Not enough arguments provided. Expected ${t.demanded.length} but received ${a.length}.`);let s=t.demanded.length+t.optional.length;if(o>s)throw new P(`Too many arguments provided. Expected max ${s} but received ${o}.`);t.demanded.forEach(t=>{let n=Jt(a.shift());t.cmd.filter(e=>e===n||e===`*`).length===0&&Yt(n,t.cmd,e),e+=1}),t.optional.forEach(t=>{if(a.length===0)return;let n=Jt(a.shift());t.cmd.filter(e=>e===n||e===`*`).length===0&&Yt(n,t.cmd,e),e+=1})}catch(e){console.warn(e.stack)}}function Jt(e){return Array.isArray(e)?`array`:e===null?`null`:typeof e}function Yt(e,t,n){throw new P(`Invalid ${qt[n]||`manyith`} argument. Expected ${t.join(` or `)} but received ${e}.`)}var Xt=class{constructor(e){this.globalMiddleware=[],this.frozens=[],this.yargs=e}addMiddleware(e,t,n=!0,r=!1){if(F(`<array|function> [boolean] [boolean] [boolean]`,[e,t,n],arguments.length),Array.isArray(e)){for(let r=0;r<e.length;r++){if(typeof e[r]!=`function`)throw Error(`middleware must be a function`);let i=e[r];i.applyBeforeValidation=t,i.global=n}Array.prototype.push.apply(this.globalMiddleware,e)}else if(typeof e==`function`){let i=e;i.applyBeforeValidation=t,i.global=n,i.mutates=r,this.globalMiddleware.push(e)}return this.yargs}addCoerceMiddleware(e,t){let n=this.yargs.getAliases();return this.globalMiddleware=this.globalMiddleware.filter(e=>{let r=[...n[t]||[],t];return!e.option||!r.includes(e.option)}),e.option=t,this.addMiddleware(e,!0,!0,!0)}getMiddleware(){return this.globalMiddleware}freeze(){this.frozens.push([...this.globalMiddleware])}unfreeze(){let e=this.frozens.pop();e!==void 0&&(this.globalMiddleware=e)}reset(){this.globalMiddleware=this.globalMiddleware.filter(e=>e.global)}};function Zt(e){return e?e.map(e=>(e.applyBeforeValidation=!1,e)):[]}function Qt(e,t,n,r){return n.reduce((e,n)=>{if(n.applyBeforeValidation!==r)return e;if(n.mutates){if(n.applied)return e;n.applied=!0}if(N(e))return e.then(e=>Promise.all([e,n(e,t)])).then(([e,t])=>Object.assign(e,t));{let r=n(e,t);return N(r)?r.then(t=>Object.assign(e,t)):Object.assign(e,r)}},e)}function $t(e,t,n=e=>{throw e}){try{let n=en(e)?e():e;return N(n)?n.then(e=>t(e)):t(n)}catch(e){return n(e)}}function en(e){return typeof e==`function`}const tn=/(^\*)|(^\$0)/;var nn=class{constructor(e,t,n,r){this.requireCache=/* @__PURE__ */ new Set,this.handlers={},this.aliasMap={},this.frozens=[],this.shim=r,this.usage=e,this.globalMiddleware=n,this.validation=t}addDirectory(e,t,n,r){r||={},this.requireCache.add(n);let i=this.shim.path.resolve(this.shim.path.dirname(n),e),a=this.shim.readdirSync(i,{recursive:!!r.recurse});Array.isArray(r.extensions)||(r.extensions=[`js`]);let o=typeof r.visit==`function`?r.visit:e=>e;for(let e of a){let n=e.toString();if(r.exclude){let e=!1;if(e=typeof r.exclude==`function`?r.exclude(n):r.exclude.test(n),e)continue}if(r.include){let e=!1;if(e=typeof r.include==`function`?r.include(n):r.include.test(n),!e)continue}let a=!1;for(let e of r.extensions)n.endsWith(e)&&(a=!0);if(a){let e=this.shim.path.join(i,n),r=t(e),a=Object.create(null,Object.getOwnPropertyDescriptors({...r}));if(o(a,e,n)){if(this.requireCache.has(e))continue;this.requireCache.add(e),a.command||=this.shim.path.basename(e,this.shim.path.extname(e)),this.addHandler(a)}}}}addHandler(e,t,n,r,i,a){let o=[],s=Zt(i);if(r||=(()=>{}),Array.isArray(e)){if(on(e))[e,...o]=e;else for(let t of e)this.addHandler(t)}else if(ln(e)){let t=Array.isArray(e.command)||typeof e.command==`string`?e.command:null;if(t===null)throw Error(`No command name given for module: ${this.shim.inspect(e)}`);e.aliases&&(t=[].concat(t,e.aliases)),this.addHandler(t,this.extractDesc(e),e.builder,e.handler,e.middlewares,e.deprecated);return}else if(an(n)){this.addHandler([e].concat(o),t,n.builder,n.handler,n.middlewares,n.deprecated);return}if(typeof e==`string`){let i=Kt(e);o=o.map(e=>Kt(e).cmd);let c=!1,l=[i.cmd].concat(o).filter(e=>!tn.test(e)||(c=!0,!1));l.length===0&&c&&l.push(`$0`),c&&(i.cmd=l[0],o=l.slice(1),e=e.replace(tn,i.cmd)),o.forEach(e=>{this.aliasMap[e]=i.cmd}),t!==!1&&this.usage.command(e,t,c,o,a),this.handlers[i.cmd]={original:e,description:t,handler:r,builder:n||{},middlewares:s,deprecated:a,demanded:i.demanded,optional:i.optional},c&&(this.defaultCommand=this.handlers[i.cmd])}}getCommandHandlers(){return this.handlers}getCommands(){return Object.keys(this.handlers).concat(Object.keys(this.aliasMap))}hasDefaultCommand(){return!!this.defaultCommand}runCommand(e,t,n,r,i,a){let o=this.handlers[e]||this.handlers[this.aliasMap[e]]||this.defaultCommand,s=t.getInternalMethods().getContext(),c=s.commands.slice(),l=!e;e&&(s.commands.push(e),s.fullCommands.push(o.original));let u=this.applyBuilderUpdateUsageAndParse(l,o,t,n.aliases,c,r,i,a);return N(u)?u.then(e=>this.applyMiddlewareAndGetResult(l,o,e.innerArgv,s,i,e.aliases,t)):this.applyMiddlewareAndGetResult(l,o,u.innerArgv,s,i,u.aliases,t)}applyBuilderUpdateUsageAndParse(e,t,n,r,i,a,o,s){let c=t.builder,l=n;if(sn(c)){n.getInternalMethods().getUsageInstance().freeze();let u=c(n.getInternalMethods().reset(r),s);if(N(u))return u.then(r=>(l=Pr(r)?r:n,this.parseAndUpdateUsage(e,t,l,i,a,o)))}else cn(c)&&(n.getInternalMethods().getUsageInstance().freeze(),l=n.getInternalMethods().reset(r),Object.keys(t.builder).forEach(e=>{l.option(e,c[e])}));return this.parseAndUpdateUsage(e,t,l,i,a,o)}parseAndUpdateUsage(e,t,n,r,i,a){e&&n.getInternalMethods().getUsageInstance().unfreeze(!0),this.shouldUpdateUsage(n)&&n.getInternalMethods().getUsageInstance().usage(this.usageFromParentCommandsCommandHandler(r,t),t.description);let o=n.getInternalMethods().runYargsParserAndExecuteCommands(null,void 0,!0,i,a);return N(o)?o.then(e=>({aliases:n.parsed.aliases,innerArgv:e})):{aliases:n.parsed.aliases,innerArgv:o}}shouldUpdateUsage(e){return!e.getInternalMethods().getUsageInstance().getUsageDisabled()&&e.getInternalMethods().getUsageInstance().getUsage().length===0}usageFromParentCommandsCommandHandler(e,t){let n=tn.test(t.original)?t.original.replace(tn,``).trim():t.original,r=e.filter(e=>!tn.test(e));return r.push(n),`$0 ${r.join(` `)}`}handleValidationAndGetResult(e,t,n,r,i,a,o,s){if(!a.getInternalMethods().getHasOutput()){let t=a.getInternalMethods().runValidation(i,s,a.parsed.error,e);n=$t(n,e=>(t(e),e))}if(t.handler&&!a.getInternalMethods().getHasOutput()){a.getInternalMethods().setHasOutput();let r=!!a.getOptions().configuration[`populate--`];a.getInternalMethods().postProcess(n,r,!1,!1),n=Qt(n,a,o,!1),n=$t(n,e=>{let n=t.handler(e);return N(n)?n.then(()=>e):e}),e||a.getInternalMethods().getUsageInstance().cacheHelpMessage(),N(n)&&!a.getInternalMethods().hasParseCallback()&&n.catch(e=>{try{a.getInternalMethods().getUsageInstance().fail(null,e)}catch{}})}return e||(r.commands.pop(),r.fullCommands.pop()),n}applyMiddlewareAndGetResult(e,t,n,r,i,a,o){let s={};if(i)return n;o.getInternalMethods().getHasOutput()||(s=this.populatePositionals(t,n,r,o));let c=this.globalMiddleware.getMiddleware().slice(0).concat(t.middlewares),l=Qt(n,o,c,!0);return N(l)?l.then(n=>this.handleValidationAndGetResult(e,t,n,r,a,o,c,s)):this.handleValidationAndGetResult(e,t,l,r,a,o,c,s)}populatePositionals(e,t,n,r){t._=t._.slice(n.commands.length);let i=e.demanded.slice(0),a=e.optional.slice(0),o={};for(this.validation.positionalCount(i.length,t._.length);i.length;){let e=i.shift();this.populatePositional(e,t,o)}for(;a.length;){let e=a.shift();this.populatePositional(e,t,o)}return t._=n.commands.concat(t._.map(e=>``+e)),this.postProcessPositionals(t,o,this.cmdToParseOptions(e.original),r),o}populatePositional(e,t,n){let r=e.cmd[0];e.variadic?n[r]=t._.splice(0).map(String):t._.length&&(n[r]=[String(t._.shift())])}cmdToParseOptions(e){let t={array:[],default:{},alias:{},demand:{}},n=Kt(e);return n.demanded.forEach(e=>{let[n,...r]=e.cmd;e.variadic&&(t.array.push(n),t.default[n]=[]),t.alias[n]=r,t.demand[n]=!0}),n.optional.forEach(e=>{let[n,...r]=e.cmd;e.variadic&&(t.array.push(n),t.default[n]=[]),t.alias[n]=r}),t}postProcessPositionals(e,t,n,r){let i=Object.assign({},r.getOptions());i.default=Object.assign(n.default,i.default);for(let e of Object.keys(n.alias))i.alias[e]=(i.alias[e]||[]).concat(n.alias[e]);i.array=i.array.concat(n.array),i.config={};let a=[];if(Object.keys(t).forEach(e=>{t[e].map(t=>{i.configuration[`unknown-options-as-args`]&&(i.key[e]=!0),a.push(`--${e}`),a.push(t)})}),!a.length)return;let o=Object.assign({},i.configuration,{"populate--":!1}),s=this.shim.Parser.detailed(a,Object.assign({},i,{configuration:o}));if(s.error)r.getInternalMethods().getUsageInstance().fail(s.error.message,s.error);else{let n=Object.keys(t);Object.keys(t).forEach(e=>{n.push(...s.aliases[e])}),Object.keys(s.argv).forEach(i=>{n.includes(i)&&(t[i]||(t[i]=s.argv[i]),e[i]=!this.isInConfigs(r,i)&&!this.isDefaulted(r,i)&&Object.prototype.hasOwnProperty.call(e,i)&&Object.prototype.hasOwnProperty.call(s.argv,i)&&(Array.isArray(e[i])||Array.isArray(s.argv[i]))?[].concat(e[i],s.argv[i]):s.argv[i])})}}isDefaulted(e,t){let{default:n}=e.getOptions();return Object.prototype.hasOwnProperty.call(n,t)||Object.prototype.hasOwnProperty.call(n,this.shim.Parser.camelCase(t))}isInConfigs(e,t){let{configObjects:n}=e.getOptions();return n.some(e=>Object.prototype.hasOwnProperty.call(e,t))||n.some(e=>Object.prototype.hasOwnProperty.call(e,this.shim.Parser.camelCase(t)))}runDefaultBuilderOn(e){if(!this.defaultCommand)return;if(this.shouldUpdateUsage(e)){let t=tn.test(this.defaultCommand.original)?this.defaultCommand.original:this.defaultCommand.original.replace(/^[^[\]<>]*/,`$0 `);e.getInternalMethods().getUsageInstance().usage(t,this.defaultCommand.description)}let t=this.defaultCommand.builder;if(sn(t))return t(e,!0);an(t)||Object.keys(t).forEach(n=>{e.option(n,t[n])})}extractDesc({describe:e,description:t,desc:n}){for(let r of[e,t,n]){if(typeof r==`string`||r===!1)return r;M(r,!0,this.shim)}return!1}freeze(){this.frozens.push({handlers:this.handlers,aliasMap:this.aliasMap,defaultCommand:this.defaultCommand})}unfreeze(){let e=this.frozens.pop();M(e,void 0,this.shim),{handlers:this.handlers,aliasMap:this.aliasMap,defaultCommand:this.defaultCommand}=e}reset(){return this.handlers={},this.aliasMap={},this.defaultCommand=void 0,this.requireCache=/* @__PURE__ */ new Set,this}};function rn(e,t,n,r){return new nn(e,t,n,r)}function an(e){return typeof e==`object`&&!!e.builder&&typeof e.handler==`function`}function on(e){return e.every(e=>typeof e==`string`)}function sn(e){return typeof e==`function`}function cn(e){return typeof e==`object`}function ln(e){return typeof e==`object`&&!Array.isArray(e)}function un(e={},t=()=>!0){let n={};return Gt(e).forEach(r=>{t(r,e[r])&&(n[r]=e[r])}),n}function dn(e){typeof process<`u`&&[process.stdout,process.stderr].forEach(t=>{let n=t;n._handle&&n.isTTY&&typeof n._handle.setBlocking==`function`&&n._handle.setBlocking(e)})}function fn(e){return typeof e==`boolean`}function pn(e,t){let n=t.y18n.__,r={},i=[];r.failFn=function(e){i.push(e)};let a=null,o=null,s=!0;r.showHelpOnFail=function(t=!0,n){let[i,c]=typeof t==`string`?[!0,t]:[t,n];return e.getInternalMethods().isGlobalContext()&&(o=c),a=c,s=i,r};let c=!1;r.fail=function(t,n){let l=e.getInternalMethods().getLoggerInstance();if(i.length)for(let e=i.length-1;e>=0;--e){let a=i[e];if(fn(a)){if(n)throw n;if(t)throw Error(t)}else a(t,n,r)}else{if(e.getExitProcess()&&dn(!0),!c){c=!0,s&&(e.showHelp(`error`),l.error()),(t||n)&&l.error(t||n);let r=a||o;r&&((t||n)&&l.error(``),l.error(r))}if(n||=new P(t),e.getExitProcess())return e.exit(1);if(e.getInternalMethods().hasParseCallback())return e.exit(1,n);throw n}};let l=[],u=!1;r.usage=(e,t)=>e===null?(u=!0,l=[],r):(u=!1,l.push([e,t||``]),r),r.getUsage=()=>l,r.getUsageDisabled=()=>u,r.getPositionalGroupName=()=>n(`Positionals:`);let d=[];r.example=(e,t)=>{d.push([e,t||``])};let f=[];r.command=function(e,t,n,r,i=!1){n&&(f=f.map(e=>(e[2]=!1,e))),f.push([e,t||``,n,r,i])},r.getCommands=()=>f;let p={};r.describe=function(e,t){Array.isArray(e)?e.forEach(e=>{r.describe(e,t)}):typeof e==`object`?Object.keys(e).forEach(t=>{r.describe(t,e[t])}):p[e]=t},r.getDescriptions=()=>p;let m=[];r.epilog=e=>{m.push(e)};let h=!1,g;r.wrap=e=>{h=!0,g=e},r.getWrap=()=>t.getEnv(`YARGS_DISABLE_WRAP`)?null:(h||=(g=x(),!0),g);let _=`__yargsString__:`;r.deferY18nLookup=e=>_+e,r.help=function(){if(b)return b;y();let i=e.customScriptName?e.$0:t.path.basename(e.$0),a=e.getDemandedOptions(),o=e.getDemandedCommands(),s=e.getDeprecatedOptions(),c=e.getGroups(),h=e.getOptions(),g=[];g=g.concat(Object.keys(p)),g=g.concat(Object.keys(a)),g=g.concat(Object.keys(o)),g=g.concat(Object.keys(h.default)),g=g.filter(te),g=Object.keys(g.reduce((e,t)=>(t!==`_`&&(e[t]=!0),e),{}));let x=r.getWrap(),S=t.cliui({width:x,wrap:!!x});if(!u){if(l.length)l.forEach(e=>{S.div({text:`${e[0].replace(/\$0/g,i)}`}),e[1]&&S.div({text:`${e[1]}`,padding:[1,0,0,0]})}),S.div();else if(f.length){let e=null;e=o._?`${i} <${n(`command`)}>\n`:`${i} [${n(`command`)}]\n`,S.div(`${e}`)}}if(f.length>1||f.length===1&&!f[0][2]){S.div(n(`Commands:`));let t=e.getInternalMethods().getContext(),r=t.commands.length?`${t.commands.join(` `)} `:``;e.getInternalMethods().getParserConfiguration()[`sort-commands`]===!0&&(f=f.sort((e,t)=>e[0].localeCompare(t[0])));let a=i?`${i} `:``;f.forEach(e=>{let t=`${a}${r}${e[0].replace(/^\$0 ?/,``)}`;S.span({text:t,padding:[0,2,0,2],width:v(f,x,`${i}${r}`)+4},{text:e[1]});let o=[];e[2]&&o.push(`[${n(`default`)}]`),e[3]&&e[3].length&&o.push(`[${n(`aliases:`)} ${e[3].join(`, `)}]`),e[4]&&(typeof e[4]==`string`?o.push(`[${n(`deprecated: %s`,e[4])}]`):o.push(`[${n(`deprecated`)}]`)),o.length?S.div({text:o.join(` `),padding:[0,0,0,2],align:`right`}):S.div()}),S.div()}let C=(Object.keys(h.alias)||[]).concat(Object.keys(e.parsed.newAliases)||[]);g=g.filter(t=>!e.parsed.newAliases[t]&&C.every(e=>(h.alias[e]||[]).indexOf(t)===-1));let re=n(`Options:`);c[re]||(c[re]=[]),ee(g,h.alias,c,re);let w=e=>/^--/.test(_n(e)),ie=Object.keys(c).filter(e=>c[e].length>0).map(e=>({groupName:e,normalizedKeys:c[e].filter(te).map(e=>{if(C.includes(e))return e;for(let t=0,n;(n=C[t])!==void 0;t++)if((h.alias[n]||[]).includes(e))return n;return e})})).filter(({normalizedKeys:e})=>e.length>0).map(({groupName:e,normalizedKeys:t})=>({groupName:e,normalizedKeys:t,switches:t.reduce((t,n)=>(t[n]=[n].concat(h.alias[n]||[]).map(t=>e===r.getPositionalGroupName()?t:(/^[0-9]$/.test(t)?h.boolean.includes(n)?`-`:`--`:t.length>1?`--`:`-`)+t).sort((e,t)=>w(e)===w(t)?0:w(e)?1:-1).join(`, `),t),{})}));if(ie.filter(({groupName:e})=>e!==r.getPositionalGroupName()).some(({normalizedKeys:e,switches:t})=>!e.every(e=>w(t[e])))&&ie.filter(({groupName:e})=>e!==r.getPositionalGroupName()).forEach(({normalizedKeys:e,switches:t})=>{e.forEach(e=>{w(t[e])&&(t[e]=hn(t[e],4))})}),ie.forEach(({groupName:t,normalizedKeys:i,switches:o})=>{S.div(t),i.forEach(t=>{let i=o[t],c=p[t]||``,l=null;c.includes(_)&&(c=n(c.substring(16))),h.boolean.includes(t)&&(l=`[${n(`boolean`)}]`),h.count.includes(t)&&(l=`[${n(`count`)}]`),h.string.includes(t)&&(l=`[${n(`string`)}]`),h.normalize.includes(t)&&(l=`[${n(`string`)}]`),h.array.includes(t)&&(l=`[${n(`array`)}]`),h.number.includes(t)&&(l=`[${n(`number`)}]`);let u=[t in s?(e=>typeof e==`string`?`[${n(`deprecated: %s`,e)}]`:`[${n(`deprecated`)}]`)(s[t]):null,l,t in a?`[${n(`required`)}]`:null,h.choices&&h.choices[t]?`[${n(`choices:`)} ${r.stringifiedValues(h.choices[t])}]`:null,ne(h.default[t],h.defaultDescription[t])].filter(Boolean).join(` `);S.span({text:_n(i),padding:[0,2,0,2+gn(i)],width:v(o,x)+4},c);let d=e.getInternalMethods().getUsageConfiguration()[`hide-types`]===!0;u&&!d?S.div({text:u,padding:[0,0,0,2],align:`right`}):S.div()}),S.div()}),d.length&&(S.div(n(`Examples:`)),d.forEach(e=>{e[0]=e[0].replace(/\$0/g,i)}),d.forEach(e=>{e[1]===``?S.div({text:e[0],padding:[0,2,0,2]}):S.div({text:e[0],padding:[0,2,0,2],width:v(d,x)+4},{text:e[1]})}),S.div()),m.length>0){let e=m.map(e=>e.replace(/\$0/g,i)).join(`
|
|
46
|
+
`);S.div(`${e}\n`)}return S.toString().replace(/\s*$/,``)};function v(e,n,r){let i=0;return Array.isArray(e)||(e=Object.values(e).map(e=>[e])),e.forEach(e=>{i=Math.max(t.stringWidth(r?`${r} ${_n(e[0])}`:_n(e[0]))+gn(e[0]),i)}),n&&(i=Math.min(i,parseInt((n*.5).toString(),10))),i}function y(){let t=e.getDemandedOptions(),n=e.getOptions();(Object.keys(n.alias)||[]).forEach(i=>{n.alias[i].forEach(a=>{p[a]&&r.describe(i,p[a]),a in t&&e.demandOption(i,t[a]),n.boolean.includes(a)&&e.boolean(i),n.count.includes(a)&&e.count(i),n.string.includes(a)&&e.string(i),n.normalize.includes(a)&&e.normalize(i),n.array.includes(a)&&e.array(i),n.number.includes(a)&&e.number(i)})})}let b;r.cacheHelpMessage=function(){b=this.help()},r.clearCachedHelpMessage=function(){b=void 0},r.hasCachedHelpMessage=function(){return!!b};function ee(e,t,n,r){let i=[],a=null;return Object.keys(n).forEach(e=>{i=i.concat(n[e])}),e.forEach(e=>{a=[e].concat(t[e]),a.some(e=>i.indexOf(e)!==-1)||n[r].push(e)}),i}function te(t){return e.getOptions().hiddenOptions.indexOf(t)<0||e.parsed.argv[e.getOptions().showHiddenOpt]}r.showHelp=t=>{let n=e.getInternalMethods().getLoggerInstance();t||=`error`,(typeof t==`function`?t:n[t])(r.help())},r.functionDescription=e=>[`(`,e.name?t.Parser.decamelize(e.name,`-`):n(`generated-value`),`)`].join(``),r.stringifiedValues=function(e,t){let n=``,r=t||`, `,i=[].concat(e);return!e||!i.length||i.forEach(e=>{n.length&&(n+=r),n+=JSON.stringify(e)}),n};function ne(e,t){let r=`[${n(`default:`)} `;if(e===void 0&&!t)return null;if(t)r+=t;else switch(typeof e){case`string`:r+=`"${e}"`;break;case`object`:r+=JSON.stringify(e);break;default:r+=e}return`${r}]`}function x(){return t.process.stdColumns?Math.min(80,t.process.stdColumns):80}let S=null;r.version=e=>{S=e},r.showVersion=t=>{let n=e.getInternalMethods().getLoggerInstance();t||=`error`,(typeof t==`function`?t:n[t])(S)},r.reset=function(e){return a=null,c=!1,l=[],u=!1,m=[],d=[],f=[],p=un(p,t=>!e[t]),r};let C=[];return r.freeze=function(){C.push({failMessage:a,failureOutput:c,usages:l,usageDisabled:u,epilogs:m,examples:d,commands:f,descriptions:p})},r.unfreeze=function(e=!1){let t=C.pop();t&&(e?(p={...t.descriptions,...p},f=[...t.commands,...f],l=[...t.usages,...l],d=[...t.examples,...d],m=[...t.epilogs,...m]):{failMessage:a,failureOutput:c,usages:l,usageDisabled:u,epilogs:m,examples:d,commands:f,descriptions:p}=t)},r}function mn(e){return typeof e==`object`}function hn(e,t){return mn(e)?{text:e.text,indentation:e.indentation+t}:{text:e,indentation:t}}function gn(e){return mn(e)?e.indentation:0}function _n(e){return mn(e)?e.text:e}var vn=class{constructor(e,t,n,r){this.yargs=e,this.usage=t,this.command=n,this.shim=r,this.completionKey=`get-yargs-completions`,this.aliases=null,this.customCompletionFunction=null,this.indexAfterLastReset=0,this.zshShell=(this.shim.getEnv(`SHELL`)?.includes(`zsh`)||this.shim.getEnv(`ZSH_NAME`)?.includes(`zsh`))??!1,this.fishShell=this.shim.getEnv(`SHELL`)?.includes(`fish`)??!1}defaultCompletion(e,t,n,r){let i=this.command.getCommandHandlers();for(let t=0,n=e.length;t<n;++t)if(i[e[t]]&&i[e[t]].builder){let n=i[e[t]].builder;if(sn(n)){this.indexAfterLastReset=t+1;let e=this.yargs.getInternalMethods().reset();return n(e,!0),e.argv}}let a=[];this.commandCompletions(a,e,n),this.optionCompletions(a,e,t,n),this.choicesFromOptionsCompletions(a,e,t,n),this.choicesFromPositionalsCompletions(a,e,t,n),r(null,a)}commandCompletions(e,t,n){let r=this.yargs.getInternalMethods().getContext().commands;!n.match(/^-/)&&r[r.length-1]!==n&&!this.previousArgHasChoices(t)&&this.usage.getCommands().forEach(n=>{let r=Kt(n[0]).cmd;if(t.indexOf(r)===-1){let t=n[1]||``;this.fishShell?e.push(r+` `+t):this.zshShell?e.push(r.replace(/:/g,`\\:`)+`:`+t):e.push(r)}})}optionCompletions(e,t,n,r){if((r.match(/^-/)||r===``&&e.length===0)&&!this.previousArgHasChoices(t)){let n=this.yargs.getOptions(),i=this.yargs.getGroups()[this.usage.getPositionalGroupName()]||[];Object.keys(n.key).forEach(a=>{let o=!!n.configuration[`boolean-negation`]&&n.boolean.includes(a);i.includes(a)||n.hiddenOptions.includes(a)||this.argsContainKey(t,a,o)||this.completeOptionKey(a,e,r,o&&!!n.default[a])})}}choicesFromOptionsCompletions(e,t,n,r){if(this.previousArgHasChoices(t)){let n=this.getPreviousArgChoices(t);n&&n.length>0&&(this.fishShell?e.push(...n):e.push(...n.map(e=>e.replace(/:/g,`\\:`))))}}choicesFromPositionalsCompletions(e,t,n,r){if(r===``&&e.length>0&&this.previousArgHasChoices(t))return;let i=this.yargs.getGroups()[this.usage.getPositionalGroupName()]||[],a=Math.max(this.indexAfterLastReset,this.yargs.getInternalMethods().getContext().commands.length+1),o=i[n._.length-a-1];if(!o)return;let s=this.yargs.getOptions().choices[o]||[];for(let t of s)t.startsWith(r)&&(this.fishShell?e.push(t):e.push(t.replace(/:/g,`\\:`)))}getPreviousArgChoices(e){if(e.length<1)return;let t=e[e.length-1],n=``;if(!t.startsWith(`-`)&&e.length>1&&(n=t,t=e[e.length-2]),!t.startsWith(`-`))return;let r=t.replace(/^-+/,``),i=this.yargs.getOptions(),a=[r,...this.yargs.getAliases()[r]||[]],o;for(let e of a)if(Object.prototype.hasOwnProperty.call(i.key,e)&&Array.isArray(i.choices[e])){o=i.choices[e];break}if(o)return o.filter(e=>!n||e.startsWith(n))}previousArgHasChoices(e){let t=this.getPreviousArgChoices(e);return t!==void 0&&t.length>0}argsContainKey(e,t,n){let r=t=>e.indexOf((/^[^0-9]$/.test(t)?`-`:`--`)+t)!==-1;if(r(t)||n&&r(`no-${t}`))return!0;if(this.aliases){for(let e of this.aliases[t])if(r(e))return!0}return!1}completeOptionKey(e,t,n,r){let i=e;if(this.zshShell||this.fishShell){let t=this.usage.getDescriptions(),n=((this===null||this===void 0?void 0:this.aliases)?.[e])?.find(e=>{let n=t[e];return typeof n==`string`&&n.length>0}),r=n?t[n]:void 0,a=(t[e]??r??``).replace(`__yargsString__:`,``).replace(/(\r\n|\n|\r)/gm,` `);i=this.fishShell?`${e}\t${a}`:`${e.replace(/:/g,`\\:`)}:${a}`}let a=!(e=>/^--/.test(e))(n)&&(e=>/^[^0-9]$/.test(e))(e)?`-`:`--`;t.push(a+i),r&&t.push(a+`no-`+i)}customCompletion(e,t,n,r){if(M(this.customCompletionFunction,null,this.shim),bn(this.customCompletionFunction)){let e=this.customCompletionFunction(n,t);return N(e)?e.then(e=>{this.shim.process.nextTick(()=>{r(null,e)})}).catch(e=>{this.shim.process.nextTick(()=>{r(e,void 0)})}):r(null,e)}return xn(this.customCompletionFunction)?this.customCompletionFunction(n,t,(i=r)=>this.defaultCompletion(e,t,n,i),e=>{r(null,e)}):this.customCompletionFunction(n,t,e=>{r(null,e)})}getCompletion(e,t){let n=e.length?e[e.length-1]:``,r=this.yargs.parse(e,!0),i=this.customCompletionFunction?r=>this.customCompletion(e,r,n,t):r=>this.defaultCompletion(e,r,n,t);return N(r)?r.then(i):i(r)}generateCompletionScript(e,t){let n;n=this.zshShell?`#compdef {{app_name}}
|
|
47
|
+
###-begin-{{app_name}}-completions-###
|
|
48
|
+
#
|
|
49
|
+
# yargs command completion script
|
|
50
|
+
#
|
|
51
|
+
# Installation: {{app_path}} {{completion_command}} >> ~/.zshrc
|
|
52
|
+
# or {{app_path}} {{completion_command}} >> ~/.zprofile on OSX.
|
|
53
|
+
#
|
|
54
|
+
_{{app_name}}_yargs_completions()
|
|
55
|
+
{
|
|
56
|
+
local reply
|
|
57
|
+
local si=$IFS
|
|
58
|
+
IFS=$'
|
|
59
|
+
' reply=($(COMP_CWORD="$((CURRENT-1))" COMP_LINE="$BUFFER" COMP_POINT="$CURSOR" {{app_path}} --get-yargs-completions "\${words[@]}"))
|
|
60
|
+
IFS=$si
|
|
61
|
+
if [[ \${#reply} -gt 0 ]]; then
|
|
62
|
+
_describe 'values' reply
|
|
63
|
+
else
|
|
64
|
+
_default
|
|
65
|
+
fi
|
|
66
|
+
}
|
|
67
|
+
if [[ "\${zsh_eval_context[-1]}" == "loadautofunc" ]]; then
|
|
68
|
+
_{{app_name}}_yargs_completions "$@"
|
|
69
|
+
else
|
|
70
|
+
compdef _{{app_name}}_yargs_completions {{app_name}}
|
|
71
|
+
fi
|
|
72
|
+
###-end-{{app_name}}-completions-###
|
|
73
|
+
`:this.fishShell?`###-begin-{{app_name}}-completions-###
|
|
74
|
+
#
|
|
75
|
+
# yargs command completion script
|
|
76
|
+
#
|
|
77
|
+
# Installation: {{app_path}} {{completion_command}} > ~/.config/fish/completions/{{app_name}}.fish
|
|
78
|
+
#
|
|
79
|
+
complete -f -c {{app_name}} -a '({{app_path}} --get-yargs-completions (commandline -o)[2..-1])'
|
|
80
|
+
###-end-{{app_name}}-completions-###
|
|
81
|
+
`:`###-begin-{{app_name}}-completions-###
|
|
82
|
+
#
|
|
83
|
+
# yargs command completion script
|
|
84
|
+
#
|
|
85
|
+
# Installation: {{app_path}} {{completion_command}} >> ~/.bashrc
|
|
86
|
+
# or {{app_path}} {{completion_command}} >> ~/.bash_profile on OSX.
|
|
87
|
+
#
|
|
88
|
+
_{{app_name}}_yargs_completions()
|
|
89
|
+
{
|
|
90
|
+
local cur_word args type_list
|
|
91
|
+
|
|
92
|
+
cur_word="\${COMP_WORDS[COMP_CWORD]}"
|
|
93
|
+
args=("\${COMP_WORDS[@]}")
|
|
94
|
+
|
|
95
|
+
# ask yargs to generate completions.
|
|
96
|
+
# see https://stackoverflow.com/a/40944195/7080036 for the spaces-handling awk
|
|
97
|
+
mapfile -t type_list < <({{app_path}} --get-yargs-completions "\${args[@]}")
|
|
98
|
+
mapfile -t COMPREPLY < <(compgen -W "$( printf '%q ' "\${type_list[@]}" )" -- "\${cur_word}" |
|
|
99
|
+
awk '/ / { print "\\""$0"\\"" } /^[^ ]+$/ { print $0 }')
|
|
100
|
+
|
|
101
|
+
# if no match was found, fall back to filename completion
|
|
102
|
+
if [ \${#COMPREPLY[@]} -eq 0 ]; then
|
|
103
|
+
COMPREPLY=()
|
|
104
|
+
fi
|
|
105
|
+
|
|
106
|
+
return 0
|
|
107
|
+
}
|
|
108
|
+
complete -o bashdefault -o default -F _{{app_name}}_yargs_completions {{app_name}}
|
|
109
|
+
###-end-{{app_name}}-completions-###
|
|
110
|
+
`;let r=this.shim.path.basename(e);return e.match(/\.js$/)&&(e=`./${e}`),n=n.replace(/{{app_name}}/g,r),n=n.replace(/{{completion_command}}/g,t),n.replace(/{{app_path}}/g,e)}registerFunction(e){this.customCompletionFunction=e}setParsed(e){this.aliases=e.aliases}};function yn(e,t,n,r){return new vn(e,t,n,r)}function bn(e){return e.length<3}function xn(e){return e.length>3}function Sn(e,t){if(e.length===0)return t.length;if(t.length===0)return e.length;let n=[],r=0;for(;r<=t.length;r++)n[r]=[r];let i=0;for(;i<=e.length;i++)n[0][i]=i;for(r=1;r<=t.length;r++)for(i=1;i<=e.length;i++)t.charAt(r-1)===e.charAt(i-1)?n[r][i]=n[r-1][i-1]:r>1&&i>1&&t.charAt(r-2)===e.charAt(i-1)&&t.charAt(r-1)===e.charAt(i-2)?n[r][i]=n[r-2][i-2]+1:n[r][i]=Math.min(n[r-1][i-1]+1,Math.min(n[r][i-1]+1,n[r-1][i]+1));return n[t.length][e.length]}const Cn=[`$0`,`--`,`_`];function wn(e,t,n){let r=n.y18n.__,i=n.y18n.__n,a={};a.nonOptionCount=function(n){let r=e.getDemandedCommands(),a=n._.length+(n[`--`]?n[`--`].length:0)-e.getInternalMethods().getContext().commands.length;r._&&(a<r._.min||a>r._.max)&&(a<r._.min?r._.minMsg===void 0?t.fail(i(`Not enough non-option arguments: got %s, need at least %s`,`Not enough non-option arguments: got %s, need at least %s`,a,a.toString(),r._.min.toString())):t.fail(r._.minMsg?r._.minMsg.replace(/\$0/g,a.toString()).replace(/\$1/,r._.min.toString()):null):a>r._.max&&(r._.maxMsg===void 0?t.fail(i(`Too many non-option arguments: got %s, maximum of %s`,`Too many non-option arguments: got %s, maximum of %s`,a,a.toString(),r._.max.toString())):t.fail(r._.maxMsg?r._.maxMsg.replace(/\$0/g,a.toString()).replace(/\$1/,r._.max.toString()):null)))},a.positionalCount=function(e,n){n<e&&t.fail(i(`Not enough non-option arguments: got %s, need at least %s`,`Not enough non-option arguments: got %s, need at least %s`,n,n+``,e+``))},a.requiredArguments=function(e,n){let r=null;for(let t of Object.keys(n))Object.prototype.hasOwnProperty.call(e,t)&&e[t]!==void 0||(r||={},r[t]=n[t]);if(r){let e=[];for(let t of Object.keys(r)){let n=r[t];n&&e.indexOf(n)<0&&e.push(n)}let n=e.length?`\n${e.join(`
|
|
111
|
+
`)}`:``;t.fail(i(`Missing required argument: %s`,`Missing required arguments: %s`,Object.keys(r).length,Object.keys(r).join(`, `)+n))}},a.unknownArguments=function(n,r,o,s,c=!0){let l=e.getInternalMethods().getCommandInstance().getCommands(),u=[],d=e.getInternalMethods().getContext();if(Object.keys(n).forEach(t=>{Cn.includes(t)||Object.prototype.hasOwnProperty.call(o,t)||Object.prototype.hasOwnProperty.call(e.getInternalMethods().getParseContext(),t)||a.isValidAndSomeAliasIsNotNew(t,r)||u.push(t)}),c&&(d.commands.length>0||l.length>0||s)&&n._.slice(d.commands.length).forEach(e=>{l.includes(``+e)||u.push(``+e)}),c){let t=e.getDemandedCommands()._?.max||0,r=d.commands.length+t;r<n._.length&&n._.slice(r).forEach(e=>{e=String(e),!d.commands.includes(e)&&!u.includes(e)&&u.push(e)})}u.length&&t.fail(i(`Unknown argument: %s`,`Unknown arguments: %s`,u.length,u.map(e=>e.trim()?e:`"${e}"`).join(`, `)))},a.unknownCommands=function(n){let r=e.getInternalMethods().getCommandInstance().getCommands(),a=[],o=e.getInternalMethods().getContext();return(o.commands.length>0||r.length>0)&&n._.slice(o.commands.length).forEach(e=>{r.includes(``+e)||a.push(``+e)}),a.length>0&&(t.fail(i(`Unknown command: %s`,`Unknown commands: %s`,a.length,a.join(`, `))),!0)},a.isValidAndSomeAliasIsNotNew=function(t,n){if(!Object.prototype.hasOwnProperty.call(n,t))return!1;let r=e.parsed.newAliases;return[t,...n[t]].some(e=>!Object.prototype.hasOwnProperty.call(r,e)||!r[t])},a.limitedChoices=function(n){let i=e.getOptions(),a={};if(!Object.keys(i.choices).length)return;Object.keys(n).forEach(e=>{Cn.indexOf(e)===-1&&Object.prototype.hasOwnProperty.call(i.choices,e)&&[].concat(n[e]).forEach(t=>{i.choices[e].indexOf(t)===-1&&t!==void 0&&(a[e]=(a[e]||[]).concat(t))})});let o=Object.keys(a);if(!o.length)return;let s=r(`Invalid values:`);o.forEach(e=>{s+=`\n ${r(`Argument: %s, Given: %s, Choices: %s`,e,t.stringifiedValues(a[e]),t.stringifiedValues(i.choices[e]))}`}),t.fail(s)};let o={};a.implies=function(t,r){F(`<string|object> [array|number|string]`,[t,r],arguments.length),typeof t==`object`?Object.keys(t).forEach(e=>{a.implies(e,t[e])}):(e.global(t),o[t]||(o[t]=[]),Array.isArray(r)?r.forEach(e=>a.implies(t,e)):(M(r,void 0,n),o[t].push(r)))},a.getImplied=function(){return o};function s(e,t){let n=Number(t);return t=isNaN(n)?t:n,typeof t==`number`?t=e._.length>=t:t.match(/^--no-.+/)?(t=t.match(/^--no-(.+)/)[1],t=!Object.prototype.hasOwnProperty.call(e,t)):t=Object.prototype.hasOwnProperty.call(e,t),t}a.implications=function(e){let n=[];if(Object.keys(o).forEach(t=>{let r=t;(o[t]||[]).forEach(t=>{let i=r,a=t;i=s(e,i),t=s(e,t),i&&!t&&n.push(` ${r} -> ${a}`)})}),n.length){let e=`${r(`Implications failed:`)}\n`;n.forEach(t=>{e+=t}),t.fail(e)}};let c={};a.conflicts=function(t,n){F(`<string|object> [array|string]`,[t,n],arguments.length),typeof t==`object`?Object.keys(t).forEach(e=>{a.conflicts(e,t[e])}):(e.global(t),c[t]||(c[t]=[]),Array.isArray(n)?n.forEach(e=>a.conflicts(t,e)):c[t].push(n))},a.getConflicting=()=>c,a.conflicting=function(i){Object.keys(i).forEach(e=>{c[e]&&c[e].forEach(n=>{n&&i[e]!==void 0&&i[n]!==void 0&&t.fail(r(`Arguments %s and %s are mutually exclusive`,e,n))})}),e.getInternalMethods().getParserConfiguration()[`strip-dashed`]&&Object.keys(c).forEach(e=>{c[e].forEach(a=>{a&&i[n.Parser.camelCase(e)]!==void 0&&i[n.Parser.camelCase(a)]!==void 0&&t.fail(r(`Arguments %s and %s are mutually exclusive`,e,a))})})},a.recommendCommands=function(e,n){n=n.sort((e,t)=>t.length-e.length);let i=null,a=1/0;for(let t=0,r;(r=n[t])!==void 0;t++){let t=Sn(e,r);t<=3&&t<a&&(a=t,i=r)}i&&t.fail(r(`Did you mean %s?`,i))},a.reset=function(e){return o=un(o,t=>!e[t]),c=un(c,t=>!e[t]),a};let l=[];return a.freeze=function(){l.push({implied:o,conflicting:c})},a.unfreeze=function(){let e=l.pop();M(e,void 0,n),{implied:o,conflicting:c}=e},a}let Tn=[],En;function Dn(e,t,n,r){En=r;let i={};if(Object.prototype.hasOwnProperty.call(e,`extends`)){if(typeof e.extends!=`string`)return i;let a=/\.json|\..*rc$/.test(e.extends),o=null;if(a)o=kn(t,e.extends);else try{o=import.meta.resolve(e.extends)}catch{return e}On(o),Tn.push(o),i=a?JSON.parse(En.readFileSync(o,`utf8`)):r.require(e.extends),delete e.extends,i=Dn(i,En.path.dirname(o),n,En)}return Tn=[],n?An(i,e):Object.assign({},i,e)}function On(e){if(Tn.indexOf(e)>-1)throw new P(`Circular extended configurations: '${e}'.`)}function kn(e,t){return En.path.resolve(e,t)}function An(e,t){let n={};function r(e){return e&&typeof e==`object`&&!Array.isArray(e)}Object.assign(n,e);for(let i of Object.keys(t))i!==`__proto__`&&(n[i]=r(t[i])&&r(n[i])?An(e[i],t[i]):t[i]);return n}var I=function(e,t,n,r,i){if(r===`m`)throw TypeError(`Private method is not writable`);if(r===`a`&&!i)throw TypeError(`Private accessor was defined without a setter`);if(typeof t==`function`?e!==t||!i:!t.has(e))throw TypeError(`Cannot write private member to an object whose class did not declare it`);return r===`a`?i.call(e,n):i?i.value=n:t.set(e,n),n},L=function(e,t,n,r){if(n===`a`&&!r)throw TypeError(`Private accessor was defined without a getter`);if(typeof t==`function`?e!==t||!r:!t.has(e))throw TypeError(`Cannot read private member from an object whose class did not declare it`);return n===`m`?r:n===`a`?r.call(e):r?r.value:t.get(e)},R,jn,Mn,z,B,Nn,V,Pn,Fn,H,In,U,W,G,K,Ln,Rn,q,J,zn,Bn,Y,Vn,Hn,Un,Wn,Gn,X,Kn,qn,Jn,Z,Yn,Q,$;function Xn(e){return(t=[],n=e.process.cwd(),r)=>{let i=new Nr(t,n,r,e);return Object.defineProperty(i,"argv",{get:()=>i.parse(),enumerable:!0}),i.help(),i.version(),i}}const Zn=Symbol(`copyDoubleDash`),Qn=Symbol(`copyDoubleDash`),$n=Symbol(`deleteFromParserHintObject`),er=Symbol(`emitWarning`),tr=Symbol(`freeze`),nr=Symbol(`getDollarZero`),rr=Symbol(`getParserConfiguration`),ir=Symbol(`getUsageConfiguration`),ar=Symbol(`guessLocale`),or=Symbol(`guessVersion`),sr=Symbol(`parsePositionalNumbers`),cr=Symbol(`pkgUp`),lr=Symbol(`populateParserHintArray`),ur=Symbol(`populateParserHintSingleValueDictionary`),dr=Symbol(`populateParserHintArrayDictionary`),fr=Symbol(`populateParserHintDictionary`),pr=Symbol(`sanitizeKey`),mr=Symbol(`setKey`),hr=Symbol(`unfreeze`),gr=Symbol(`validateAsync`),_r=Symbol(`getCommandInstance`),vr=Symbol(`getContext`),yr=Symbol(`getHasOutput`),br=Symbol(`getLoggerInstance`),xr=Symbol(`getParseContext`),Sr=Symbol(`getUsageInstance`),Cr=Symbol(`getValidationInstance`),wr=Symbol(`hasParseCallback`),Tr=Symbol(`isGlobalContext`),Er=Symbol(`postProcess`),Dr=Symbol(`rebase`),Or=Symbol(`reset`),kr=Symbol(`runYargsParserAndExecuteCommands`),Ar=Symbol(`runValidation`),jr=Symbol(`setHasOutput`),Mr=Symbol(`kTrackManuallySetKeys`);var Nr=class{constructor(e=[],t,n,r){this.customScriptName=!1,this.parsed=!1,R.set(this,void 0),jn.set(this,void 0),Mn.set(this,{commands:[],fullCommands:[]}),z.set(this,null),B.set(this,null),Nn.set(this,`show-hidden`),V.set(this,null),Pn.set(this,!0),Fn.set(this,{}),H.set(this,!0),In.set(this,[]),U.set(this,void 0),W.set(this,{}),G.set(this,!1),K.set(this,null),Ln.set(this,!0),Rn.set(this,void 0),q.set(this,``),J.set(this,void 0),zn.set(this,void 0),Bn.set(this,{}),Y.set(this,null),Vn.set(this,null),Hn.set(this,{}),Un.set(this,{}),Wn.set(this,void 0),Gn.set(this,!1),X.set(this,void 0),Kn.set(this,!1),qn.set(this,!1),Jn.set(this,!1),Z.set(this,void 0),Yn.set(this,{}),Q.set(this,null),$.set(this,void 0),I(this,X,r,`f`),I(this,Wn,e,`f`),I(this,jn,t,`f`),I(this,zn,n,`f`),I(this,U,new Xt(this),`f`),this.$0=this[nr](),this[Or](),I(this,R,L(this,R,`f`),`f`),I(this,Z,L(this,Z,`f`),`f`),I(this,$,L(this,$,`f`),`f`),I(this,J,L(this,J,`f`),`f`),L(this,J,`f`).showHiddenOpt=L(this,Nn,`f`),I(this,Rn,this[Qn](),`f`),L(this,X,`f`).y18n.setLocale(`en_US`)}addHelpOpt(e,t){return F(`[string|boolean] [string]`,[e,t],arguments.length),L(this,K,`f`)&&(this[$n](L(this,K,`f`)),I(this,K,null,`f`)),e===!1&&t===void 0||(I(this,K,typeof e==`string`?e:`help`,`f`),this.boolean(L(this,K,`f`)),this.describe(L(this,K,`f`),t||L(this,Z,`f`).deferY18nLookup(`Show help`))),this}help(e,t){return this.addHelpOpt(e,t)}addShowHiddenOpt(e,t){if(F(`[string|boolean] [string]`,[e,t],arguments.length),e===!1&&t===void 0)return this;let n=typeof e==`string`?e:L(this,Nn,`f`);return this.boolean(n),this.describe(n,t||L(this,Z,`f`).deferY18nLookup(`Show hidden options`)),L(this,J,`f`).showHiddenOpt=n,this}showHidden(e,t){return this.addShowHiddenOpt(e,t)}alias(e,t){return F(`<object|string|array> [string|array]`,[e,t],arguments.length),this[dr](this.alias.bind(this),`alias`,e,t),this}array(e){return F(`<array|string>`,[e],arguments.length),this[lr](`array`,e),this[Mr](e),this}boolean(e){return F(`<array|string>`,[e],arguments.length),this[lr](`boolean`,e),this[Mr](e),this}check(e,t){return F(`<function> [boolean]`,[e,t],arguments.length),this.middleware((t,n)=>$t(()=>e(t,n.getOptions()),n=>(n?(typeof n==`string`||n instanceof Error)&&L(this,Z,`f`).fail(n.toString(),n):L(this,Z,`f`).fail(L(this,X,`f`).y18n.__(`Argument check failed: %s`,e.toString())),t),e=>(L(this,Z,`f`).fail(e.message?e.message:e.toString(),e),t)),!1,t),this}choices(e,t){return F(`<object|string|array> [string|array]`,[e,t],arguments.length),this[dr](this.choices.bind(this),`choices`,e,t),this}coerce(e,t){if(F(`<object|string|array> [function]`,[e,t],arguments.length),Array.isArray(e)){if(!t)throw new P(`coerce callback must be provided`);for(let n of e)this.coerce(n,t);return this}if(typeof e==`object`){for(let t of Object.keys(e))this.coerce(t,e[t]);return this}if(!t)throw new P(`coerce callback must be provided`);let n=e;return L(this,J,`f`).key[n]=!0,L(this,U,`f`).addCoerceMiddleware((e,r)=>{let i=r.getAliases()[n]??[],a=[n,...i].filter(t=>Object.prototype.hasOwnProperty.call(e,t));return a.length===0?e:$t(()=>t(e[a[0]]),t=>(a.forEach(n=>{e[n]=t}),e),e=>{throw new P(e.message)})},n),this}conflicts(e,t){return F(`<string|object> [string|array]`,[e,t],arguments.length),L(this,$,`f`).conflicts(e,t),this}config(e=`config`,t,n){return F(`[object|string] [string|function] [function]`,[e,t,n],arguments.length),typeof e==`object`&&!Array.isArray(e)?(e=Dn(e,L(this,jn,`f`),this[rr]()[`deep-merge-config`]||!1,L(this,X,`f`)),L(this,J,`f`).configObjects=(L(this,J,`f`).configObjects||[]).concat(e),this):(typeof t==`function`&&(n=t,t=void 0),this.describe(e,t||L(this,Z,`f`).deferY18nLookup(`Path to JSON config file`)),(Array.isArray(e)?e:[e]).forEach(e=>{L(this,J,`f`).config[e]=n||!0}),this)}completion(e,t,n){return F(`[string] [string|boolean|function] [function]`,[e,t,n],arguments.length),typeof t==`function`&&(n=t,t=void 0),I(this,B,e||L(this,B,`f`)||`completion`,`f`),!t&&t!==!1&&(t=`generate completion script`),this.command(L(this,B,`f`),t),n&&L(this,z,`f`).registerFunction(n),this}command(e,t,n,r,i,a){return F(`<string|array|object> [string|boolean] [function|object] [function] [array] [boolean|string]`,[e,t,n,r,i,a],arguments.length),L(this,R,`f`).addHandler(e,t,n,r,i,a),this}commands(e,t,n,r,i,a){return this.command(e,t,n,r,i,a)}commandDir(e,t){F(`<string> [object]`,[e,t],arguments.length);let n=L(this,zn,`f`)||L(this,X,`f`).require;return L(this,R,`f`).addDirectory(e,n,L(this,X,`f`).getCallerFile(),t),this}count(e){return F(`<array|string>`,[e],arguments.length),this[lr](`count`,e),this[Mr](e),this}default(e,t,n){return F(`<object|string|array> [*] [string]`,[e,t,n],arguments.length),n&&(Wt(e,L(this,X,`f`)),L(this,J,`f`).defaultDescription[e]=n),typeof t==`function`&&(Wt(e,L(this,X,`f`)),L(this,J,`f`).defaultDescription[e]||(L(this,J,`f`).defaultDescription[e]=L(this,Z,`f`).functionDescription(t)),t=t.call()),this[ur](this.default.bind(this),`default`,e,t),this}defaults(e,t,n){return this.default(e,t,n)}demandCommand(e=1,t,n,r){return F(`[number] [number|string] [string|null|undefined] [string|null|undefined]`,[e,t,n,r],arguments.length),typeof t!=`number`&&(n=t,t=1/0),this.global(`_`,!1),L(this,J,`f`).demandedCommands._={min:e,max:t,minMsg:n,maxMsg:r},this}demand(e,t,n){return Array.isArray(t)?(t.forEach(e=>{M(n,!0,L(this,X,`f`)),this.demandOption(e,n)}),t=1/0):typeof t!=`number`&&(n=t,t=1/0),typeof e==`number`?(M(n,!0,L(this,X,`f`)),this.demandCommand(e,t,n,n)):Array.isArray(e)?e.forEach(e=>{M(n,!0,L(this,X,`f`)),this.demandOption(e,n)}):typeof n==`string`?this.demandOption(e,n):(n===!0||n===void 0)&&this.demandOption(e),this}demandOption(e,t){return F(`<object|string|array> [string]`,[e,t],arguments.length),this[ur](this.demandOption.bind(this),`demandedOptions`,e,t),this}deprecateOption(e,t){return F(`<string> [string|boolean]`,[e,t],arguments.length),L(this,J,`f`).deprecatedOptions[e]=t,this}describe(e,t){return F(`<object|string|array> [string]`,[e,t],arguments.length),this[mr](e,!0),L(this,Z,`f`).describe(e,t),this}detectLocale(e){return F(`<boolean>`,[e],arguments.length),I(this,Pn,e,`f`),this}env(e){return F(`[string|boolean]`,[e],arguments.length),e===!1?delete L(this,J,`f`).envPrefix:L(this,J,`f`).envPrefix=e||``,this}epilogue(e){return F(`<string>`,[e],arguments.length),L(this,Z,`f`).epilog(e),this}epilog(e){return this.epilogue(e)}example(e,t){return F(`<string|array> [string]`,[e,t],arguments.length),Array.isArray(e)?e.forEach(e=>this.example(...e)):L(this,Z,`f`).example(e,t),this}exit(e,t){I(this,G,!0,`f`),I(this,V,t,`f`),L(this,H,`f`)&&L(this,X,`f`).process.exit(e)}exitProcess(e=!0){return F(`[boolean]`,[e],arguments.length),I(this,H,e,`f`),this}fail(e){if(F(`<function|boolean>`,[e],arguments.length),typeof e==`boolean`&&e!==!1)throw new P(`Invalid first argument. Expected function or boolean 'false'`);return L(this,Z,`f`).failFn(e),this}getAliases(){return this.parsed?this.parsed.aliases:{}}async getCompletion(e,t){return F(`<array> [function]`,[e,t],arguments.length),t?L(this,z,`f`).getCompletion(e,t):new Promise((t,n)=>{L(this,z,`f`).getCompletion(e,(e,r)=>{e?n(e):t(r)})})}getDemandedOptions(){return F([],0),L(this,J,`f`).demandedOptions}getDemandedCommands(){return F([],0),L(this,J,`f`).demandedCommands}getDeprecatedOptions(){return F([],0),L(this,J,`f`).deprecatedOptions}getDetectLocale(){return L(this,Pn,`f`)}getExitProcess(){return L(this,H,`f`)}getGroups(){return Object.assign({},L(this,W,`f`),L(this,Un,`f`))}getHelp(){if(I(this,G,!0,`f`),!L(this,Z,`f`).hasCachedHelpMessage()){if(!this.parsed){let e=this[kr](L(this,Wn,`f`),void 0,void 0,0,!0);if(N(e))return e.then(()=>L(this,Z,`f`).help())}let e=L(this,R,`f`).runDefaultBuilderOn(this);if(N(e))return e.then(()=>L(this,Z,`f`).help())}return Promise.resolve(L(this,Z,`f`).help())}getOptions(){return L(this,J,`f`)}getStrict(){return L(this,Kn,`f`)}getStrictCommands(){return L(this,qn,`f`)}getStrictOptions(){return L(this,Jn,`f`)}global(e,t){return F(`<string|array> [boolean]`,[e,t],arguments.length),e=[].concat(e),t===!1?e.forEach(e=>{L(this,J,`f`).local.includes(e)||L(this,J,`f`).local.push(e)}):L(this,J,`f`).local=L(this,J,`f`).local.filter(t=>e.indexOf(t)===-1),this}group(e,t){F(`<string|array> <string>`,[e,t],arguments.length);let n=L(this,Un,`f`)[t]||L(this,W,`f`)[t];L(this,Un,`f`)[t]&&delete L(this,Un,`f`)[t];let r={};return L(this,W,`f`)[t]=(n||[]).concat(e).filter(e=>r[e]?!1:r[e]=!0),this}hide(e){return F(`<string>`,[e],arguments.length),L(this,J,`f`).hiddenOptions.push(e),this}implies(e,t){return F(`<string|object> [number|string|array]`,[e,t],arguments.length),L(this,$,`f`).implies(e,t),this}locale(e){return F(`[string]`,[e],arguments.length),e===void 0?(this[ar](),L(this,X,`f`).y18n.getLocale()):(I(this,Pn,!1,`f`),L(this,X,`f`).y18n.setLocale(e),this)}middleware(e,t,n){return L(this,U,`f`).addMiddleware(e,!!t,n)}nargs(e,t){return F(`<string|object|array> [number]`,[e,t],arguments.length),this[ur](this.nargs.bind(this),`narg`,e,t),this}normalize(e){return F(`<array|string>`,[e],arguments.length),this[lr](`normalize`,e),this}number(e){return F(`<array|string>`,[e],arguments.length),this[lr](`number`,e),this[Mr](e),this}option(e,t){if(F(`<string|object> [object]`,[e,t],arguments.length),typeof e==`object`)Object.keys(e).forEach(t=>{this.options(t,e[t])});else{typeof t!=`object`&&(t={}),this[Mr](e),L(this,Q,`f`)&&(e===`version`||t?.alias===`version`)&&this[er](`"version" is a reserved word.
|
|
112
|
+
Please do one of the following:
|
|
113
|
+
- Disable version with \`yargs.version(false)\` if using "version" as an option
|
|
114
|
+
- Use the built-in \`yargs.version\` method instead (if applicable)
|
|
115
|
+
- Use a different option key
|
|
116
|
+
https://yargs.js.org/docs/#api-reference-version`,void 0,`versionWarning`),L(this,J,`f`).key[e]=!0,t.alias&&this.alias(e,t.alias);let n=t.deprecate||t.deprecated;n&&this.deprecateOption(e,n);let r=t.demand||t.required||t.require;r&&this.demand(e,r),t.demandOption&&this.demandOption(e,typeof t.demandOption==`string`?t.demandOption:void 0),t.conflicts&&this.conflicts(e,t.conflicts),`default`in t&&this.default(e,t.default),t.implies!==void 0&&this.implies(e,t.implies),t.nargs!==void 0&&this.nargs(e,t.nargs),t.config&&this.config(e,t.configParser),t.normalize&&this.normalize(e),t.choices&&this.choices(e,t.choices),t.coerce&&this.coerce(e,t.coerce),t.group&&this.group(e,t.group),(t.boolean||t.type===`boolean`)&&(this.boolean(e),t.alias&&this.boolean(t.alias)),(t.array||t.type===`array`)&&(this.array(e),t.alias&&this.array(t.alias)),(t.number||t.type===`number`)&&(this.number(e),t.alias&&this.number(t.alias)),(t.string||t.type===`string`)&&(this.string(e),t.alias&&this.string(t.alias)),(t.count||t.type===`count`)&&this.count(e),typeof t.global==`boolean`&&this.global(e,t.global),t.defaultDescription&&(L(this,J,`f`).defaultDescription[e]=t.defaultDescription),t.skipValidation&&this.skipValidation(e);let i=t.describe||t.description||t.desc,a=L(this,Z,`f`).getDescriptions();Object.prototype.hasOwnProperty.call(a,e)&&typeof i!=`string`||this.describe(e,i),t.hidden&&this.hide(e),t.requiresArg&&this.requiresArg(e)}return this}options(e,t){return this.option(e,t)}parse(e,t,n){F(`[string|array] [function|boolean|object] [function]`,[e,t,n],arguments.length),this[tr](),e===void 0&&(e=L(this,Wn,`f`)),typeof t==`object`&&(I(this,Vn,t,`f`),t=n),typeof t==`function`&&(I(this,Y,t,`f`),t=!1),t||I(this,Wn,e,`f`),L(this,Y,`f`)&&I(this,H,!1,`f`);let r=this[kr](e,!!t),i=this.parsed;return L(this,z,`f`).setParsed(this.parsed),N(r)?r.then(e=>(L(this,Y,`f`)&&L(this,Y,`f`).call(this,L(this,V,`f`),e,L(this,q,`f`)),e)).catch(e=>{throw L(this,Y,`f`)&&L(this,Y,`f`)(e,this.parsed.argv,L(this,q,`f`)),e}).finally(()=>{this[hr](),this.parsed=i}):(L(this,Y,`f`)&&L(this,Y,`f`).call(this,L(this,V,`f`),r,L(this,q,`f`)),this[hr](),this.parsed=i,r)}parseAsync(e,t,n){let r=this.parse(e,t,n);return N(r)?r:Promise.resolve(r)}parseSync(e,t,n){let r=this.parse(e,t,n);if(N(r))throw new P(`.parseSync() must not be used with asynchronous builders, handlers, or middleware`);return r}parserConfiguration(e){return F(`<object>`,[e],arguments.length),I(this,Bn,e,`f`),this}pkgConf(e,t){F(`<string> [string]`,[e,t],arguments.length);let n=null,r=this[cr](t||L(this,jn,`f`));return r[e]&&typeof r[e]==`object`&&(n=Dn(r[e],t||L(this,jn,`f`),this[rr]()[`deep-merge-config`]||!1,L(this,X,`f`)),L(this,J,`f`).configObjects=(L(this,J,`f`).configObjects||[]).concat(n)),this}positional(e,t){F(`<string> <object>`,[e,t],arguments.length);let n=[`default`,`defaultDescription`,`implies`,`normalize`,`choices`,`conflicts`,`coerce`,`type`,`describe`,`desc`,`description`,`alias`];t=un(t,(e,t)=>e===`type`&&![`string`,`number`,`boolean`].includes(t)?!1:n.includes(e));let r=L(this,Mn,`f`).fullCommands[L(this,Mn,`f`).fullCommands.length-1],i=r?L(this,R,`f`).cmdToParseOptions(r):{array:[],alias:{},default:{},demand:{}};return Gt(i).forEach(n=>{let r=i[n];Array.isArray(r)?r.indexOf(e)!==-1&&(t[n]=!0):r[e]&&!(n in t)&&(t[n]=r[e])}),this.group(e,L(this,Z,`f`).getPositionalGroupName()),this.option(e,t)}recommendCommands(e=!0){return F(`[boolean]`,[e],arguments.length),I(this,Gn,e,`f`),this}required(e,t,n){return this.demand(e,t,n)}require(e,t,n){return this.demand(e,t,n)}requiresArg(e){return F(`<array|string|object> [number]`,[e],arguments.length),typeof e==`string`&&L(this,J,`f`).narg[e]||this[ur](this.requiresArg.bind(this),`narg`,e,NaN),this}showCompletionScript(e,t){return F(`[string] [string]`,[e,t],arguments.length),e||=this.$0,L(this,Rn,`f`).log(L(this,z,`f`).generateCompletionScript(e,t||L(this,B,`f`)||`completion`)),this}showHelp(e){if(F(`[string|function]`,[e],arguments.length),I(this,G,!0,`f`),!L(this,Z,`f`).hasCachedHelpMessage()){if(!this.parsed){let t=this[kr](L(this,Wn,`f`),void 0,void 0,0,!0);if(N(t))return t.then(()=>{L(this,Z,`f`).showHelp(e)}),this}let t=L(this,R,`f`).runDefaultBuilderOn(this);if(N(t))return t.then(()=>{L(this,Z,`f`).showHelp(e)}),this}return L(this,Z,`f`).showHelp(e),this}scriptName(e){return this.customScriptName=!0,this.$0=e,this}showHelpOnFail(e,t){return F(`[boolean|string] [string]`,[e,t],arguments.length),L(this,Z,`f`).showHelpOnFail(e,t),this}showVersion(e){return F(`[string|function]`,[e],arguments.length),L(this,Z,`f`).showVersion(e),this}skipValidation(e){return F(`<array|string>`,[e],arguments.length),this[lr](`skipValidation`,e),this}strict(e){return F(`[boolean]`,[e],arguments.length),I(this,Kn,e!==!1,`f`),this}strictCommands(e){return F(`[boolean]`,[e],arguments.length),I(this,qn,e!==!1,`f`),this}strictOptions(e){return F(`[boolean]`,[e],arguments.length),I(this,Jn,e!==!1,`f`),this}string(e){return F(`<array|string>`,[e],arguments.length),this[lr](`string`,e),this[Mr](e),this}terminalWidth(){return F([],0),L(this,X,`f`).process.stdColumns}updateLocale(e){return this.updateStrings(e)}updateStrings(e){return F(`<object>`,[e],arguments.length),I(this,Pn,!1,`f`),L(this,X,`f`).y18n.updateLocale(e),this}usage(e,t,n,r){if(F(`<string|null|undefined> [string|boolean] [function|object] [function]`,[e,t,n,r],arguments.length),t!==void 0){if(M(e,null,L(this,X,`f`)),(e||``).match(/^\$0( |$)/))return this.command(e,t,n,r);throw new P(`.usage() description must start with $0 if being used as alias for .command()`)}return L(this,Z,`f`).usage(e),this}usageConfiguration(e){return F(`<object>`,[e],arguments.length),I(this,Yn,e,`f`),this}version(e,t,n){let r=`version`;if(F(`[boolean|string] [string] [string]`,[e,t,n],arguments.length),L(this,Q,`f`)&&(this[$n](L(this,Q,`f`)),L(this,Z,`f`).version(void 0),I(this,Q,null,`f`)),arguments.length===0)n=this[or](),e=r;else if(arguments.length===1){if(e===!1)return this;n=e,e=r}else arguments.length===2&&(n=t,t=void 0);return I(this,Q,typeof e==`string`?e:r,`f`),t||=L(this,Z,`f`).deferY18nLookup(`Show version number`),L(this,Z,`f`).version(n||void 0),this.boolean(L(this,Q,`f`)),this.describe(L(this,Q,`f`),t),this}wrap(e){return F(`<number|null|undefined>`,[e],arguments.length),L(this,Z,`f`).wrap(e),this}[(R=/* @__PURE__ */ new WeakMap,jn=/* @__PURE__ */ new WeakMap,Mn=/* @__PURE__ */ new WeakMap,z=/* @__PURE__ */ new WeakMap,B=/* @__PURE__ */ new WeakMap,Nn=/* @__PURE__ */ new WeakMap,V=/* @__PURE__ */ new WeakMap,Pn=/* @__PURE__ */ new WeakMap,Fn=/* @__PURE__ */ new WeakMap,H=/* @__PURE__ */ new WeakMap,In=/* @__PURE__ */ new WeakMap,U=/* @__PURE__ */ new WeakMap,W=/* @__PURE__ */ new WeakMap,G=/* @__PURE__ */ new WeakMap,K=/* @__PURE__ */ new WeakMap,Ln=/* @__PURE__ */ new WeakMap,Rn=/* @__PURE__ */ new WeakMap,q=/* @__PURE__ */ new WeakMap,J=/* @__PURE__ */ new WeakMap,zn=/* @__PURE__ */ new WeakMap,Bn=/* @__PURE__ */ new WeakMap,Y=/* @__PURE__ */ new WeakMap,Vn=/* @__PURE__ */ new WeakMap,Hn=/* @__PURE__ */ new WeakMap,Un=/* @__PURE__ */ new WeakMap,Wn=/* @__PURE__ */ new WeakMap,Gn=/* @__PURE__ */ new WeakMap,X=/* @__PURE__ */ new WeakMap,Kn=/* @__PURE__ */ new WeakMap,qn=/* @__PURE__ */ new WeakMap,Jn=/* @__PURE__ */ new WeakMap,Z=/* @__PURE__ */ new WeakMap,Yn=/* @__PURE__ */ new WeakMap,Q=/* @__PURE__ */ new WeakMap,$=/* @__PURE__ */ new WeakMap,Zn)](e){if(!e._||!e[`--`])return e;e._.push.apply(e._,e[`--`]);try{delete e[`--`]}catch{}return e}[Qn](){return{log:(...e)=>{this[wr]()||console.log(...e),I(this,G,!0,`f`),L(this,q,`f`).length&&I(this,q,L(this,q,`f`)+`
|
|
117
|
+
`,`f`),I(this,q,L(this,q,`f`)+e.join(` `),`f`)},error:(...e)=>{this[wr]()||console.error(...e),I(this,G,!0,`f`),L(this,q,`f`).length&&I(this,q,L(this,q,`f`)+`
|
|
118
|
+
`,`f`),I(this,q,L(this,q,`f`)+e.join(` `),`f`)}}}[$n](e){Gt(L(this,J,`f`)).forEach(t=>{if((e=>e===`configObjects`)(t))return;let n=L(this,J,`f`)[t];Array.isArray(n)?n.includes(e)&&n.splice(n.indexOf(e),1):typeof n==`object`&&delete n[e]}),delete L(this,Z,`f`).getDescriptions()[e]}[er](e,t,n){L(this,Fn,`f`)[n]||(L(this,X,`f`).process.emitWarning(e,t),L(this,Fn,`f`)[n]=!0)}[tr](){L(this,In,`f`).push({options:L(this,J,`f`),configObjects:L(this,J,`f`).configObjects.slice(0),exitProcess:L(this,H,`f`),groups:L(this,W,`f`),strict:L(this,Kn,`f`),strictCommands:L(this,qn,`f`),strictOptions:L(this,Jn,`f`),completionCommand:L(this,B,`f`),output:L(this,q,`f`),exitError:L(this,V,`f`),hasOutput:L(this,G,`f`),parsed:this.parsed,parseFn:L(this,Y,`f`),parseContext:L(this,Vn,`f`)}),L(this,Z,`f`).freeze(),L(this,$,`f`).freeze(),L(this,R,`f`).freeze(),L(this,U,`f`).freeze()}[nr](){let e=``,t;return t=/\b(node|iojs|electron|bun)(\.exe)?$/.test(L(this,X,`f`).process.argv()[0])?L(this,X,`f`).process.argv().slice(1,2):L(this,X,`f`).process.argv().slice(0,1),e=t.map(e=>{let t=this[Dr](L(this,jn,`f`),e);return e.match(/^(\/|([a-zA-Z]:)?\\)/)&&t.length<e.length?t:e}).join(` `).trim(),L(this,X,`f`).getEnv(`_`)&&L(this,X,`f`).getProcessArgvBin()===L(this,X,`f`).getEnv(`_`)&&(e=L(this,X,`f`).getEnv(`_`).replace(`${L(this,X,`f`).path.dirname(L(this,X,`f`).process.execPath())}/`,``)),e}[rr](){return L(this,Bn,`f`)}[ir](){return L(this,Yn,`f`)}[ar](){if(!L(this,Pn,`f`))return;let e=L(this,X,`f`).getEnv(`LC_ALL`)||L(this,X,`f`).getEnv(`LC_MESSAGES`)||L(this,X,`f`).getEnv(`LANG`)||L(this,X,`f`).getEnv(`LANGUAGE`)||`en_US`;this.locale(e.replace(/[.:].*/,``))}[or](){return this[cr]().version||`unknown`}[sr](e){let t=e[`--`]?e[`--`]:e._;for(let e=0,n;(n=t[e])!==void 0;e++)L(this,X,`f`).Parser.looksLikeNumber(n)&&Number.isSafeInteger(Math.floor(parseFloat(`${n}`)))&&(t[e]=Number(n));return e}[cr](e){let t=e||`*`;if(L(this,Hn,`f`)[t])return L(this,Hn,`f`)[t];let n={};try{let t=e||L(this,X,`f`).mainFilename;L(this,X,`f`).path.extname(t)&&(t=L(this,X,`f`).path.dirname(t));let r=L(this,X,`f`).findUp(t,(e,t)=>{if(t.includes(`package.json`))return`package.json`});M(r,void 0,L(this,X,`f`)),n=JSON.parse(L(this,X,`f`).readFileSync(r,`utf8`))}catch{}return L(this,Hn,`f`)[t]=n||{},L(this,Hn,`f`)[t]}[lr](e,t){t=[].concat(t),t.forEach(t=>{t=this[pr](t),L(this,J,`f`)[e].push(t)})}[ur](e,t,n,r){this[fr](e,t,n,r,(e,t,n)=>{L(this,J,`f`)[e][t]=n})}[dr](e,t,n,r){this[fr](e,t,n,r,(e,t,n)=>{L(this,J,`f`)[e][t]=(L(this,J,`f`)[e][t]||[]).concat(n)})}[fr](e,t,n,r,i){if(Array.isArray(n))n.forEach(t=>{e(t,r)});else if((e=>typeof e==`object`)(n))for(let t of Gt(n))e(t,n[t]);else i(t,this[pr](n),r)}[pr](e){return e===`__proto__`?`___proto___`:e}[mr](e,t){return this[ur](this[mr].bind(this),`key`,e,t),this}[hr](){var e,t,n,r,i,a,o,s,c,l,u,d;let f=L(this,In,`f`).pop();M(f,void 0,L(this,X,`f`));let p;e=this,t=this,n=this,r=this,i=this,a=this,o=this,s=this,c=this,l=this,u=this,d=this,{options:{set value(t){I(e,J,t,`f`)}}.value,configObjects:p,exitProcess:{set value(e){I(t,H,e,`f`)}}.value,groups:{set value(e){I(n,W,e,`f`)}}.value,output:{set value(e){I(r,q,e,`f`)}}.value,exitError:{set value(e){I(i,V,e,`f`)}}.value,hasOutput:{set value(e){I(a,G,e,`f`)}}.value,parsed:this.parsed,strict:{set value(e){I(o,Kn,e,`f`)}}.value,strictCommands:{set value(e){I(s,qn,e,`f`)}}.value,strictOptions:{set value(e){I(c,Jn,e,`f`)}}.value,completionCommand:{set value(e){I(l,B,e,`f`)}}.value,parseFn:{set value(e){I(u,Y,e,`f`)}}.value,parseContext:{set value(e){I(d,Vn,e,`f`)}}.value}=f,L(this,J,`f`).configObjects=p,L(this,Z,`f`).unfreeze(),L(this,$,`f`).unfreeze(),L(this,R,`f`).unfreeze(),L(this,U,`f`).unfreeze()}[gr](e,t){return $t(t,t=>(e(t),t))}getInternalMethods(){return{getCommandInstance:this[_r].bind(this),getContext:this[vr].bind(this),getHasOutput:this[yr].bind(this),getLoggerInstance:this[br].bind(this),getParseContext:this[xr].bind(this),getParserConfiguration:this[rr].bind(this),getUsageConfiguration:this[ir].bind(this),getUsageInstance:this[Sr].bind(this),getValidationInstance:this[Cr].bind(this),hasParseCallback:this[wr].bind(this),isGlobalContext:this[Tr].bind(this),postProcess:this[Er].bind(this),reset:this[Or].bind(this),runValidation:this[Ar].bind(this),runYargsParserAndExecuteCommands:this[kr].bind(this),setHasOutput:this[jr].bind(this)}}[_r](){return L(this,R,`f`)}[vr](){return L(this,Mn,`f`)}[yr](){return L(this,G,`f`)}[br](){return L(this,Rn,`f`)}[xr](){return L(this,Vn,`f`)||{}}[Sr](){return L(this,Z,`f`)}[Cr](){return L(this,$,`f`)}[wr](){return!!L(this,Y,`f`)}[Tr](){return L(this,Ln,`f`)}[Er](e,t,n,r){return n||N(e)||(t||(e=this[Zn](e)),(this[rr]()[`parse-positional-numbers`]||this[rr]()[`parse-positional-numbers`]===void 0)&&(e=this[sr](e)),r&&(e=Qt(e,this,L(this,U,`f`).getMiddleware(),!1))),e}[Or](e={}){I(this,J,L(this,J,`f`)||{},`f`);let t={};t.local=L(this,J,`f`).local||[],t.configObjects=L(this,J,`f`).configObjects||[];let n={};return t.local.forEach(t=>{n[t]=!0,(e[t]||[]).forEach(e=>{n[e]=!0})}),Object.assign(L(this,Un,`f`),Object.keys(L(this,W,`f`)).reduce((e,t)=>{let r=L(this,W,`f`)[t].filter(e=>!(e in n));return r.length>0&&(e[t]=r),e},{})),I(this,W,{},`f`),[`array`,`boolean`,`string`,`skipValidation`,`count`,`normalize`,`number`,`hiddenOptions`].forEach(e=>{t[e]=(L(this,J,`f`)[e]||[]).filter(e=>!n[e])}),[`narg`,`key`,`alias`,`default`,`defaultDescription`,`config`,`choices`,`demandedOptions`,`demandedCommands`,`deprecatedOptions`].forEach(e=>{t[e]=un(L(this,J,`f`)[e],e=>!n[e])}),t.envPrefix=L(this,J,`f`).envPrefix,I(this,J,t,`f`),I(this,Z,L(this,Z,`f`)?L(this,Z,`f`).reset(n):pn(this,L(this,X,`f`)),`f`),I(this,$,L(this,$,`f`)?L(this,$,`f`).reset(n):wn(this,L(this,Z,`f`),L(this,X,`f`)),`f`),I(this,R,L(this,R,`f`)?L(this,R,`f`).reset():rn(L(this,Z,`f`),L(this,$,`f`),L(this,U,`f`),L(this,X,`f`)),`f`),L(this,z,`f`)||I(this,z,yn(this,L(this,Z,`f`),L(this,R,`f`),L(this,X,`f`)),`f`),L(this,U,`f`).reset(),I(this,B,null,`f`),I(this,q,``,`f`),I(this,V,null,`f`),I(this,G,!1,`f`),this.parsed=!1,this}[Dr](e,t){return L(this,X,`f`).path.relative(e,t)}[kr](e,t,n,r=0,i=!1){let a=!!n||i;e||=L(this,Wn,`f`),L(this,J,`f`).__=L(this,X,`f`).y18n.__,L(this,J,`f`).configuration=this[rr]();let o=!!L(this,J,`f`).configuration[`populate--`],s=Object.assign({},L(this,J,`f`).configuration,{"populate--":!0}),c=L(this,X,`f`).Parser.detailed(e,Object.assign({},L(this,J,`f`),{configuration:{"parse-positional-numbers":!1,...s}})),l=Object.assign(c.argv,L(this,Vn,`f`)),u,d=c.aliases,f=!1,p=!1;Object.keys(l).forEach(e=>{e===L(this,K,`f`)&&l[e]?f=!0:e===L(this,Q,`f`)&&l[e]&&(p=!0)}),l.$0=this.$0,this.parsed=c,r===0&&L(this,Z,`f`).clearCachedHelpMessage();try{if(this[ar](),t)return this[Er](l,o,!!n,!1);L(this,K,`f`)&&[L(this,K,`f`)].concat(d[L(this,K,`f`)]||[]).filter(e=>e.length>1).includes(``+l._[l._.length-1])&&(l._.pop(),f=!0),I(this,Ln,!1,`f`);let s=L(this,R,`f`).getCommands(),m=L(this,z,`f`)?.completionKey?[L(this,z,`f`)?.completionKey,...this.getAliases()[L(this,z,`f`)?.completionKey]??[]].some(e=>Object.prototype.hasOwnProperty.call(l,e)):!1,h=f||m||i;if(l._.length){if(s.length){let e;for(let t=r||0,a;l._[t]!==void 0;t++){if(a=String(l._[t]),s.includes(a)&&a!==L(this,B,`f`)){let e=L(this,R,`f`).runCommand(a,this,c,t+1,i,f||p||i);return this[Er](e,o,!!n,!1)}if(!e&&a!==L(this,B,`f`)){e=a;break}}!L(this,R,`f`).hasDefaultCommand()&&L(this,Gn,`f`)&&e&&!h&&L(this,$,`f`).recommendCommands(e,s)}L(this,B,`f`)&&l._.includes(L(this,B,`f`))&&!m&&(L(this,H,`f`)&&dn(!0),this.showCompletionScript(),this.exit(0))}if(L(this,R,`f`).hasDefaultCommand()&&!h){let e=L(this,R,`f`).runCommand(null,this,c,0,i,f||p||i);return this[Er](e,o,!!n,!1)}if(m){L(this,H,`f`)&&dn(!0),e=[].concat(e);let t=e.slice(e.indexOf(`--${L(this,z,`f`).completionKey}`)+1);return L(this,z,`f`).getCompletion(t,(e,t)=>{if(e)throw new P(e.message);(t||[]).forEach(e=>{L(this,Rn,`f`).log(e)}),this.exit(0)}),this[Er](l,!o,!!n,!1)}if(L(this,G,`f`)||(f?(L(this,H,`f`)&&dn(!0),a=!0,this.showHelp(e=>{L(this,Rn,`f`).log(e),this.exit(0)})):p&&(L(this,H,`f`)&&dn(!0),a=!0,L(this,Z,`f`).showVersion(`log`),this.exit(0))),!a&&L(this,J,`f`).skipValidation.length>0&&(a=Object.keys(l).some(e=>L(this,J,`f`).skipValidation.indexOf(e)>=0&&l[e]===!0)),!a){if(c.error)throw new P(c.error.message);if(!m){let e=this[Ar](d,{},c.error);n||(u=Qt(l,this,L(this,U,`f`).getMiddleware(),!0)),u=this[gr](e,u??l),N(u)&&!n&&(u=u.then(()=>Qt(l,this,L(this,U,`f`).getMiddleware(),!1)))}}}catch(e){if(e instanceof P)L(this,Z,`f`).fail(e.message,e);else throw e}return this[Er](u??l,o,!!n,!0)}[Ar](e,t,n,r){let i={...this.getDemandedOptions()};return a=>{if(n)throw new P(n.message);L(this,$,`f`).nonOptionCount(a),L(this,$,`f`).requiredArguments(a,i);let o=!1;L(this,qn,`f`)&&(o=L(this,$,`f`).unknownCommands(a)),L(this,Kn,`f`)&&!o?L(this,$,`f`).unknownArguments(a,e,t,!!r):L(this,Jn,`f`)&&L(this,$,`f`).unknownArguments(a,e,{},!1,!1),L(this,$,`f`).limitedChoices(a),L(this,$,`f`).implications(a),L(this,$,`f`).conflicting(a)}}[jr](){I(this,G,!0,`f`)}[Mr](e){if(typeof e==`string`)L(this,J,`f`).key[e]=!0;else for(let t of e)L(this,J,`f`).key[t]=!0}};function Pr(e){return!!e&&typeof e.getInternalMethods==`function`}const Fr=Xn(Ut),Ir=[{command:i(`abuse-reports`,`Submit and track abuse reports for phishing, malware, and other policy violations on Cloudflare-proxied sites`,()=>import(`./abuse-reports-D9edOyag.mjs`),null),hideCommand:!1},{command:i(`access`,`Access protected applications and services`,()=>import(`./access-CKCCSrrU.mjs`),null),hideCommand:!1},{command:i(`accounts`,`Account settings, members, roles, subscriptions, and API tokens for your Cloudflare account`,()=>import(`./accounts-CNb9U9bK.mjs`),null),hideCommand:!1},{command:i(`acm`,`acm`,()=>import(`./acm-CdKTAToZ.mjs`),null),hideCommand:!1},{command:i(`addressing`,`addressing`,()=>import(`./addressing-eZI_C-b0.mjs`),null),hideCommand:!1},{command:i(`agent-memory`,`agent-memory`,()=>import(`./agent-memory-BBHCEE7h.mjs`),null),hideCommand:!1},{command:i(`ai`,`ai`,()=>import(`./ai-Csl_QNwv.mjs`),null),hideCommand:!1},{command:i(`ai-audit`,`ai-audit`,()=>import(`./ai-audit-DlqWsQi-.mjs`),null),hideCommand:!1},{command:i(`ai-gateway`,`Proxy, cache, rate-limit, and observe requests to AI providers — OpenAI, Anthropic, Workers AI, and more`,()=>import(`./ai-gateway-Lj4On37s.mjs`),null),hideCommand:!1},{command:i(`ai-search`,`Managed search-as-a-service: crawl, index, and query content with AI-powered relevance and chat completions`,()=>import(`./ai-search-BxyhS3X7.mjs`),null),hideCommand:!1},{command:i(`ai-security`,`Detect prompt injection, PII, and unsafe topics in traffic to your AI applications`,()=>import(`./ai-security-DvU2iYkY.mjs`),null),hideCommand:!1},{command:i(`alerting`,`alerting`,()=>import(`./alerting-r0G2X9y9.mjs`),null),hideCommand:!1},{command:i(`analytics`,`Zone-level traffic analytics — dashboard summaries, per-colo breakdowns, and Argo latency metrics`,()=>import(`./analytics-C6bfqm-W.mjs`),null),hideCommand:!1},{command:i(`analytics-engine`,`analytics-engine`,()=>import(`./analytics-engine-BlIecoOe.mjs`),null),hideCommand:!1},{command:i(`api-security`,`api-security`,()=>import(`./api-security-DZ7GWOqD.mjs`),null),hideCommand:!1},{command:i(`argo`,`Network optimization features that speed up and improve reliability of traffic to your origins`,()=>import(`./argo-Bh0_cj49.mjs`),null),hideCommand:!1},{command:i(`artifacts`,`artifacts`,()=>import(`./artifacts-VZJWVq_6.mjs`),null),hideCommand:!1},{command:i(`audit-logs`,`audit-logs`,()=>import(`./audit-logs-B8cGL4B9.mjs`),null),hideCommand:!1},{command:i(`basin-catalog`,`Iceberg-compatible data catalog for R2 — organize objects into tables and namespaces for SQL query engines`,()=>import(`./basin-catalog-TehR1sKZ.mjs`),null),hideCommand:!1},{command:i(`billing`,`Account billing profiles and usage data for Cloudflare subscriptions and add-on services`,()=>import(`./billing-B2KusU6g.mjs`),null),hideCommand:!1},{command:i(`bot-management`,`bot-management`,()=>import(`./bot-management-CXHXgrQC.mjs`),null),hideCommand:!1},{command:i(`botnet-feed`,`Botnet threat intelligence feeds — IP and ASN-level data on known command-and-control infrastructure`,()=>import(`./botnet-feed-UyK7Rfp6.mjs`),null),hideCommand:!1},{command:i(`brand-protection`,`brand-protection`,()=>import(`./brand-protection-kv1ba80i.mjs`),null),hideCommand:!1},{command:i(`browser-run`,`browser-run`,()=>import(`./browser-run-D-vRoZmf.mjs`),null),hideCommand:!1},{command:i(`builds`,`Build and deploy Workers from connected repositories, then inspect build status and logs.`,()=>import(`./builds-BbxINHRP.mjs`),null),hideCommand:!1},{command:i(`cache`,`Purge cached content and configure Cache Reserve, tiered caching, and variant serving`,()=>import(`./cache-BacNNtLu.mjs`),null),hideCommand:!1},{command:i(`client-side-security`,`Client-Side Security — monitor JavaScript, connections, and cookies on your pages for supply-chain attacks`,()=>import(`./client-side-security-bzB9JosR.mjs`),null),hideCommand:!1},{command:i(`cloud-connector`,`Route traffic from Cloudflare directly to cloud provider services (AWS, Azure, GCP) without origin servers`,()=>import(`./cloud-connector-BHtf37R5.mjs`),null),hideCommand:!1},{command:i(`cloudforce-one`,`Detection rule management APIs`,()=>import(`./cloudforce-one-DWBPQDA3.mjs`),null),hideCommand:!1},{command:i(`connector-interrupts`,`connector-interrupts`,()=>import(`./connector-interrupts-dUPW6Ya_.mjs`),null),hideCommand:!1},{command:i(`connector-telemetry-events`,`connector-telemetry-events`,()=>import(`./connector-telemetry-events-DWVCqnhn.mjs`),null),hideCommand:!1},{command:i(`connector-telemetry-snapshots`,`connector-telemetry-snapshots`,()=>import(`./connector-telemetry-snapshots-CeMP3qeI.mjs`),null),hideCommand:!1},{command:i(`connectors`,`connectors`,()=>import(`./connectors-DZFGNw3i.mjs`),null),hideCommand:!1},{command:i(`containers`,`Deploy and manage Containers applications on Cloudflare's global network`,()=>import(`./containers-DCzQCo79.mjs`),null),hideCommand:!1},{command:i(`content-scan`,`Malicious uploads detection, scan uploaded content in HTTP requests for malware and malicious payloads`,()=>import(`./content-scan-XhnNJqXf.mjs`),null),hideCommand:!1},{command:i(`cps`,`cps`,()=>import(`./cps-CohlxvuN.mjs`),null),hideCommand:!1},{command:i(`csam-scanner`,`csam-scanner`,()=>import(`./csam-scanner-BV4bHq8v.mjs`),null),hideCommand:!1},{command:i(`custom-csrs`,`custom-csrs`,()=>import(`./custom-csrs-BVdMQjYq.mjs`),null),hideCommand:!1},{command:i(`custom-hostnames`,`custom-hostnames`,()=>import(`./custom-hostnames-r-CxhSa1.mjs`),null),hideCommand:!1},{command:i(`custom-nameservers`,`custom-nameservers`,()=>import(`./custom-nameservers-CapMDyly.mjs`),null),hideCommand:!1},{command:i(`custom-pages`,`Manage custom error and challenge pages and their assets for accounts and zones`,()=>import(`./custom-pages-BVIniWfq.mjs`),null),hideCommand:!1},{command:i(`d1`,`D1 is Cloudflare's managed, serverless database with SQLite's SQL semantics, built-in disaster recovery, and Worker and HTTP API access.`,()=>import(`./d1-nJCOJZb8.mjs`),null),hideCommand:!1},{command:i(`diagnostics`,`Network diagnostic tools — traceroutes from Cloudflare's edge and endpoint health checks`,()=>import(`./diagnostics-C3nqxsAO.mjs`),null),hideCommand:!1},{command:i(`dls`,`dls`,()=>import(`./dls-N1x8sAK3.mjs`),null),hideCommand:!1},{command:i(`dns`,`dns`,()=>import(`./dns-DATWP-PF.mjs`),null),hideCommand:!1},{command:i(`dns-firewall`,`dns-firewall`,()=>import(`./dns-firewall-n3Y2ui6W.mjs`),null),hideCommand:!1},{command:i(`durable-objects`,`Stateful serverless objects with transactional storage, ideal for coordination, sessions, and real-time collaboration`,()=>import(`./durable-objects-DHK9w-vO.mjs`),null),hideCommand:!1},{command:i(`email-auth`,`email-auth`,()=>import(`./email-auth-ptdqNSTZ.mjs`),null),hideCommand:!1},{command:i(`email-domains`,`email-domains`,()=>import(`./email-domains-uL22-zRY.mjs`),null),hideCommand:!1},{command:i(`email-routing`,`Route incoming email to verified destination addresses or Workers with routing rules, catch-all behavior, and managed DNS records`,()=>import(`./email-routing-CV43rMJC.mjs`),null),hideCommand:!1},{command:i(`email-security`,`Cloud email security — investigate threats, manage allow/block policies, and detect phishing`,()=>import(`./email-security-DK_SJ0yi.mjs`),null),hideCommand:!1},{command:i(`email-sending`,`Send transactional email and manage sending subdomains and their DNS configuration`,()=>import(`./email-sending-CTQafGec.mjs`),null),hideCommand:!1},{command:i(`field-extractors`,`field-extractors`,()=>import(`./field-extractors-jcZ_bAGc.mjs`),null),hideCommand:!1},{command:i(`firewall`,`Legacy firewall rules, zone lockdowns, access rules, user-agent blocking, and WAF packages`,()=>import(`./firewall-CW-fAI9m.mjs`),null),hideCommand:!1},{command:i(`flagship`,`flagship`,()=>import(`./flagship-RiLnDwfJ.mjs`),null),hideCommand:!1},{command:i(`fraud`,`fraud`,()=>import(`./fraud-DvfBBTe8.mjs`),null),hideCommand:!1},{command:i(`google-tag-gateway`,`Google Tag Gateway operations`,()=>import(`./google-tag-gateway-C5WYsSXv.mjs`),null),hideCommand:!1},{command:i(`healthchecks`,`Standalone health checks that monitor origin server availability from Cloudflare's edge`,()=>import(`./healthchecks-BA1fmzTm.mjs`),null),hideCommand:!1},{command:i(`hyperdrive`,`Accelerate access to existing databases by caching queries and pooling connections at the edge`,()=>import(`./hyperdrive-Ch6klUp3.mjs`),null),hideCommand:!1},{command:i(`iam`,`Identity and access management — permission groups, resource groups, user groups, and SSO connectors`,()=>import(`./iam-LlGEzRCq.mjs`),null),hideCommand:!1},{command:i(`images`,`Store, resize, and deliver optimized images globally — variants, signing keys, and direct uploads`,()=>import(`./images-C5WqUXkK.mjs`),null),hideCommand:!1},{command:i(`intel`,`Threat intelligence lookups — IP reputation, domain info, ASN details, WHOIS, and indicator feeds`,()=>import(`./intel-vcWyslaX.mjs`),null),hideCommand:!1},{command:i(`internal`,`internal`,()=>import(`./internal-BhV9WjLp.mjs`),null),hideCommand:!0},{command:i(`ips`,`ips`,()=>import(`./ips-CqHjVsqd.mjs`),null),hideCommand:!0},{command:i(`k2`,`Durable, ordered event streams that you produce records to and consume from with subscriptions`,()=>import(`./k2-CZT2Pd5J.mjs`),null),hideCommand:!1},{command:i(`kv`,`kv`,()=>import(`./kv-Ipa7dnvF.mjs`),null),hideCommand:!1},{command:i(`leaked-credential-checks`,`Detect compromised credentials in login requests by checking against known breach databases`,()=>import(`./leaked-credential-checks-EzT4TTjO.mjs`),null),hideCommand:!1},{command:i(`live`,`live`,()=>import(`./live-C9L1bNuE.mjs`),null),hideCommand:!0},{command:i(`load-balancers`,`Distribute traffic across origin pools with health monitoring, geo-steering, and failover`,()=>import(`./load-balancers-Cb3VkSfc.mjs`),null),hideCommand:!1},{command:i(`logpush`,`logpush`,()=>import(`./logpush-C5Gw7F_9.mjs`),null),hideCommand:!1},{command:i(`logs`,`Log control, retention, and raw log access — CMB config, ray ID lookups, and received fields`,()=>import(`./logs-y3REfHbb.mjs`),null),hideCommand:!1},{command:i(`magic-network-monitoring`,`Flow-based network traffic monitoring with configurable alerting rules and VPC flow ingestion`,()=>import(`./magic-network-monitoring-BZBGZB6M.mjs`),null),hideCommand:!0},{command:i(`magic-transit`,`DDoS-protected network transit — GRE/IPsec tunnels, static routes, Magic WAN sites, connectors, and packet captures`,()=>import(`./magic-transit-BPV_POf5.mjs`),null),hideCommand:!1},{command:i(`managed-defense`,`managed-defense`,()=>import(`./managed-defense-BaUBSUcz.mjs`),null),hideCommand:!1},{command:i(`managed-transforms`,`managed-transforms`,()=>import(`./managed-transforms-CjkjLzMC.mjs`),null),hideCommand:!1},{command:i(`mcp`,`Manage MCP portals and upstream MCP servers for Cloudflare Access AI controls`,()=>import(`./mcp-RPtrISTy.mjs`),null),hideCommand:!1},{command:i(`mesh`,`mesh`,()=>import(`./mesh-DZ4QHBPE.mjs`),null),hideCommand:!1},{command:i(`monetization`,`monetization`,()=>import(`./monetization-CVZqM8Xo.mjs`),null),hideCommand:!1},{command:i(`network`,`network`,()=>import(`./network-DLt2JUo1.mjs`),null),hideCommand:!1},{command:i(`network-interconnects`,`Physical and virtual private interconnects between your infrastructure and Cloudflare's network`,()=>import(`./network-interconnects-9nS5jL__.mjs`),null),hideCommand:!1},{command:i(`o11y`,`o11y`,()=>import(`./o11y-ySxrnP1Z.mjs`),null),hideCommand:!1},{command:i(`observability`,`observability`,()=>import(`./observability-C-KNh__y.mjs`),null),hideCommand:!1},{command:i(`ohttp-gateway`,`ohttp-gateway`,()=>import(`./ohttp-gateway-B5nCl4s3.mjs`),null),hideCommand:!1},{command:i(`organizations`,`Multi-user organizations that group accounts, members, and shared settings under a single entity`,()=>import(`./organizations-DbeeWUL4.mjs`),null),hideCommand:!1},{command:i(`page-rules`,`page-rules`,()=>import(`./page-rules-DRw763O1.mjs`),null),hideCommand:!1},{command:i(`pages`,`Full-stack application hosting with Git-integrated builds, preview deployments, and custom domains`,()=>import(`./pages-DfQnxiTk.mjs`),null),hideCommand:!1},{command:i(`pay-per-crawl`,`pay-per-crawl`,()=>import(`./pay-per-crawl-EHYtSKxX.mjs`),null),hideCommand:!1},{command:i(`pay-per-use`,`pay-per-use`,()=>import(`./pay-per-use-wdEhl8k4.mjs`),null),hideCommand:!1},{command:i(`pipelines`,`Ingest, transform, and route event streams into R2, analytics, or other destinations in real time`,()=>import(`./pipelines-DbyrI6F4.mjs`),null),hideCommand:!1},{command:i(`precursor`,`Precursor settings for a zone`,()=>import(`./precursor-Dx8lN4UJ.mjs`),null),hideCommand:!1},{command:i(`previews`,`Manage Worker Previews`,()=>import(`./previews-DEVNSip2.mjs`),null),hideCommand:!1},{command:i(`queues`,`Reliable message queuing between Workers — produce, consume, and batch-process messages at scale`,()=>import(`./queues-DgMc7Z6A.mjs`),null),hideCommand:!1},{command:i(`r2`,`S3-compatible object storage with zero egress fees — buckets, lifecycle rules, event notifications, and data migration`,()=>import(`./r2-BpTVicIq.mjs`),null),hideCommand:!1},{command:i(`radar`,`Internet-wide traffic intelligence — BGP, DNS, HTTP trends, attack data, and network quality insights`,()=>import(`./radar-DW-S1VUh.mjs`),null),hideCommand:!1},{command:i(`ready`,`ready`,()=>import(`./ready-d0li0X6r.mjs`),null),hideCommand:!0},{command:i(`realtime`,`Real-time audio, video, and data services on Cloudflare's global network`,()=>import(`./realtime-DMKHLYF4.mjs`),null),hideCommand:!1},{command:i(`registrar`,`registrar`,()=>import(`./registrar-D23gfKBi.mjs`),null),hideCommand:!1},{command:i(`registrar-sandbox`,`registrar-sandbox`,()=>import(`./registrar-sandbox-lVLB1-mC.mjs`),null),hideCommand:!1},{command:i(`reporting`,`reporting`,()=>import(`./reporting-WX8P3Y0k.mjs`),null),hideCommand:!1},{command:i(`request-tracers`,`Trace how a request would be processed through Cloudflare's rules and configuration pipeline`,()=>import(`./request-tracers-qd7XOAka.mjs`),null),hideCommand:!1},{command:i(`resource-sharing`,`Share account-level resources (WAF custom rulesets, Gateway policies and settings, Access IdP federation grants) with other accounts in the same organization`,()=>import(`./resource-sharing-B2ZSt_cA.mjs`),null),hideCommand:!1},{command:i(`rules`,`Resources used by Cloudflare rules and rulesets`,()=>import(`./rules-CB0QQTB3.mjs`),null),hideCommand:!1},{command:i(`rulesets`,`rulesets`,()=>import(`./rulesets-DmqwixUC.mjs`),null),hideCommand:!1},{command:i(`rum`,`Real User Measurement (Web Analytics) — track page loads, Core Web Vitals, and visitor metrics`,()=>import(`./rum-BZ_24qZU.mjs`),null),hideCommand:!0},{command:i(`scim`,`SCIM 2.0 provisioning — manage users, groups, and identity provider sync for your account`,()=>import(`./scim-DchxaJfE.mjs`),null),hideCommand:!1},{command:i(`secrets-store`,`Centralized secret management — store API keys, tokens, and credentials for use across Workers and other products`,()=>import(`./secrets-store-oAft1cFE.mjs`),null),hideCommand:!1},{command:i(`security-insights`,`security-insights`,()=>import(`./security-insights-DMm0qg_m.mjs`),null),hideCommand:!1},{command:i(`security-txt`,`Manage the /.well-known/security.txt file that tells security researchers how to report vulnerabilities`,()=>import(`./security-txt-CIt0494b.mjs`),null),hideCommand:!1},{command:i(`signed-url`,`signed-url`,()=>import(`./signed-url-gNangfwc.mjs`),null),hideCommand:!0},{command:i(`smart-shield`,`Smart Shield settings, health checks, and cache reserve management`,()=>import(`./smart-shield-Boy_qbqd.mjs`),null),hideCommand:!1},{command:i(`snippets`,`snippets`,()=>import(`./snippets-DdoDYXW-.mjs`),null),hideCommand:!1},{command:i(`spectrum`,`Proxy and protect arbitrary TCP/UDP applications through Cloudflare's network with DDoS mitigation`,()=>import(`./spectrum-DLYIHelC.mjs`),null),hideCommand:!1},{command:i(`speed`,`Observatory speed tests — run Lighthouse audits, track performance trends, and schedule recurring tests`,()=>import(`./speed-DugG9Tm9.mjs`),null),hideCommand:!1},{command:i(`sql`,`sql`,()=>import(`./sql-Bb56llsb.mjs`),null),hideCommand:!1},{command:i(`ssl`,`SSL/TLS certificate management — certificate packs, Universal SSL, verification, and TLS mode recommendations`,()=>import(`./ssl-Bg4X3WGk.mjs`),null),hideCommand:!1},{command:i(`stream`,`Video encoding, storage, and delivery — upload, live-stream, clip, caption, and embed video at scale`,()=>import(`./stream-BuZYDbNR.mjs`),null),hideCommand:!1},{command:i(`tags`,`tags`,()=>import(`./tags-SKz2odE_.mjs`),null),hideCommand:!1},{command:i(`tenant-custom-nameservers`,`tenant-custom-nameservers`,()=>import(`./tenant-custom-nameservers-BhkhBerL.mjs`),null),hideCommand:!1},{command:i(`tenants`,`Multi-tenant account management`,()=>import(`./tenants-DD-GMq0K.mjs`),null),hideCommand:!1},{command:i(`tunnels`,`tunnels`,()=>import(`./tunnels-D90ztENM.mjs`),null),hideCommand:!1},{command:i(`turnstile`,`CAPTCHA-free bot verification widgets that protect forms and APIs without degrading user experience`,()=>import(`./turnstile-DhSU_Xar.mjs`),null),hideCommand:!1},{command:i(`url-normalization`,`url-normalization`,()=>import(`./url-normalization-K7gkmPvG.mjs`),null),hideCommand:!1},{command:i(`url-scanner`,`Scan URLs for phishing, malware, and other threats — submit scans and retrieve detailed results`,()=>import(`./url-scanner-BRdWwka4.mjs`),null),hideCommand:!1},{command:i(`user`,`Your Cloudflare user profile, invitations, organizations, billing, and personal API tokens`,()=>import(`./user-Cmb1_Wu5.mjs`),null),hideCommand:!1},{command:i(`vectorize`,`Globally distributed vector database for building semantic search, recommendations, and RAG applications on Workers`,()=>import(`./vectorize-BTBerJME.mjs`),null),hideCommand:!1},{command:i(`waiting-rooms`,`Virtual queues that throttle traffic to your site during peak demand with customizable waiting pages`,()=>import(`./waiting-rooms-LymmKIGr.mjs`),null),hideCommand:!1},{command:i(`web-assets`,`web-assets`,()=>import(`./web-assets-LHPQsrnY.mjs`),null),hideCommand:!1},{command:i(`web3`,`web3`,()=>import(`./web3-BsOio0Ae.mjs`),null),hideCommand:!0},{command:i(`workers`,`Deploy and manage serverless JavaScript/WASM applications on Cloudflare's global network`,()=>import(`./workers-BnLiOjZf.mjs`),null),hideCommand:!1},{command:i(`workers-builds`,`workers-builds`,()=>import(`./workers-builds-sKpITeRk.mjs`),null),hideCommand:!1},{command:i(`workers-for-platforms`,`Workers for Platforms uses dispatch namespaces to isolate and route requests to many individual user Workers, letting platforms run untrusted customer or AI-generated code at scale with per-tenant bindings, limits, and observability`,()=>import(`./workers-for-platforms-BGp6yr6P.mjs`),null),hideCommand:!1},{command:i(`workers-vpc`,`workers-vpc`,()=>import(`./workers-vpc-D8lefWDo.mjs`),null),hideCommand:!1},{command:i(`workflows`,`Durable, multi-step workflows that run on Workers with automatic retries and state persistence`,()=>import(`./workflows-B-ZIG3y7.mjs`),null),hideCommand:!1},{command:i(`zaraz`,`Server-side tag manager — load third-party tools (analytics, pixels, etc.) from Cloudflare's edge without client-side JS`,()=>import(`./zaraz-BBKki5WS.mjs`),null),hideCommand:!1},{command:i(`zero-trust`,`Cloudflare's SASE platform — secure access, device posture, DLP, tunnels, gateway policies, and network segmentation`,()=>import(`./zero-trust-BZDXM5r6.mjs`),null),hideCommand:!1},{command:i(`zones`,`Zones are domains on Cloudflare — list, create, and configure domain settings`,()=>import(`./zones-B-UV_DGE.mjs`),null),hideCommand:!1}];function Lr(e){return typeof e==`object`&&!!e&&`schemas`in e&&typeof e.schemas==`object`&&e.schemas!==null&&!Array.isArray(e.schemas)}function Rr(e,t){if(!t)return e;let n=a(import.meta.url,`schemas.json`,Lr);return!n||!Object.hasOwn(n.schemas,t)?e:`${e}\n\n${o.italic(`To inspect the exact API request, run ${o.code(`cf schema ${t}`)}`)}`}const zr=[{kind:`root`,dryRun:`preview`,command:`auth`,describe:`Manage authentication and profiles`,dir:`auth`},{kind:`root`,dryRun:`preview`,command:`login`,describe:!1,dir:`login`},{kind:`root`,dryRun:`preview`,command:`build`,describe:`Build a project for Cloudflare`,dir:`build`},{kind:`root`,dryRun:`preview`,command:`complete [shell]`,describe:`Generate and handle shell completions`,dir:`completions`},{kind:`root`,dryRun:`native`,command:`deploy`,describe:`Deploy a Worker, static site, or full-stack application to Cloudflare`,dir:`deploy`},{kind:`root`,dryRun:`preview`,command:`dev [implArgs..]`,describe:`Run the project's Cloudflare dev server`,dir:`dev`},{kind:`root`,dryRun:`preview`,command:`docs`,describe:`Search live Cloudflare documentation`,dir:`docs`},{kind:`root`,dryRun:`preview`,command:`init [directory]`,describe:`Create a new Cloudflare project or set up an existing one`,dir:`init`},{kind:`root`,dryRun:`native`,command:`migrate [path]`,describe:`Migrate a Wrangler project to cf`,dir:`migrate`},{kind:`root`,dryRun:`preview`,command:`cli`,describe:`Discover commands and configure the cf CLI`,dir:`cli`},{kind:`leaf`,dryRun:`preview`,parent:`previews`,name:`deploy`,dir:`previews/deploy`},{kind:`parentOverride`,parent:`previews`,describe:`Manage Worker Previews`,expose:!0,createIfMissing:!0},{kind:`root`,dryRun:`preview`,command:`schema [command..]`,describe:`Show API schema details for a command`,dir:`schema`},{kind:`root`,dryRun:`preview`,command:`tools`,describe:!1,dir:`tools`},{kind:`leafOverride`,dryRun:`native`,emitKey:`ai/run`,dir:`ai/run`},{kind:`leafOverride`,dryRun:`native`,emitKey:`registrar/registrations/create`,dir:`registrar/registrations/create`},{kind:`leaf`,dryRun:`native`,parent:`workers/versions`,name:`create`,dir:`workers/versions/create`},{kind:`leaf`,dryRun:`preview`,parent:`containers`,name:`build`,dir:`containers/build`},{kind:`leaf`,dryRun:`preview`,parent:`containers`,name:`push`,dir:`containers/push`},{kind:`leaf`,dryRun:`preview`,parent:`containers/images`,name:`list`,dir:`containers/images/list`},{kind:`leaf`,dryRun:`preview`,parent:`containers/images`,name:`delete`,dir:`containers/images/delete`},{kind:`leaf`,dryRun:`preview`,parent:`containers`,name:`ssh`,dir:`containers/ssh`},{kind:`leaf`,dryRun:`preview`,parent:`pages`,name:`deploy`,dir:`pages/deploy`},{kind:`leaf`,dryRun:`preview`,parent:`workers`,name:`check`,dir:`workers/check`},{kind:`leaf`,dryRun:`preview`,parent:`workers`,name:`types`,dir:`workers/types`},{kind:`parentOverride`,parent:`access`,describe:`Access protected applications and services`,expose:!0},{kind:`leaf`,dryRun:`preview`,parent:`access`,name:`login`,dir:`access/login`},{kind:`leaf`,dryRun:`preview`,parent:`access`,name:`token`,dir:`access/token`},{kind:`leaf`,dryRun:`preview`,parent:`access`,name:`ssh-config`,dir:`access/ssh-config`},{kind:`leaf`,dryRun:`preview`,parent:`access`,name:`ssh-gen`,dir:`access/ssh-gen`},{kind:`leaf`,dryRun:`preview`,parent:`access`,name:`tcp`,dir:`access/tcp`},{kind:`leaf`,dryRun:`preview`,parent:`access`,name:`curl`,dir:`access/curl`},{kind:`leaf`,dryRun:`preview`,parent:`tunnels`,name:`diag`,dir:`tunnels/diag`},{kind:`leaf`,dryRun:`preview`,parent:`tunnels`,name:`login`,dir:`tunnels/login`},{kind:`leaf`,dryRun:`preview`,parent:`tunnels`,name:`quick-start`,dir:`tunnels/quick-start`},{kind:`leaf`,dryRun:`preview`,parent:`tunnels`,name:`ready`,dir:`tunnels/ready`},{kind:`leaf`,dryRun:`preview`,parent:`tunnels`,name:`run`,dir:`tunnels/run`},{kind:`leaf`,dryRun:`preview`,parent:`tunnels`,name:`tail`,dir:`tunnels/tail`},{kind:`subgroup`,dryRun:`preview`,parent:`d1`,name:`migrations`,dir:`d1/migrations`,describe:`Create, list, and apply D1 database migrations`},{kind:`subgroup`,dryRun:`native`,parent:`workers`,name:`triggers`,dir:`workers/triggers`,describe:`Manage triggers (Routes, Workflows, Cron triggers etc.)`}];function Br(){return zr.filter(e=>e.kind===`root`)}function Vr(e){return e.command.split(/\s+/)[0]??e.command}const Hr={auth:{load:()=>import(`./auth-clmqFEWU.mjs`),telemetry:{command:`auth`,recordArgs:!1}},login:{load:()=>import(`./login-DRJugxya.mjs`),telemetry:null},build:{load:()=>import(`./build-BzJGqb2o.mjs`),telemetry:{command:`build`,classification:{safeFlags:[]}}},completions:{load:()=>import(`./completions-BvdKtzsX.mjs`),telemetry:null},deploy:{load:()=>import(`./deploy-DJMnWFNk.mjs`),telemetry:{command:`deploy`,classification:{safeFlags:[`dry-run`,`prebuilt`,`containers-rollout`,`provision`]}}},dev:{load:()=>import(`./dev-GsYHvMah.mjs`),telemetry:{command:`dev`,recordArgs:!1}},init:{load:()=>import(`./init-EVsjBrOz.mjs`),telemetry:{command:`init`,classification:{safeFlags:[`install`,`package-manager`]}}},migrate:{load:()=>import(`./migrate-CRIUqGi2.mjs`),telemetry:{command:`migrate`,recordArgs:!1}},docs:{load:()=>import(`./docs-CRc_WOXh.mjs`),telemetry:{command:`docs`,recordArgs:!1}},cli:{load:()=>import(`./cli-B7vslRfu.mjs`),telemetry:{command:`cli`,recordArgs:!1}},schema:{load:()=>import(`./schema-Dj9STsWI.mjs`),telemetry:{command:`schema`,classification:{safeFlags:[`list`]}}},tools:{load:()=>import(`./tools-KW_4hvzY.mjs`),telemetry:{command:`tools`,classification:{safeFlags:[`text`]}}}};function Ur(){return Br().map(e=>({...e,...Hr[e.dir]}))}function Wr(e,t){let n=t.alias;return[e,...Array.isArray(n)?n:n===void 0?[]:[n]]}function Gr(e){return e.length===1?`-${e}`:`--${e}`}const Kr=new Set(v),qr=Object.entries({..._,...y}).filter(([,e])=>!e.hidden).map(([e,t])=>` ${Wr(e,t).sort((e,t)=>e.length-t.length).map(Gr).join(`, `)}`).join(`
|
|
119
|
+
`);function Jr(e,t){return Object.entries(_).some(([n,r])=>r.type===`boolean`&&t!==`true`&&t!==`false`?!1:Wr(n,r).some(t=>e===Gr(t)))}const Yr=Ur().map(e=>b(i(e.command,e.describe,e.load,e.telemetry),e.dryRun)),Xr=new Set(Br().map(Vr));function Zr(e){return s().isAgentic?`=== STOP: AGENT COMMAND DISCOVERY ===
|
|
120
|
+
AGENTS: Do not explore commands by chaining nested --help calls.
|
|
121
|
+
Your first port of call and the best way to discover commands is:
|
|
122
|
+
AGENTS: Keep cf cli search and cf docs search queries anonymous; describe the action and resource type only.
|
|
123
|
+
Never include names, email addresses, domains, account or resource IDs, tokens, or other identifying values.
|
|
124
|
+
cf cli search "<describe the task you want to accomplish>"
|
|
125
|
+
It returns five compact JSON matches with short descriptions. Pick the best match instead of repeating similar searches.
|
|
126
|
+
Run \`<discovered command> --help\` for detailed command help.
|
|
127
|
+
For API request details, replace the result's leading \`cf\` with \`cf schema\`.
|
|
128
|
+
For Cloudflare documentation, guides, and examples, use cf docs search "<question>".
|
|
129
|
+
It returns ranked JSON results. Fetch a result's URL with Accept: text/markdown to read the full page.
|
|
130
|
+
=== END AGENT COMMAND DISCOVERY ===\n${e}`:e}function Qr(e,t){return Zr(Rr(e,t))}async function $r(e=!1){if(!process.stderr.isTTY||e||c(process.argv.slice(2))||ni()===`complete`)return;let{isCI:t}=await import(`./interactive-CHcvofEp.mjs`);if(t)return;let{readState:n,updateState:r}=await import(`./state-DW3QZtfh.mjs`);if(n().completions?.prompted)return;r({completions:{prompted:!0}});let{log:i}=await import(`./log-DZfik9Jk.mjs`);i.info(`Tip: run ${o.code(`cf complete <bash|zsh|fish|powershell>`)} to install shell completions.`)}let ei;function ti(){return ei??=import(`./telemetry-B4zmCpT0.mjs`),ei}function ni(e=process.argv.slice(2)){return ri(e,1)[0]}function ri(e=process.argv.slice(2),t=2){let n=[];for(let r=0;r<e.length&&n.length<t;r++){let t=e[r];if(t===void 0||t===`--`)break;Jr(t,e[r+1])?r++:t.startsWith(`-`)||n.push(t)}return n}async function ii(e=!1){if(!process.stderr.isTTY)return;let t=process.argv.slice(2);if(e||c(t)||t.includes(`--help`)||t.includes(`-h`)||hi(ri(t).join(` `)))return;let{getBannerLastShown:n,getTelemetryDispatcher:r,setBannerLastShown:i}=await ti();if(!r().enabled||n()===f)return;let{log:a}=await import(`./log-DZfik9Jk.mjs`);a.info(`Cloudflare collects anonymous cf usage telemetry. Run ${o.code(`cf cli telemetry disable`)} to opt out.`),i(f)}async function ai(){try{await Promise.race([S(),re(1e3,void 0,{ref:!1})])}catch{}}const oi=/^Unknown commands?: /,si=/^Did you mean (.+)\?$/,ci=`You need to specify a command`;function li(e){return e instanceof Error&&e.message.startsWith(`Unknown command:`)}function ui(e,t){let n=si.exec(t)?.[1],r;if(n!==void 0)r=`suggested-command`;else if(oi.test(t))r=`unknown-subcommand`;else if(t===ci)r=`missing-command`;else return;try{let t=e,i=t.getInternalMethods(),a=i.getContext().commands,o=i.getCommandInstance().getCommands(),s=t.parsed?t.parsed.argv?._:void 0;if(!Array.isArray(a)||!a.every(e=>typeof e==`string`)||!Array.isArray(o))return;let c=a.length>0&&o.length===0;return{kind:r===`unknown-subcommand`&&c?`surplus-positional`:r,knownCommand:a,knownCommandIsLeaf:c,unknownTokens:Array.isArray(s)?s.slice(a.length).map(String):[],...n===void 0?{}:{suggestedCommand:n}}}catch{return}}function di(e){try{let t=e.getInternalMethods().getContext().commands;return!Array.isArray(t)||t.length===0||!t.every(e=>typeof e==`string`)?void 0:t.join(` `)}catch{return}}function fi(e){let t=e,n=t.parsed;if(!n||n.argv.help!==!0)return[];let{commands:r,fullCommands:i}=t.getInternalMethods().getContext();if(!Array.isArray(r)||!Array.isArray(i))return[];let a=i.at(-1),o=typeof a==`string`?a.match(/(?:<[^>]+>|\[[^\]]+\])/g)??[]:[];return o.some(e=>e.slice(1,-1).endsWith(`..`))?[]:n.argv._.slice(r.length+o.length).map(String)}var pi=class extends Error{helpCommand;constructor(e,t){super(e),this.helpCommand=t}};function mi(e){return`cf${e?` ${e}`:``} --help`}function hi(e){let[t,n]=e.split(` `);return t===`complete`||t===`cli`&&n===`telemetry`}function gi(e){let[t,...n]=e.unknownTokens,r=e.suggestedCommand??t;return[...e.knownCommand,...r===void 0?[]:[r],...n].join(` `).toLowerCase()}async function _i(e,t,n){if(ne()||e instanceof l)return;let r=li(e)||n?.knownCommand.length===0,i=r?void 0:t;if(!(i===void 0&&!r||hi(i??ri().join(` `))||n!==void 0&&hi(gi(n))))try{let{getTelemetryDispatcher:t,UNKNOWN_COMMAND_EVENT:r}=await ti(),{sanitizeError:a}=await import(`./error-sanitization-D069tpKk.mjs`),o=t();if(!o.enabled)return;let s=n?await vi(n):{argsUsed:[],argsCombination:``},c={command:i??r,sanitizedArgs:{},...s};o.sendCommandEvent(`cf command started`,c),o.sendCommandEvent(`cf command finished`,{...c,outcome:`error`,durationMs:0,...a(e)})}catch{}}async function vi(e){let{loadCommandVocabulary:t,sanitizeCommandResolution:n}=await import(`./command-resolution-DAQ4PWUt.mjs`);return n(e,vt(process.argv),t(Object.keys(_)))}async function yi(e){if(e&&!hi(e))try{let{getTelemetryDispatcher:t}=await ti();t().sendAdhocEvent(`cf help shown`,{command:e})}catch{}}function bi(e){let t=process.argv.slice(2),n=t.indexOf(`--`),r=n===-1?t:t.slice(0,n);return!r.includes(`--version`)&&!r.includes(`-v`)?!1:(h(f,{quiet:c(r),update:e}),console.log(f),!0)}function xi(e){if(process.argv.slice(2).length>0)return!1;let t=[p(f,e),``,`The Cloudflare CLI — manage your account, zones, and developer platform.`,``,`${o.bold(`Get started:`)}`,` ${o.code(`cf auth login`)} ${o.muted(`Authenticate with Cloudflare`)}`,` ${o.code(`cf --help`)} ${o.muted(`Browse all commands`)}`,` ${o.code(`cf <command> --help`)} ${o.muted(`Per-command help`)}`,` ${o.code(`cf migrate`)} ${o.muted(`Migrate a Wrangler project to cf`)}`,` ${o.code(`cf complete bash`)} ${o.muted(`Install shell completions`)}`,``,`${o.bold(`Docs:`)} ${o.brand(`https://developers.cloudflare.com/`)}`,``];return console.log(t.join(`
|
|
131
|
+
`)),!0}function Si(e=!1,t){let n=process.argv.slice(2),r=n.indexOf(`--`),i=r===-1?n:n.slice(0,r);i.length!==0&&(i.includes(`--version`)||i.includes(`-v`)||ni(i)!==`complete`&&h(f,{quiet:e||c(i),update:t}))}async function Ci(){let e=process.argv.slice(2);if(c(e)||ni(e)===`complete`||(e.length===0?process.stdout.isTTY!==!0:process.stderr.isTTY!==!0))return;let{isCI:t}=await import(`./interactive-CHcvofEp.mjs`);if(t)return;let{getUpdateNotice:n,maybeStartBackgroundUpdateCheck:r}=await import(`./update-check-HltjTMDE.mjs`),i=!1;return{notice:n(f),start(){i||(i=!0,r())}}}function wi(e,t={}){let{onCommandResolved:n,onCommandResolutionFailed:r,onHelpShown:i,updateCheck:a}=t,s,c=e=>o.brand(e),l=e.indexOf(`--`),p=(l===-1?e:e.slice(0,l)).some(e=>e===`--local`||e===`--no-local`||e.startsWith(`--local=`)),h=Fr(e).scriptName(`cf`).parserConfiguration({"sort-commands":!0}).wrap(process.stdout.columns||80).usage(`$0 <command> [options]`).usage(`
|
|
132
|
+
The Cloudflare CLI - manage your Cloudflare resources`).updateStrings({"Commands:":c(`Commands`),"Options:":c(`Options`),"Positionals:":c(`Positionals`),"Examples:":c(`Examples`)}).help(`help`,y.help.description).alias(y.help.alias,`help`).options(_).group([...Object.keys(_),...Object.keys(y)],c(`Global flags`));for(let e of Yr)h.command(e);for(let e of Ir)e.hideCommand?h.command({...e.command,describe:!1}):h.command(e.command);h.middleware(async e=>{Si(e.quiet,a?.notice),a?.start();let t=di(h);t!==void 0&&n?.(t);try{await ii(e.quiet)}catch{}try{await $r(e.quiet)}catch{}te(e.mode);let r=String(e._[0]??``),i=e.persistTo??e[`persist-to`];if(!e.help&&(r===`dev`&&p||e.local&&Xr.has(r)))throw Error(`--local is not supported by cf ${r}.`);if(!e.help&&r===`dev`&&i!==void 0)throw Error(`--persist-to is not supported by cf dev.`);if(i===``)throw Error(`--persist-to requires a non-empty directory.`);if(i!==void 0&&!e.local)throw Error(`--persist-to can only be used with --local.`);if(e[`temporary-account`]&&e.local)throw Error(`--temporary-account cannot be used with --local.`);let o=e[`event-code`];if(o!==void 0&&!e[`temporary-account`])throw Error(`--event-code requires --temporary-account.`);if(t!==void 0&&u(t,e.local)&&(s=await d(e)),!e.local){let{resolveProfile:t,setTemporaryAccountRequested:n}=await import(`./oauth-Cidoyxfp.mjs`);n(e[`temporary-account`],o===void 0?void 0:{eventCode:o});let r=t(e.profile);m(r)}}).demandCommand(1,`You need to specify a command`).strictCommands().strictOptions().recommendCommands().version(`version`,y.version.description,f).alias(y.version.alias,`version`).epilogue(`For more information, visit https://developers.cloudflare.com/`).exitProcess(!1).fail((e,t,o)=>{Si(!1,a?.notice),a?.start();let s=di(h);if(s!==void 0&&n?.(s),t)throw t;if(e===`You need to specify a command`&&h.parsed&&Object.keys(h.parsed.argv).some(e=>e!==`_`&&e!==`$0`&&!Kr.has(e.replace(/[A-Z]/g,e=>`-${e.toLowerCase()}`))))return;let c=si.exec(e)?.[1];if(c&&!o.getCommands().some(([e])=>e.split(` `)[0]===c))return;if(e===`Please specify a subcommand`){s!==void 0&&i?.(s),o.showHelp(`log`);return}let l=new pi(e,mi(s)),u=ui(h,e)??(s===void 0&&/^Unknown arguments?:/.test(e)?ui(h,ci):void 0);throw u&&r?.(u,l),l});let g=h.showHelp.bind(h);h.showHelp=e=>{let t=typeof e==`function`?fi(h):[];if(t.length>0){let e=new pi(`Unknown command: ${t[0]}`,mi(di(h))),n=ui(h,e.message);throw n&&r?.({...n,unknownTokens:t},e),e}return g(t=>{let r=di(h);r!==void 0&&n?.(r),i?.(r??`cf`);let a=Qr(t,r);typeof e==`function`?e(a):e===`log`?console.log(a):console.error(a)})};let v=h.getHelp.bind(h);return h.getHelp=async()=>Qr(await v(),di(h)),{cli:h,dispose:()=>{s?.(),s=void 0}}}async function Ti(e){let t=process.argv;process.argv=[`node`,`cf`,...e];try{await Ei()}finally{process.argv=t}}async function Ei(){te(void 0),x();let e=await Ci();if(bi(e?.notice)||xi(e?.notice))throw e?.start(),new l(0);let t,n,r,{cli:i,dispose:a}=wi(vt(process.argv),{onCommandResolved:e=>{t=e},onCommandResolutionFailed:(e,t)=>{n={failure:e,error:t}},onHelpShown:e=>{r=e},updateCheck:e}),s=vt(process.argv),c=s.indexOf(`--`),u=c===-1?s:s.slice(0,c);if(u.includes(`--help`)||u.includes(`-h`)){Si(!1,e?.notice),e?.start();try{await $r()}catch{}}try{await i.parse(vt(process.argv)),await yi(r)}catch(e){if(e instanceof l)throw e;if(t===void 0){try{await ii()}catch{}try{await $r()}catch{}}let r=n!==void 0&&n.error===e?n.failure:void 0;await _i(e,t??di(i),r);let a=g(e);throw e instanceof pi&&(e.helpCommand===`cf --help`&&/^Unknown arguments?:/.test(e.message)&&console.error(`\nGlobal flags:\n${qr}`),console.error(`
|
|
133
|
+
`+o.italic(`For more information, run ${o.code(e.helpCommand)}`))),a}finally{a(),await ee(),await ai()}}export{Ei as n,Ti as r,wi as t};
|