@vercel/cli-support 0.0.0 → 65.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +202 -0
- package/README.md +100 -3
- package/dist/chunks/add-5YZQTIQM.js +8 -0
- package/dist/chunks/add-A524QQ2H.js +8 -0
- package/dist/chunks/add-V4JMUHKO.js +8 -0
- package/dist/chunks/build-K2PVDJZ4.js +7 -0
- package/dist/chunks/chunk-22FDWPWY.js +7 -0
- package/dist/chunks/chunk-25565AGS.js +7 -0
- package/dist/chunks/chunk-2ACMWVTB.js +12 -0
- package/dist/chunks/chunk-2EYYB6YN.js +7 -0
- package/dist/chunks/chunk-2GHZGOWT.js +7 -0
- package/dist/chunks/chunk-2H3SB5RP.js +9 -0
- package/dist/chunks/chunk-2NABMKFV.js +29 -0
- package/dist/chunks/chunk-2PKEEQ5W.js +25 -0
- package/dist/chunks/chunk-2S6PE6GB.js +7 -0
- package/dist/chunks/chunk-2U7DJZSQ.js +21 -0
- package/dist/chunks/chunk-2WYYGGEO.js +7 -0
- package/dist/chunks/chunk-3ADDGPEN.js +7 -0
- package/dist/chunks/chunk-3AYYFYZG.js +7 -0
- package/dist/chunks/chunk-3G3FQYMW.js +7 -0
- package/dist/chunks/chunk-3JGBBS6V.js +7 -0
- package/dist/chunks/chunk-3KKFLKQG.js +7 -0
- package/dist/chunks/chunk-3LIKVGFT.js +8 -0
- package/dist/chunks/chunk-3XW7N4W3.js +9 -0
- package/dist/chunks/chunk-43GBAKL2.js +86 -0
- package/dist/chunks/chunk-4CACOKMS.js +7 -0
- package/dist/chunks/chunk-4NTBYNFR.js +17 -0
- package/dist/chunks/chunk-4SAVH3H7.js +7 -0
- package/dist/chunks/chunk-4UGHFESV.js +8 -0
- package/dist/chunks/chunk-4VFYJU37.js +7 -0
- package/dist/chunks/chunk-5IASAERQ.js +7 -0
- package/dist/chunks/chunk-5RMIM4S2.js +7 -0
- package/dist/chunks/chunk-67GZ5REA.js +7 -0
- package/dist/chunks/chunk-6IDNVZZR.js +7 -0
- package/dist/chunks/chunk-6ISAISGD.js +16 -0
- package/dist/chunks/chunk-6KVHNQW4.js +17 -0
- package/dist/chunks/chunk-6OVX3PWM.js +7 -0
- package/dist/chunks/chunk-6QKS6QK7.js +7 -0
- package/dist/chunks/chunk-6VH56CX2.js +19 -0
- package/dist/chunks/chunk-6Y2ZL5XJ.js +98 -0
- package/dist/chunks/chunk-76KGQU2G.js +7 -0
- package/dist/chunks/chunk-76SVVWPH.js +7 -0
- package/dist/chunks/chunk-773GOZIR.js +13 -0
- package/dist/chunks/chunk-7BGKE3JW.js +10 -0
- package/dist/chunks/chunk-7EJQLVWX.js +7 -0
- package/dist/chunks/chunk-7HV7O6DM.js +7 -0
- package/dist/chunks/chunk-7L2K4OKM.js +63 -0
- package/dist/chunks/chunk-7Y46LB43.js +14 -0
- package/dist/chunks/chunk-7YKFF6CE.js +7 -0
- package/dist/chunks/chunk-7Z3WUAO5.js +10 -0
- package/dist/chunks/chunk-A2RZZQEP.js +7 -0
- package/dist/chunks/chunk-ABZEMNDR.js +7 -0
- package/dist/chunks/chunk-ADLBLGT3.js +8 -0
- package/dist/chunks/chunk-AM46JVVN.js +7 -0
- package/dist/chunks/chunk-ANMDN3EG.js +9 -0
- package/dist/chunks/chunk-APZULWJC.js +8 -0
- package/dist/chunks/chunk-AWMQGOS2.js +7 -0
- package/dist/chunks/chunk-B4UE4LVE.js +7 -0
- package/dist/chunks/chunk-B4YYOSPY.js +7 -0
- package/dist/chunks/chunk-BBKEP7RO.js +7 -0
- package/dist/chunks/chunk-BL3HBRF6.js +12 -0
- package/dist/chunks/chunk-BLUPZPAS.js +7 -0
- package/dist/chunks/chunk-BPUANOGW.js +7 -0
- package/dist/chunks/chunk-BRQUZ5NC.js +7 -0
- package/dist/chunks/chunk-BS32OUOC.js +7 -0
- package/dist/chunks/chunk-BTI5TG6Q.js +7 -0
- package/dist/chunks/chunk-BUJITHGZ.js +8 -0
- package/dist/chunks/chunk-BVH2AEFE.js +7 -0
- package/dist/chunks/chunk-BZENIQ7N.js +7 -0
- package/dist/chunks/chunk-C6GY2G73.js +7 -0
- package/dist/chunks/chunk-CEMPU323.js +7 -0
- package/dist/chunks/chunk-COD3WAUI.js +7 -0
- package/dist/chunks/chunk-COM5YCHF.js +9 -0
- package/dist/chunks/chunk-CZSOZKHX.js +7 -0
- package/dist/chunks/chunk-D2BZMGHP.js +7 -0
- package/dist/chunks/chunk-D3AHZ5LI.js +7 -0
- package/dist/chunks/chunk-D6REP5QQ.js +15 -0
- package/dist/chunks/chunk-DFVNL5ML.js +7 -0
- package/dist/chunks/chunk-DGYHWXD2.js +10 -0
- package/dist/chunks/chunk-DUT4U5YY.js +7 -0
- package/dist/chunks/chunk-DWZBL4NK.js +7 -0
- package/dist/chunks/chunk-E2SADN6I.js +7 -0
- package/dist/chunks/chunk-E6CO6TUM.js +7 -0
- package/dist/chunks/chunk-EAUDC24V.js +9 -0
- package/dist/chunks/chunk-ECQIO5K3.js +7 -0
- package/dist/chunks/chunk-ETV3C2CV.js +7 -0
- package/dist/chunks/chunk-F2SWJEYV.js +8 -0
- package/dist/chunks/chunk-F4KY2TOK.js +7 -0
- package/dist/chunks/chunk-F53OKXYI.js +7 -0
- package/dist/chunks/chunk-F7AVGV4Y.js +7 -0
- package/dist/chunks/chunk-FBYA6LLM.js +7 -0
- package/dist/chunks/chunk-FDNYYENK.js +11 -0
- package/dist/chunks/chunk-FGFLTLEA.js +7 -0
- package/dist/chunks/chunk-FUX6LKNP.js +7 -0
- package/dist/chunks/chunk-G4T7VBGN.js +9 -0
- package/dist/chunks/chunk-GA277JFB.js +20 -0
- package/dist/chunks/chunk-GD7AV7BO.js +9 -0
- package/dist/chunks/chunk-GG5RME4X.js +7 -0
- package/dist/chunks/chunk-GHAY4PSD.js +7 -0
- package/dist/chunks/chunk-GVTXA6HG.js +7 -0
- package/dist/chunks/chunk-GYVJIIYL.js +7 -0
- package/dist/chunks/chunk-GZNDA6SV.js +8 -0
- package/dist/chunks/chunk-HCRD3JFL.js +7 -0
- package/dist/chunks/chunk-HEGJZJO7.js +7 -0
- package/dist/chunks/chunk-HRR57QNP.js +7 -0
- package/dist/chunks/chunk-IA3MXJRC.js +8 -0
- package/dist/chunks/chunk-ID663OJ7.js +7 -0
- package/dist/chunks/chunk-IEPW2YRH.js +7 -0
- package/dist/chunks/chunk-IGDG5CWT.js +7 -0
- package/dist/chunks/chunk-IKQTP764.js +7 -0
- package/dist/chunks/chunk-IQ7FPAI4.js +7 -0
- package/dist/chunks/chunk-IQKGQ2Y2.js +15 -0
- package/dist/chunks/chunk-ISWW3DKF.js +7 -0
- package/dist/chunks/chunk-IUXSJWL3.js +7 -0
- package/dist/chunks/chunk-IVSC7ZFJ.js +7 -0
- package/dist/chunks/chunk-IVSSTHB6.js +7 -0
- package/dist/chunks/chunk-J24BABG4.js +21 -0
- package/dist/chunks/chunk-JALVF3C2.js +7 -0
- package/dist/chunks/chunk-JELLVPCM.js +8 -0
- package/dist/chunks/chunk-JESNVRVR.js +7 -0
- package/dist/chunks/chunk-JLEJB6KM.js +7 -0
- package/dist/chunks/chunk-KH6565YH.js +8 -0
- package/dist/chunks/chunk-KNLGWGUE.js +57 -0
- package/dist/chunks/chunk-KRPY5FHJ.js +7 -0
- package/dist/chunks/chunk-KW6GSQXV.js +7 -0
- package/dist/chunks/chunk-L4NSF346.js +22 -0
- package/dist/chunks/chunk-LCHECISY.js +7 -0
- package/dist/chunks/chunk-LJBUJ23M.js +7 -0
- package/dist/chunks/chunk-LKLH6DZP.js +9 -0
- package/dist/chunks/chunk-LRYGNQ6C.js +8 -0
- package/dist/chunks/chunk-LSF7FY6X.js +7 -0
- package/dist/chunks/chunk-LSQREJXO.js +11 -0
- package/dist/chunks/chunk-LT3UK4K6.js +10 -0
- package/dist/chunks/chunk-LUBUI5GF.js +7 -0
- package/dist/chunks/chunk-MCRKBVZA.js +7 -0
- package/dist/chunks/chunk-MVGTMPMI.js +23 -0
- package/dist/chunks/chunk-MXTC4ZAQ.js +7 -0
- package/dist/chunks/chunk-NB2WLB3J.js +12 -0
- package/dist/chunks/chunk-NEFDNROD.js +7 -0
- package/dist/chunks/chunk-NQWGRKF4.js +7 -0
- package/dist/chunks/chunk-NTZ5WWYV.js +7 -0
- package/dist/chunks/chunk-NWGBDBZI.js +7 -0
- package/dist/chunks/chunk-NZ2TFADV.js +7 -0
- package/dist/chunks/chunk-OAM5NJCU.js +9 -0
- package/dist/chunks/chunk-OCQPXOTX.js +11 -0
- package/dist/chunks/chunk-OCR5CRTH.js +10 -0
- package/dist/chunks/chunk-OFDTADPQ.js +7 -0
- package/dist/chunks/chunk-OGPENBY2.js +7 -0
- package/dist/chunks/chunk-OKEBIUKZ.js +7 -0
- package/dist/chunks/chunk-OMCGXRSA.js +21 -0
- package/dist/chunks/chunk-OO572JUC.js +7 -0
- package/dist/chunks/chunk-OPORM35X.js +7 -0
- package/dist/chunks/chunk-OQCMRU3J.js +10 -0
- package/dist/chunks/chunk-OQPXJCMK.js +32 -0
- package/dist/chunks/chunk-OWOWPOIE.js +23 -0
- package/dist/chunks/chunk-PADL3C6Z.js +7 -0
- package/dist/chunks/chunk-PFD7LETF.js +7 -0
- package/dist/chunks/chunk-PFNYWWLI.js +7 -0
- package/dist/chunks/chunk-PFPJLIFF.js +33 -0
- package/dist/chunks/chunk-PSOVLGHP.js +7 -0
- package/dist/chunks/chunk-PUKYAALC.js +7 -0
- package/dist/chunks/chunk-PVASGBEF.js +7 -0
- package/dist/chunks/chunk-Q5ODLDCU.js +7 -0
- package/dist/chunks/chunk-Q7D7RGXM.js +7 -0
- package/dist/chunks/chunk-QB7F3UAP.js +7 -0
- package/dist/chunks/chunk-QHJLRTVY.js +7 -0
- package/dist/chunks/chunk-QMCHGGDX.js +10 -0
- package/dist/chunks/chunk-QZX7VG2V.js +9 -0
- package/dist/chunks/chunk-R6BEOVTU.js +7 -0
- package/dist/chunks/chunk-RLKS5G6C.js +12 -0
- package/dist/chunks/chunk-RM3ZDRYE.js +7 -0
- package/dist/chunks/chunk-RRDNKB2X.js +7 -0
- package/dist/chunks/chunk-RRREFECI.js +7 -0
- package/dist/chunks/chunk-RUXO73ON.js +7 -0
- package/dist/chunks/chunk-RW3X523R.js +8 -0
- package/dist/chunks/chunk-S3L2OHPO.js +7 -0
- package/dist/chunks/chunk-S4SJ7GIZ.js +7 -0
- package/dist/chunks/chunk-S5IWVPYT.js +32 -0
- package/dist/chunks/chunk-SACGQMVQ.js +13 -0
- package/dist/chunks/chunk-SCV7XEEO.js +7 -0
- package/dist/chunks/chunk-SF4E3AQ3.js +7 -0
- package/dist/chunks/chunk-SKYDLHEZ.js +7 -0
- package/dist/chunks/chunk-SLI2O5X7.js +63 -0
- package/dist/chunks/chunk-SXOSF4O6.js +39 -0
- package/dist/chunks/chunk-TAAWMNNL.js +7 -0
- package/dist/chunks/chunk-TG2RCYTH.js +7 -0
- package/dist/chunks/chunk-TKBORMUF.js +7 -0
- package/dist/chunks/chunk-TO5PJDEN.js +7 -0
- package/dist/chunks/chunk-TPNOSQZ3.js +15 -0
- package/dist/chunks/chunk-TZFDVQ72.js +27 -0
- package/dist/chunks/chunk-U4Z2MMOF.js +301 -0
- package/dist/chunks/chunk-U56NHYAH.js +7 -0
- package/dist/chunks/chunk-UJSW56GS.js +9 -0
- package/dist/chunks/chunk-UKQMYTWW.js +9 -0
- package/dist/chunks/chunk-ULHNMQ7C.js +7 -0
- package/dist/chunks/chunk-UNEGQPD3.js +7 -0
- package/dist/chunks/chunk-URPEIX6M.js +7 -0
- package/dist/chunks/chunk-UVHKXCR5.js +11 -0
- package/dist/chunks/chunk-V6Y6UK6B.js +43 -0
- package/dist/chunks/chunk-V7BEC3E4.js +10 -0
- package/dist/chunks/chunk-VMMMBWD3.js +7 -0
- package/dist/chunks/chunk-VOCZ34ON.js +7 -0
- package/dist/chunks/chunk-VQSLPYAF.js +7 -0
- package/dist/chunks/chunk-VT6RIZJH.js +7 -0
- package/dist/chunks/chunk-WBF36MYT.js +16 -0
- package/dist/chunks/chunk-WCWP4GBR.js +7 -0
- package/dist/chunks/chunk-WGXKX24Q.js +7 -0
- package/dist/chunks/chunk-X4762EE4.js +7 -0
- package/dist/chunks/chunk-XB4SKARZ.js +29 -0
- package/dist/chunks/chunk-XGTKHQTT.js +7 -0
- package/dist/chunks/chunk-XOETL6DB.js +96 -0
- package/dist/chunks/chunk-XP3FT56R.js +27 -0
- package/dist/chunks/chunk-XR6QY7RR.js +7 -0
- package/dist/chunks/chunk-XXXRTHTP.js +8 -0
- package/dist/chunks/chunk-XZV4BFM5.js +7 -0
- package/dist/chunks/chunk-Y6AGOERS.js +8 -0
- package/dist/chunks/chunk-YHPPP3SF.js +7 -0
- package/dist/chunks/chunk-YHQ7PPXP.js +7 -0
- package/dist/chunks/chunk-YK7XLFU2.js +24 -0
- package/dist/chunks/chunk-YN3C5BL5.js +7 -0
- package/dist/chunks/chunk-ZF27J6FQ.js +7 -0
- package/dist/chunks/chunk-ZFRNVIHI.js +7 -0
- package/dist/chunks/chunk-ZH6KHD55.js +20 -0
- package/dist/chunks/cjs-2SMN43VH.js +54 -0
- package/dist/chunks/clear-ZS4KQ7OT.js +8 -0
- package/dist/chunks/compile-vercel-config-3IYM2CHC.js +7 -0
- package/dist/chunks/config-N2SBVW4T.js +8 -0
- package/dist/chunks/config-ZFIC7N4D.js +7 -0
- package/dist/chunks/config-validator.mjs +1 -0
- package/dist/chunks/connect-git-provider-FS5Q2HO4.js +7 -0
- package/dist/chunks/constants-ICJL2EO5.js +7 -0
- package/dist/chunks/create-project-IKCB6MB2.js +7 -0
- package/dist/chunks/delete-2ZE2NVHI.js +10 -0
- package/dist/chunks/delete-AL57HZDQ.js +9 -0
- package/dist/chunks/detect-projects-OD4JEAW2.js +7 -0
- package/dist/chunks/detect-services-MOXTX5XG.js +7 -0
- package/dist/chunks/disable-MKI3BKNH.js +7 -0
- package/dist/chunks/discard-SI4H7ST3.js +14 -0
- package/dist/chunks/dist-33WTJLVQ.js +7 -0
- package/dist/chunks/dist-RXYNZPEA.js +7 -0
- package/dist/chunks/edit-DNWH6SPE.js +8 -0
- package/dist/chunks/edit-WYNWDFUJ.js +9 -0
- package/dist/chunks/enable-J6MMYPYF.js +7 -0
- package/dist/chunks/esm-33752ISR.js +7 -0
- package/dist/chunks/esm-4JKEE7PC.js +7 -0
- package/dist/chunks/esm-BYG5BWYH.js +9 -0
- package/dist/chunks/esm-DFFBNKNU.js +20 -0
- package/dist/chunks/esm-IF453UWS.js +7 -0
- package/dist/chunks/esm-LABWDJ72.js +7 -0
- package/dist/chunks/esm-TG37FXTU.js +9 -0
- package/dist/chunks/exec-OZSY46V6.js +16372 -0
- package/dist/chunks/export-MHSH7QCX.js +19 -0
- package/dist/chunks/fetch-proxy-45DGILKR.js +67 -0
- package/dist/chunks/future-FFOGTKMF.js +7 -0
- package/dist/chunks/generate-cert-for-deploy-YZKNGAEQ.js +7 -0
- package/dist/chunks/image-7METSS6F.js +7 -0
- package/dist/chunks/import-builders-GM2SERWV.js +7 -0
- package/dist/chunks/inspect-A7WJQQZO.js +15 -0
- package/dist/chunks/inspect-DI434TAM.js +19 -0
- package/dist/chunks/inspect-H2Q7XOWN.js +13 -0
- package/dist/chunks/inspect-H5JC2XKI.js +9 -0
- package/dist/chunks/inspect-IAWVHJXQ.js +20 -0
- package/dist/chunks/list-ELEUTZWJ.js +12 -0
- package/dist/chunks/list-INRPH25K.js +10 -0
- package/dist/chunks/list-WWU734RK.js +16 -0
- package/dist/chunks/login-R5NQRPQC.js +7 -0
- package/dist/chunks/login-ZF2TLCQB.js +9 -0
- package/dist/chunks/logs-UD7FEXZ7.js +7 -0
- package/dist/chunks/ls-5ZEAKKPQ.js +8 -0
- package/dist/chunks/ls-IXRLAJ4L.js +11 -0
- package/dist/chunks/ls-LIGIBVAT.js +12 -0
- package/dist/chunks/ls-MCQ2NS65.js +8 -0
- package/dist/chunks/ls-S5E2NQMI.js +12 -0
- package/dist/chunks/ls-V2ZSIVO3.js +12 -0
- package/dist/chunks/ls-VXH4QYF5.js +12 -0
- package/dist/chunks/mutate-OQWOKLIW.js +9 -0
- package/dist/chunks/notifications-KFZ333V5.js +7 -0
- package/dist/chunks/open-HH6K7ZRC.js +7 -0
- package/dist/chunks/openapi-JGYEFJJV.js +7 -0
- package/dist/chunks/permissions-ZSHKMXBZ.js +7 -0
- package/dist/chunks/pkg-EDJQLCNP.js +7 -0
- package/dist/chunks/plugin-offer-Z6FCPQFD.js +9 -0
- package/dist/chunks/prompt-missing-credentials-KOA7C4QC.js +7 -0
- package/dist/chunks/publish-FPNQ2US4.js +15 -0
- package/dist/chunks/pull-7OGOIKB3.js +7 -0
- package/dist/chunks/purchase-domain-if-available-F4LKHVBD.js +7 -0
- package/dist/chunks/push-NY3SIK2C.js +7 -0
- package/dist/chunks/query-JGPO7TNY.js +12 -0
- package/dist/chunks/reauthenticate-OZRQFR66.js +7 -0
- package/dist/chunks/reorder-4J2STFUS.js +10 -0
- package/dist/chunks/reply-EO4NTTPW.js +9 -0
- package/dist/chunks/repo-info-to-url-XQSULSEO.js +7 -0
- package/dist/chunks/resolve-RPHHRPNM.js +12 -0
- package/dist/chunks/resolve-agent-team-KX77HEAF.js +7 -0
- package/dist/chunks/resolve-deployment-framework-preset-AXXYBFCL.js +7 -0
- package/dist/chunks/restore-TEA6TSVK.js +16 -0
- package/dist/chunks/rm-BPILSPUI.js +8 -0
- package/dist/chunks/rm-F6XVUDBM.js +8 -0
- package/dist/chunks/rm-JCPXV2FN.js +8 -0
- package/dist/chunks/rm-LPQRGX7N.js +8 -0
- package/dist/chunks/rm-WHUGT6TE.js +8 -0
- package/dist/chunks/routes-P6LKQCWH.js +7 -0
- package/dist/chunks/rule-inspect-BOETGPFO.js +8 -0
- package/dist/chunks/schema-BEUO7G52.js +44 -0
- package/dist/chunks/schema-YOEAK4VX.js +14 -0
- package/dist/chunks/select-org-OMLGQEKK.js +7 -0
- package/dist/chunks/set-5XY27S7R.js +7 -0
- package/dist/chunks/setup-and-link-A7M3QT52.js +7 -0
- package/dist/chunks/skills-4J2NC2QI.js +590 -0
- package/dist/chunks/slugify-NMMUASYK.js +7 -0
- package/dist/chunks/stamp-TKONNIJ5.js +7 -0
- package/dist/chunks/tags-ZXZQEXOV.js +7 -0
- package/dist/chunks/token-W6P2KNI5.js +7 -0
- package/dist/chunks/token-util-JDQI37VN.js +7 -0
- package/dist/chunks/types-SK6J2HFE.js +14 -0
- package/dist/chunks/update-25CKNOY5.js +8 -0
- package/dist/chunks/update-route-version-KWK5S4UW.js +7 -0
- package/dist/chunks/utils-IQZEE4DT.js +86 -0
- package/dist/chunks/vlt-builder-graph-XL2XRO4V.js +7 -0
- package/dist/chunks/vlt-builder-importer-RBUPAB6J.js +11 -0
- package/dist/chunks/zod-2C2SXNIK.js +7 -0
- package/dist/commands/build/builder-worker.cjs +281 -0
- package/dist/commands/build/index.js +34 -0
- package/dist/commands/deploy/index.js +72 -0
- package/dist/commands/dev/builder-worker.cjs +110 -0
- package/dist/commands/dev/index.js +157 -0
- package/dist/commands/env/index.js +40 -0
- package/dist/commands/link/index.js +10 -0
- package/dist/commands/list/index.js +14 -0
- package/dist/commands/project/index.js +113 -0
- package/dist/commands-account.js +209 -0
- package/dist/commands-ai.js +200 -0
- package/dist/commands-blob.js +107 -0
- package/dist/commands-core.js +222 -0
- package/dist/commands-deployments.js +84 -0
- package/dist/commands-flags.js +377 -0
- package/dist/commands-integrations.js +143 -0
- package/dist/commands-observability.js +122 -0
- package/dist/commands-routing.js +273 -0
- package/dist/fetch-dist-tags.cjs +60 -0
- package/dist/get-latest-worker.cjs +222 -0
- package/dist/help.js +7 -0
- package/dist/index.js +25 -0
- package/dist/internal-build-worker.js +10 -0
- package/dist/internal-build.js +11 -0
- package/dist/package.json +265 -0
- package/dist/root-help-commands.mjs +1 -0
- package/dist/runtime-assets/dev-tunnel/api/tunnel.ts +443 -0
- package/dist/runtime-assets/dev-tunnel/lib/env.ts +25 -0
- package/dist/runtime-assets/dev-tunnel/lib/tunnel_pb.ts +505 -0
- package/dist/runtime-assets/node-preloads/next-dev-websocket.cjs +220 -0
- package/dist/vc.js +393 -0
- package/dist/version.mjs +2 -0
- package/package.json +224 -14
- package/index.js +0 -1
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from 'node:module';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __dirname_ } from 'node:path';
|
|
4
|
+
const require = __createRequire(import.meta.url);
|
|
5
|
+
const __filename = __fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = __dirname_(__filename);
|
|
7
|
+
import{__commonJS}from"./chunk-BZENIQ7N.js";var require_escape_string_regexp=__commonJS({"../../node_modules/.pnpm/escape-string-regexp@2.0.0/node_modules/escape-string-regexp/index.js"(exports,module){"use strict";var matchOperatorsRegex=/[|\\{}()[\]^$+*?.-]/g;module.exports=string=>{if(typeof string!="string")throw new TypeError("Expected a string");return string.replace(matchOperatorsRegex,"\\$&")}}});var require_lodash=__commonJS({"../../node_modules/.pnpm/lodash.deburr@4.1.0/node_modules/lodash.deburr/index.js"(exports,module){var INFINITY=1/0,symbolTag="[object Symbol]",reLatin=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,rsComboMarksRange="\\u0300-\\u036f\\ufe20-\\ufe23",rsComboSymbolsRange="\\u20d0-\\u20f0",rsCombo="["+rsComboMarksRange+rsComboSymbolsRange+"]",reComboMark=RegExp(rsCombo,"g"),deburredLetters={\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"ss"},freeGlobal=typeof global=="object"&&global&&global.Object===Object&&global,freeSelf=typeof self=="object"&&self&&self.Object===Object&&self,root=freeGlobal||freeSelf||Function("return this")();function basePropertyOf(object){return function(key){return object?.[key]}}var deburrLetter=basePropertyOf(deburredLetters),objectProto=Object.prototype,objectToString=objectProto.toString,Symbol=root.Symbol,symbolProto=Symbol?Symbol.prototype:void 0,symbolToString=symbolProto?symbolProto.toString:void 0;function baseToString(value){if(typeof value=="string")return value;if(isSymbol(value))return symbolToString?symbolToString.call(value):"";var result=value+"";return result=="0"&&1/value==-INFINITY?"-0":result}function isObjectLike(value){return!!value&&typeof value=="object"}function isSymbol(value){return typeof value=="symbol"||isObjectLike(value)&&objectToString.call(value)==symbolTag}function toString(value){return value==null?"":baseToString(value)}function deburr(string){return string=toString(string),string&&string.replace(reLatin,deburrLetter).replace(reComboMark,"")}module.exports=deburr}});var require_replacements=__commonJS({"../../node_modules/.pnpm/@sindresorhus+transliterate@0.1.2/node_modules/@sindresorhus/transliterate/replacements.js"(exports,module){"use strict";module.exports=[["\xDF","ss"],["\xE4","ae"],["\xC4","Ae"],["\xF6","oe"],["\xD6","Oe"],["\xFC","ue"],["\xDC","Ue"],["\xC0","A"],["\xC1","A"],["\xC2","A"],["\xC3","A"],["\xC4","Ae"],["\xC5","A"],["\xC6","AE"],["\xC7","C"],["\xC8","E"],["\xC9","E"],["\xCA","E"],["\xCB","E"],["\xCC","I"],["\xCD","I"],["\xCE","I"],["\xCF","I"],["\xD0","D"],["\xD1","N"],["\xD2","O"],["\xD3","O"],["\xD4","O"],["\xD5","O"],["\xD6","Oe"],["\u0150","O"],["\xD8","O"],["\xD9","U"],["\xDA","U"],["\xDB","U"],["\xDC","Ue"],["\u0170","U"],["\xDD","Y"],["\xDE","TH"],["\xDF","ss"],["\xE0","a"],["\xE1","a"],["\xE2","a"],["\xE3","a"],["\xE4","ae"],["\xE5","a"],["\xE6","ae"],["\xE7","c"],["\xE8","e"],["\xE9","e"],["\xEA","e"],["\xEB","e"],["\xEC","i"],["\xED","i"],["\xEE","i"],["\xEF","i"],["\xF0","d"],["\xF1","n"],["\xF2","o"],["\xF3","o"],["\xF4","o"],["\xF5","o"],["\xF6","oe"],["\u0151","o"],["\xF8","o"],["\xF9","u"],["\xFA","u"],["\xFB","u"],["\xFC","ue"],["\u0171","u"],["\xFD","y"],["\xFE","th"],["\xFF","y"],["\u1E9E","SS"],["\xE0","a"],["\xC0","A"],["\xE1","a"],["\xC1","A"],["\xE2","a"],["\xC2","A"],["\xE3","a"],["\xC3","A"],["\xE8","e"],["\xC8","E"],["\xE9","e"],["\xC9","E"],["\xEA","e"],["\xCA","E"],["\xEC","i"],["\xCC","I"],["\xED","i"],["\xCD","I"],["\xF2","o"],["\xD2","O"],["\xF3","o"],["\xD3","O"],["\xF4","o"],["\xD4","O"],["\xF5","o"],["\xD5","O"],["\xF9","u"],["\xD9","U"],["\xFA","u"],["\xDA","U"],["\xFD","y"],["\xDD","Y"],["\u0103","a"],["\u0102","A"],["\u0110","D"],["\u0111","d"],["\u0129","i"],["\u0128","I"],["\u0169","u"],["\u0168","U"],["\u01A1","o"],["\u01A0","O"],["\u01B0","u"],["\u01AF","U"],["\u1EA1","a"],["\u1EA0","A"],["\u1EA3","a"],["\u1EA2","A"],["\u1EA5","a"],["\u1EA4","A"],["\u1EA7","a"],["\u1EA6","A"],["\u1EA9","a"],["\u1EA8","A"],["\u1EAB","a"],["\u1EAA","A"],["\u1EAD","a"],["\u1EAC","A"],["\u1EAF","a"],["\u1EAE","A"],["\u1EB1","a"],["\u1EB0","A"],["\u1EB3","a"],["\u1EB2","A"],["\u1EB5","a"],["\u1EB4","A"],["\u1EB7","a"],["\u1EB6","A"],["\u1EB9","e"],["\u1EB8","E"],["\u1EBB","e"],["\u1EBA","E"],["\u1EBD","e"],["\u1EBC","E"],["\u1EBF","e"],["\u1EBE","E"],["\u1EC1","e"],["\u1EC0","E"],["\u1EC3","e"],["\u1EC2","E"],["\u1EC5","e"],["\u1EC4","E"],["\u1EC7","e"],["\u1EC6","E"],["\u1EC9","i"],["\u1EC8","I"],["\u1ECB","i"],["\u1ECA","I"],["\u1ECD","o"],["\u1ECC","O"],["\u1ECF","o"],["\u1ECE","O"],["\u1ED1","o"],["\u1ED0","O"],["\u1ED3","o"],["\u1ED2","O"],["\u1ED5","o"],["\u1ED4","O"],["\u1ED7","o"],["\u1ED6","O"],["\u1ED9","o"],["\u1ED8","O"],["\u1EDB","o"],["\u1EDA","O"],["\u1EDD","o"],["\u1EDC","O"],["\u1EDF","o"],["\u1EDE","O"],["\u1EE1","o"],["\u1EE0","O"],["\u1EE3","o"],["\u1EE2","O"],["\u1EE5","u"],["\u1EE4","U"],["\u1EE7","u"],["\u1EE6","U"],["\u1EE9","u"],["\u1EE8","U"],["\u1EEB","u"],["\u1EEA","U"],["\u1EED","u"],["\u1EEC","U"],["\u1EEF","u"],["\u1EEE","U"],["\u1EF1","u"],["\u1EF0","U"],["\u1EF3","y"],["\u1EF2","Y"],["\u1EF5","y"],["\u1EF4","Y"],["\u1EF7","y"],["\u1EF6","Y"],["\u1EF9","y"],["\u1EF8","Y"],["\u0621","e"],["\u0622","a"],["\u0623","a"],["\u0624","w"],["\u0625","i"],["\u0626","y"],["\u0627","a"],["\u0628","b"],["\u0629","t"],["\u062A","t"],["\u062B","th"],["\u062C","j"],["\u062D","h"],["\u062E","kh"],["\u062F","d"],["\u0630","dh"],["\u0631","r"],["\u0632","z"],["\u0633","s"],["\u0634","sh"],["\u0635","s"],["\u0636","d"],["\u0637","t"],["\u0638","z"],["\u0639","e"],["\u063A","gh"],["\u0640","_"],["\u0641","f"],["\u0642","q"],["\u0643","k"],["\u0644","l"],["\u0645","m"],["\u0646","n"],["\u0647","h"],["\u0648","w"],["\u0649","a"],["\u064A","y"],["\u064E\u200E","a"],["\u064F","u"],["\u0650\u200E","i"],["\u0660","0"],["\u0661","1"],["\u0662","2"],["\u0663","3"],["\u0664","4"],["\u0665","5"],["\u0666","6"],["\u0667","7"],["\u0668","8"],["\u0669","9"],["\u0686","ch"],["\u06A9","k"],["\u06AF","g"],["\u067E","p"],["\u0698","zh"],["\u06CC","y"],["\u06F0","0"],["\u06F1","1"],["\u06F2","2"],["\u06F3","3"],["\u06F4","4"],["\u06F5","5"],["\u06F6","6"],["\u06F7","7"],["\u06F8","8"],["\u06F9","9"],["\u067C","p"],["\u0681","z"],["\u0685","c"],["\u0689","d"],["\uFEAB","d"],["\uFEAD","r"],["\u0693","r"],["\uFEAF","z"],["\u0696","g"],["\u069A","x"],["\u06AB","g"],["\u06BC","n"],["\u06C0","e"],["\u06D0","e"],["\u06CD","ai"],["\u0679","t"],["\u0688","d"],["\u0691","r"],["\u06BA","n"],["\u06C1","h"],["\u06BE","h"],["\u06D2","e"],["\u0410","A"],["\u0430","a"],["\u0411","B"],["\u0431","b"],["\u0412","V"],["\u0432","v"],["\u0413","G"],["\u0433","g"],["\u0414","D"],["\u0434","d"],["\u0415","E"],["\u0435","e"],["\u0416","Zh"],["\u0436","zh"],["\u0417","Z"],["\u0437","z"],["\u0418","I"],["\u0438","i"],["\u0419","J"],["\u0439","j"],["\u041A","K"],["\u043A","k"],["\u041B","L"],["\u043B","l"],["\u041C","M"],["\u043C","m"],["\u041D","N"],["\u043D","n"],["\u041E","O"],["\u043E","o"],["\u041F","P"],["\u043F","p"],["\u0420","R"],["\u0440","r"],["\u0421","S"],["\u0441","s"],["\u0422","T"],["\u0442","t"],["\u0423","U"],["\u0443","u"],["\u0424","F"],["\u0444","f"],["\u0425","H"],["\u0445","h"],["\u0426","Cz"],["\u0446","cz"],["\u0427","Ch"],["\u0447","ch"],["\u0428","Sh"],["\u0448","sh"],["\u0429","Shh"],["\u0449","shh"],["\u042A",""],["\u044A",""],["\u042B","Y"],["\u044B","y"],["\u042C",""],["\u044C",""],["\u042D","E"],["\u044D","e"],["\u042E","Yu"],["\u044E","yu"],["\u042F","Ya"],["\u044F","ya"],["\u0401","Yo"],["\u0451","yo"],["\u0103","a"],["\u0102","A"],["\u0219","s"],["\u0218","S"],["\u021B","t"],["\u021A","T"],["\u0163","t"],["\u0162","T"],["\u015F","s"],["\u015E","S"],["\xE7","c"],["\xC7","C"],["\u011F","g"],["\u011E","G"],["\u0131","i"],["\u0130","I"],["\u0561","a"],["\u0531","A"],["\u0562","b"],["\u0532","B"],["\u0563","g"],["\u0533","G"],["\u0564","d"],["\u0534","D"],["\u0565","ye"],["\u0535","Ye"],["\u0566","z"],["\u0536","Z"],["\u0567","e"],["\u0537","E"],["\u0568","y"],["\u0538","Y"],["\u0569","t"],["\u0539","T"],["\u056A","zh"],["\u053A","Zh"],["\u056B","i"],["\u053B","I"],["\u056C","l"],["\u053C","L"],["\u056D","kh"],["\u053D","Kh"],["\u056E","ts"],["\u053E","Ts"],["\u056F","k"],["\u053F","K"],["\u0570","h"],["\u0540","H"],["\u0571","dz"],["\u0541","Dz"],["\u0572","gh"],["\u0542","Gh"],["\u0573","tch"],["\u0543","Tch"],["\u0574","m"],["\u0544","M"],["\u0575","y"],["\u0545","Y"],["\u0576","n"],["\u0546","N"],["\u0577","sh"],["\u0547","Sh"],["\u0578","vo"],["\u0548","Vo"],["\u0579","ch"],["\u0549","Ch"],["\u057A","p"],["\u054A","P"],["\u057B","j"],["\u054B","J"],["\u057C","r"],["\u054C","R"],["\u057D","s"],["\u054D","S"],["\u057E","v"],["\u054E","V"],["\u057F","t"],["\u054F","T"],["\u0580","r"],["\u0550","R"],["\u0581","c"],["\u0551","C"],["\u0578\u0582","u"],["\u0548\u0552","U"],["\u0548\u0582","U"],["\u0583","p"],["\u0553","P"],["\u0584","q"],["\u0554","Q"],["\u0585","o"],["\u0555","O"],["\u0586","f"],["\u0556","F"],["\u0587","yev"],["\u10D0","a"],["\u10D1","b"],["\u10D2","g"],["\u10D3","d"],["\u10D4","e"],["\u10D5","v"],["\u10D6","z"],["\u10D7","t"],["\u10D8","i"],["\u10D9","k"],["\u10DA","l"],["\u10DB","m"],["\u10DC","n"],["\u10DD","o"],["\u10DE","p"],["\u10DF","zh"],["\u10E0","r"],["\u10E1","s"],["\u10E2","t"],["\u10E3","u"],["\u10E4","ph"],["\u10E5","q"],["\u10E6","gh"],["\u10E7","k"],["\u10E8","sh"],["\u10E9","ch"],["\u10EA","ts"],["\u10EB","dz"],["\u10EC","ts"],["\u10ED","tch"],["\u10EE","kh"],["\u10EF","j"],["\u10F0","h"],["\u010D","c"],["\u010F","d"],["\u011B","e"],["\u0148","n"],["\u0159","r"],["\u0161","s"],["\u0165","t"],["\u016F","u"],["\u017E","z"],["\u010C","C"],["\u010E","D"],["\u011A","E"],["\u0147","N"],["\u0158","R"],["\u0160","S"],["\u0164","T"],["\u016E","U"],["\u017D","Z"],["\u0780","h"],["\u0781","sh"],["\u0782","n"],["\u0783","r"],["\u0784","b"],["\u0785","lh"],["\u0786","k"],["\u0787","a"],["\u0788","v"],["\u0789","m"],["\u078A","f"],["\u078B","dh"],["\u078C","th"],["\u078D","l"],["\u078E","g"],["\u078F","gn"],["\u0790","s"],["\u0791","d"],["\u0792","z"],["\u0793","t"],["\u0794","y"],["\u0795","p"],["\u0796","j"],["\u0797","ch"],["\u0798","tt"],["\u0799","hh"],["\u079A","kh"],["\u079B","th"],["\u079C","z"],["\u079D","sh"],["\u079E","s"],["\u079F","d"],["\u07A0","t"],["\u07A1","z"],["\u07A2","a"],["\u07A3","gh"],["\u07A4","q"],["\u07A5","w"],["\u07A6","a"],["\u07A7","aa"],["\u07A8","i"],["\u07A9","ee"],["\u07AA","u"],["\u07AB","oo"],["\u07AC","e"],["\u07AD","ey"],["\u07AE","o"],["\u07AF","oa"],["\u07B0",""],["\u03B1","a"],["\u03B2","v"],["\u03B3","g"],["\u03B4","d"],["\u03B5","e"],["\u03B6","z"],["\u03B7","i"],["\u03B8","th"],["\u03B9","i"],["\u03BA","k"],["\u03BB","l"],["\u03BC","m"],["\u03BD","n"],["\u03BE","ks"],["\u03BF","o"],["\u03C0","p"],["\u03C1","r"],["\u03C3","s"],["\u03C4","t"],["\u03C5","y"],["\u03C6","f"],["\u03C7","x"],["\u03C8","ps"],["\u03C9","o"],["\u03AC","a"],["\u03AD","e"],["\u03AF","i"],["\u03CC","o"],["\u03CD","y"],["\u03AE","i"],["\u03CE","o"],["\u03C2","s"],["\u03CA","i"],["\u03B0","y"],["\u03CB","y"],["\u0390","i"],["\u0391","A"],["\u0392","B"],["\u0393","G"],["\u0394","D"],["\u0395","E"],["\u0396","Z"],["\u0397","I"],["\u0398","TH"],["\u0399","I"],["\u039A","K"],["\u039B","L"],["\u039C","M"],["\u039D","N"],["\u039E","KS"],["\u039F","O"],["\u03A0","P"],["\u03A1","R"],["\u03A3","S"],["\u03A4","T"],["\u03A5","Y"],["\u03A6","F"],["\u03A7","X"],["\u03A8","PS"],["\u03A9","O"],["\u0386","A"],["\u0388","E"],["\u038A","I"],["\u038C","O"],["\u038E","Y"],["\u0389","I"],["\u038F","O"],["\u03AA","I"],["\u03AB","Y"],["\u0101","a"],["\u0113","e"],["\u0123","g"],["\u012B","i"],["\u0137","k"],["\u013C","l"],["\u0146","n"],["\u016B","u"],["\u0100","A"],["\u0112","E"],["\u0122","G"],["\u012A","I"],["\u0136","K"],["\u013B","L"],["\u0145","N"],["\u016A","U"],["\u010D","c"],["\u0161","s"],["\u017E","z"],["\u010C","C"],["\u0160","S"],["\u017D","Z"],["\u0105","a"],["\u010D","c"],["\u0119","e"],["\u0117","e"],["\u012F","i"],["\u0161","s"],["\u0173","u"],["\u016B","u"],["\u017E","z"],["\u0104","A"],["\u010C","C"],["\u0118","E"],["\u0116","E"],["\u012E","I"],["\u0160","S"],["\u0172","U"],["\u016A","U"],["\u040C","Kj"],["\u045C","kj"],["\u0409","Lj"],["\u0459","lj"],["\u040A","Nj"],["\u045A","nj"],["\u0422\u0441","Ts"],["\u0442\u0441","ts"],["\u0105","a"],["\u0107","c"],["\u0119","e"],["\u0142","l"],["\u0144","n"],["\u015B","s"],["\u017A","z"],["\u017C","z"],["\u0104","A"],["\u0106","C"],["\u0118","E"],["\u0141","L"],["\u0143","N"],["\u015A","S"],["\u0179","Z"],["\u017B","Z"],["\u0404","Ye"],["\u0406","I"],["\u0407","Yi"],["\u0490","G"],["\u0454","ye"],["\u0456","i"],["\u0457","yi"],["\u0491","g"]]}});var require_transliterate=__commonJS({"../../node_modules/.pnpm/@sindresorhus+transliterate@0.1.2/node_modules/@sindresorhus/transliterate/index.js"(exports,module){"use strict";var deburr=require_lodash(),escapeStringRegexp=require_escape_string_regexp(),builtinReplacements=require_replacements(),doCustomReplacements=(string,replacements)=>{for(let[key,value]of replacements)string=string.replace(new RegExp(escapeStringRegexp(key),"g"),value);return string};module.exports=(string,options)=>{if(typeof string!="string")throw new TypeError(`Expected a string, got \`${typeof string}\``);options={customReplacements:[],...options};let customReplacements=new Map([...builtinReplacements,...options.customReplacements]);return string=string.normalize(),string=doCustomReplacements(string,customReplacements),string=deburr(string),string}}});var require_overridable_replacements=__commonJS({"../../node_modules/.pnpm/@sindresorhus+slugify@0.11.0/node_modules/@sindresorhus/slugify/overridable-replacements.js"(exports,module){"use strict";module.exports=[["&"," and "],["\u{1F984}"," unicorn "],["\u2665"," love "]]}});var require_slugify=__commonJS({"../../node_modules/.pnpm/@sindresorhus+slugify@0.11.0/node_modules/@sindresorhus/slugify/index.js"(exports,module){var escapeStringRegexp=require_escape_string_regexp(),transliterate=require_transliterate(),builtinOverridableReplacements=require_overridable_replacements(),decamelize=string=>string.replace(/([A-Z]{2,})([a-z\d]+)/g,"$1 $2").replace(/([a-z\d]+)([A-Z]{2,})/g,"$1 $2").replace(/([a-z\d])([A-Z])/g,"$1 $2").replace(/([A-Z]+)([A-Z][a-z\d]+)/g,"$1 $2"),removeMootSeparators=(string,separator)=>{let escapedSeparator=escapeStringRegexp(separator);return string.replace(new RegExp(`${escapedSeparator}{2,}`,"g"),separator).replace(new RegExp(`^${escapedSeparator}|${escapedSeparator}$`,"g"),"")};module.exports=(string,options)=>{if(typeof string!="string")throw new TypeError(`Expected a string, got \`${typeof string}\``);options={separator:"-",lowercase:!0,decamelize:!0,customReplacements:[],preserveLeadingUnderscore:!1,...options};let shouldPrependUnderscore=options.preserveLeadingUnderscore&&string.startsWith("_"),customReplacements=new Map([...builtinOverridableReplacements,...options.customReplacements]);string=transliterate(string,{customReplacements}),options.decamelize&&(string=decamelize(string));let patternSlug=/[^a-zA-Z\d]+/g;return options.lowercase&&(string=string.toLowerCase(),patternSlug=/[^a-z\d]+/g),string=string.replace(patternSlug,options.separator),string=string.replace(/\\/g,""),string=removeMootSeparators(string,options.separator),shouldPrependUnderscore&&(string=`_${string}`),string}}});export{require_slugify};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from 'node:module';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __dirname_ } from 'node:path';
|
|
4
|
+
const require = __createRequire(import.meta.url);
|
|
5
|
+
const __filename = __fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = __dirname_(__filename);
|
|
7
|
+
import{getExitCodeForErrorCode}from"./chunk-RW3X523R.js";import{AGENT_REASON,buildCommandWithGlobalFlags,getExitCodeForReason,outputAgentError}from"./chunk-DGYHWXD2.js";import{isJSONObject}from"./chunk-KNLGWGUE.js";import{output_manager_default}from"./chunk-XP3FT56R.js";import{readFileSync}from"fs";import{resolve}from"path";var MONITORS_API={basePath:"/alerts/v3/monitors",itemKey:"monitor",listKey:"monitors",typesKey:"monitorTypes",idKey:"monitorId"},ALERT_RULES_API={basePath:"/alerts/v3/alert-rules",itemKey:"rule",listKey:"rules",typesKey:"ruleTypes",idKey:"ruleId"};function rulesCollectionPath(api,teamId,options={}){let query=new URLSearchParams({teamId});return options.limit!==void 0&&query.set("limit",String(options.limit)),options.cursor&&query.set("cursor",options.cursor),options.projectId&&query.set("projectId",options.projectId),options.type&&query.set("type",options.type),`${api.basePath}?${query.toString()}`}function rulesItemPath(api,teamId,ruleId){let query=new URLSearchParams({teamId});return`${api.basePath}/${encodeURIComponent(ruleId)}?${query.toString()}`}function ruleNotificationsPath(api,teamId,ruleId){let query=new URLSearchParams({teamId});return`${api.basePath}/${encodeURIComponent(ruleId)}/notifications?${query.toString()}`}function rulesNotificationsPath(api,teamId,options={}){let query=new URLSearchParams({teamId});return options.limit!==void 0&&query.set("limit",String(options.limit)),options.cursor&&query.set("cursor",options.cursor),`${api.basePath}/notifications?${query.toString()}`}function rulesNotificationLinksPath(api,teamId,ruleId){let query=new URLSearchParams({teamId});return`${api.basePath}/${encodeURIComponent(ruleId)}/notifications/links?${query.toString()}`}function rulesSchemaPath(api,teamId,type){let query=new URLSearchParams({teamId});return type&&query.set("type",type),`${api.basePath}/schema?${query.toString()}`}async function fetchRule(client,api,scope,ruleId){return(await client.fetch(rulesItemPath(api,scope.teamId,ruleId)))[api.itemKey]}function getIssues(error){return Array.isArray(error.issues)?error.issues.filter(issue=>isJSONObject(issue)&&typeof issue.path=="string"&&typeof issue.message=="string"):[]}function outputRulesError(client,jsonOutput,code,message,options={}){let issues=options.issues??[],issueSummary=issues.slice(0,5).map(issue=>`${issue.path||"body"}: ${issue.message}`).join("; "),exitCode=options.reason!==void 0?getExitCodeForReason(options.reason):getExitCodeForErrorCode(code);return outputAgentError(client,{status:"error",reason:options.reason??AGENT_REASON.INVALID_ARGUMENTS,message,hint:options.hint??(issueSummary||void 0)},exitCode),jsonOutput?client.stdout.write(`${JSON.stringify({error:{code,message,...issues.length?{issues}:{}}},null,2)}
|
|
8
|
+
`):output_manager_default.fatal([message,...issues.map(issue=>` ${issue.path}: ${issue.message}`)].join(`
|
|
9
|
+
`)),exitCode}function handleRulesApiError(client,err,jsonOutput){let message=err.status===401?"You do not have access to monitors in this team. Ensure your role can manage Alert Rules, or pass --token and --scope.":err.status===403?err.serverMessage||"You do not have permission to manage monitors in this team.":err.status>=500?`The monitors endpoint failed (${err.status}). Re-run with --debug and share the x-vercel-id from the failed request.`:err.serverMessage||`API error (${err.status}).`;return outputRulesError(client,jsonOutput,err.code||"API_ERROR",message,{reason:err.status===401?"not_authorized":err.status===403?"forbidden":err.status===404?AGENT_REASON.NOT_FOUND:err.status===429?"rate_limited":AGENT_REASON.API_ERROR,issues:getIssues(err),hint:err.status===401||err.status===403?"Confirm the team with `vercel whoami`; use --scope <team-slug> if the monitor belongs to another team.":void 0})}var LEGACY_BODY_FIELDS=["alertTypes","customAlert","queryJsonString"];function readRuleBody(client,bodyPath,jsonOutput){let raw;try{raw=readFileSync(resolve(client.cwd,bodyPath),"utf8")}catch{return outputRulesError(client,jsonOutput,"INVALID_ARGUMENTS",`Could not read --body file: ${bodyPath}`)}let parsed;try{parsed=JSON.parse(raw)}catch{return outputRulesError(client,jsonOutput,"INVALID_ARGUMENTS","Invalid JSON in --body file.")}return isJSONObject(parsed)?LEGACY_BODY_FIELDS.some(field=>Object.hasOwn(parsed,field))?outputRulesError(client,jsonOutput,"LEGACY_ALERT_RULE_BODY","This body uses the previous alert-rules shape. Rewrite it using the current schema.",{hint:"Run `vercel monitors schema --type built-in` for examples."}):parsed:outputRulesError(client,jsonOutput,"INVALID_ARGUMENTS","The --body file must contain a JSON object.")}function getBodyType(body){return body.type==="built-in"||body.type==="custom"?body.type:void 0}function emitRulesArgParseError(client,err,recoverWithProjectFlag){let message=err instanceof Error?err.message:String(err),projectFlagMissingArg=message.includes("--project")&&message.includes("requires argument");outputAgentError(client,{status:"error",reason:AGENT_REASON.INVALID_ARGUMENTS,message:projectFlagMissingArg?"`--project` requires a project name or id (for example `--project my-app`).":message,next:[{command:buildCommandWithGlobalFlags(client.argv,projectFlagMissingArg?recoverWithProjectFlag:"monitors --help"),when:projectFlagMissingArg?"Retry with a project name or id":"See valid `monitors` subcommands"}]},2)}export{MONITORS_API,ALERT_RULES_API,rulesCollectionPath,rulesItemPath,ruleNotificationsPath,rulesNotificationsPath,rulesNotificationLinksPath,rulesSchemaPath,fetchRule,outputRulesError,handleRulesApiError,readRuleBody,getBodyType,emitRulesArgParseError};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from 'node:module';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __dirname_ } from 'node:path';
|
|
4
|
+
const require = __createRequire(import.meta.url);
|
|
5
|
+
const __filename = __fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = __dirname_(__filename);
|
|
7
|
+
function parseMeta(meta){if(!meta)return{};typeof meta=="string"&&(meta=[meta]);let parsed={};for(let item of meta){let[key,...rest]=item.split("=");parsed[key]=rest.join("=")}return parsed}export{parseMeta};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from 'node:module';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __dirname_ } from 'node:path';
|
|
4
|
+
const require = __createRequire(import.meta.url);
|
|
5
|
+
const __filename = __fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = __dirname_(__filename);
|
|
7
|
+
import{outputError,writeJsonError}from"./chunk-RW3X523R.js";import{resolveProjectContext}from"./chunk-3JGBBS6V.js";import{printError}from"./chunk-G4T7VBGN.js";import{detectExplicitScope,getScope}from"./chunk-B4UE4LVE.js";import{getLinkedProject}from"./chunk-KNLGWGUE.js";import{isAPIError}from"./chunk-6VH56CX2.js";import{getCommandName}from"./chunk-JESNVRVR.js";import{output_manager_default}from"./chunk-XP3FT56R.js";function handleCommentsParseError(err,subcommandName){return printError(err),err instanceof Error&&/unknown or unexpected option: -[^-]/.test(err.message)&&output_manager_default.log(`An argument starting with "-"? Put it after \`--\`: ${getCommandName(`comments ${subcommandName} -- <arg>`)}`),output_manager_default.log(`Run ${getCommandName(`comments ${subcommandName} --help`)} for usage.`),2}function threadNotFoundMessage(threadId,scope){return`Comment not found: ${threadId} in team ${scope.teamSlug??scope.teamId}. If it belongs to another team, pass --scope <team>.`}function query(teamId,params={}){let search=new URLSearchParams({teamId});for(let[key,value]of Object.entries(params))if(value!==void 0)if(Array.isArray(value))for(let entry of value)search.append(key,entry);else search.set(key,String(value));return search.toString()}var fetchOpts={useCurrentTeam:!1};function listThreads(client,teamId,params){return client.fetch(`/toolbar/threads?${query(teamId,{...params})}`,fetchOpts)}function getThread(client,teamId,threadId){return client.fetch(`/toolbar/threads/${encodeURIComponent(threadId)}?${query(teamId)}`,fetchOpts)}function updateThread(client,teamId,threadId,resolved){return client.fetch(`/toolbar/threads/${encodeURIComponent(threadId)}?${query(teamId)}`,{...fetchOpts,method:"PATCH",body:{resolved}})}function listMessages(client,teamId,threadId,opts={}){return client.fetch(`/toolbar/threads/${encodeURIComponent(threadId)}/messages?${query(teamId,{...opts})}`,fetchOpts)}function addMessage(client,teamId,threadId,body){return client.fetch(`/toolbar/threads/${encodeURIComponent(threadId)}/messages?${query(teamId)}`,{...fetchOpts,method:"POST",body})}function updateMessage(client,teamId,threadId,messageId,body){return client.fetch(`/toolbar/threads/${encodeURIComponent(threadId)}/messages/${encodeURIComponent(messageId)}?${query(teamId)}`,{...fetchOpts,method:"PATCH",body})}function deleteMessage(client,teamId,threadId,messageId){return client.fetch(`/toolbar/threads/${encodeURIComponent(threadId)}/messages/${encodeURIComponent(messageId)}?${query(teamId)}`,{...fetchOpts,method:"DELETE"})}function toApiErrorParts(err){let apiErr=err;return{code:apiErr.code||"API_ERROR",message:apiErr.serverMessage||`API error (${apiErr.status??"unknown"}).`}}import{spawnSync}from"node:child_process";async function resolveCommentsScope(client,opts){if(opts.urlTeamSlug&&!opts.project&&!detectExplicitScope(client))return{teamId:opts.urlTeamSlug,teamSlug:opts.urlTeamSlug};if(opts.project){let context;try{context=await resolveProjectContext({client,projectNameOrId:opts.project,projectNotFoundHandling:opts.jsonOutput?"return":"report"})}catch(err){if(isAPIError(err))return outputError(client,opts.jsonOutput,err.code||"API_ERROR",err.serverMessage||`API error (${err.status}).`);throw err}return context.status==="error"?(opts.jsonOutput&&writeJsonError(client,"PROJECT_CONTEXT_ERROR","Could not resolve the project context."),context.exitCode):context.status==="not_linked"?outputError(client,opts.jsonOutput,"PROJECT_NOT_FOUND",`Project "${opts.project}" was not found in the current scope.`):{teamId:context.org.id,teamSlug:context.org.slug,projectId:context.project.id,projectName:context.project.name,linked:!!context.repoRoot}}let linked=await getLinkedProject(client);if(linked.status==="error")return linked.exitCode;if(linked.status==="linked"){if(detectExplicitScope(client)){let{team:team2}=await getScope(client);if(!team2)return outputError(client,opts.jsonOutput,"NO_TEAM","No team context found for --scope.");if(team2.id!==linked.org.id)return opts.requireProject?outputError(client,opts.jsonOutput,"SCOPE_PROJECT_MISMATCH",`--scope ${team2.slug} does not match the linked project's team (${linked.org.slug}). Pass --project <name-or-id> for a project in ${team2.slug}.`):{teamId:team2.id,teamSlug:team2.slug}}return{teamId:linked.org.id,teamSlug:linked.org.slug,projectId:linked.project.id,projectName:linked.project.name,linked:!0}}if(opts.requireProject)return outputError(client,opts.jsonOutput,"NOT_LINKED","No linked project found. Run `vercel link` to link a project, or pass --project <name-or-id>.");let{team}=await getScope(client);return team?{teamId:team.id,teamSlug:team.slug}:outputError(client,opts.jsonOutput,"NO_TEAM","No team context found. Run `vercel switch` to select a team, or run `vercel link` in a project directory.")}function inferBranch(cwd){let result=spawnSync("git",["rev-parse","--abbrev-ref","HEAD"],{cwd,encoding:"utf8"});if(result.status===0){let branch=result.stdout.trim();if(branch&&branch!=="HEAD")return{value:branch,source:"git"}}let ciRef=process.env.VERCEL_GIT_COMMIT_REF||process.env.GITHUB_HEAD_REF||process.env.GITHUB_REF_NAME;if(ciRef)return{value:ciRef,source:"ci"}}export{handleCommentsParseError,threadNotFoundMessage,listThreads,getThread,updateThread,listMessages,addMessage,updateMessage,deleteMessage,toApiErrorParts,resolveCommentsScope,inferBranch};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from 'node:module';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __dirname_ } from 'node:path';
|
|
4
|
+
const require = __createRequire(import.meta.url);
|
|
5
|
+
const __filename = __fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = __dirname_(__filename);
|
|
7
|
+
import{__commonJS}from"./chunk-BZENIQ7N.js";var require_escape_string_regexp=__commonJS({"../../node_modules/.pnpm/escape-string-regexp@1.0.5/node_modules/escape-string-regexp/index.js"(exports,module){"use strict";var matchOperatorsRe=/[|\\{}()[\]^$+*?.]/g;module.exports=function(str){if(typeof str!="string")throw new TypeError("Expected a string");return str.replace(matchOperatorsRe,"\\$&")}}});export{require_escape_string_regexp};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from 'node:module';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __dirname_ } from 'node:path';
|
|
4
|
+
const require = __createRequire(import.meta.url);
|
|
5
|
+
const __filename = __fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = __dirname_(__filename);
|
|
7
|
+
import{require_end_of_stream}from"./chunk-FBYA6LLM.js";import{require_inherits}from"./chunk-7EJQLVWX.js";import{require_once}from"./chunk-SCV7XEEO.js";import{__commonJS,__require}from"./chunk-BZENIQ7N.js";var require_chownr=__commonJS({"../../node_modules/.pnpm/chownr@1.1.4/node_modules/chownr/chownr.js"(exports,module){"use strict";var fs=__require("fs"),path=__require("path"),LCHOWN=fs.lchown?"lchown":"chown",LCHOWNSYNC=fs.lchownSync?"lchownSync":"chownSync",needEISDIRHandled=fs.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),lchownSync=(path2,uid,gid)=>{try{return fs[LCHOWNSYNC](path2,uid,gid)}catch(er){if(er.code!=="ENOENT")throw er}},chownSync=(path2,uid,gid)=>{try{return fs.chownSync(path2,uid,gid)}catch(er){if(er.code!=="ENOENT")throw er}},handleEISDIR=needEISDIRHandled?(path2,uid,gid,cb)=>er=>{!er||er.code!=="EISDIR"?cb(er):fs.chown(path2,uid,gid,cb)}:(_,__,___,cb)=>cb,handleEISDirSync=needEISDIRHandled?(path2,uid,gid)=>{try{return lchownSync(path2,uid,gid)}catch(er){if(er.code!=="EISDIR")throw er;chownSync(path2,uid,gid)}}:(path2,uid,gid)=>lchownSync(path2,uid,gid),nodeVersion=process.version,readdir=(path2,options,cb)=>fs.readdir(path2,options,cb),readdirSync=(path2,options)=>fs.readdirSync(path2,options);/^v4\./.test(nodeVersion)&&(readdir=(path2,options,cb)=>fs.readdir(path2,cb));var chown=(cpath,uid,gid,cb)=>{fs[LCHOWN](cpath,uid,gid,handleEISDIR(cpath,uid,gid,er=>{cb(er&&er.code!=="ENOENT"?er:null)}))},chownrKid=(p,child,uid,gid,cb)=>{if(typeof child=="string")return fs.lstat(path.resolve(p,child),(er,stats)=>{if(er)return cb(er.code!=="ENOENT"?er:null);stats.name=child,chownrKid(p,stats,uid,gid,cb)});if(child.isDirectory())chownr(path.resolve(p,child.name),uid,gid,er=>{if(er)return cb(er);let cpath=path.resolve(p,child.name);chown(cpath,uid,gid,cb)});else{let cpath=path.resolve(p,child.name);chown(cpath,uid,gid,cb)}},chownr=(p,uid,gid,cb)=>{readdir(p,{withFileTypes:!0},(er,children)=>{if(er){if(er.code==="ENOENT")return cb();if(er.code!=="ENOTDIR"&&er.code!=="ENOTSUP")return cb(er)}if(er||!children.length)return chown(p,uid,gid,cb);let len=children.length,errState=null,then=er2=>{if(!errState){if(er2)return cb(errState=er2);if(--len===0)return chown(p,uid,gid,cb)}};children.forEach(child=>chownrKid(p,child,uid,gid,then))})},chownrKidSync=(p,child,uid,gid)=>{if(typeof child=="string")try{let stats=fs.lstatSync(path.resolve(p,child));stats.name=child,child=stats}catch(er){if(er.code==="ENOENT")return;throw er}child.isDirectory()&&chownrSync(path.resolve(p,child.name),uid,gid),handleEISDirSync(path.resolve(p,child.name),uid,gid)},chownrSync=(p,uid,gid)=>{let children;try{children=readdirSync(p,{withFileTypes:!0})}catch(er){if(er.code==="ENOENT")return;if(er.code==="ENOTDIR"||er.code==="ENOTSUP")return handleEISDirSync(p,uid,gid);throw er}return children&&children.length&&children.forEach(child=>chownrKidSync(p,child,uid,gid)),handleEISDirSync(p,uid,gid)};module.exports=chownr;chownr.sync=chownrSync}});var require_process_nextick_args=__commonJS({"../../node_modules/.pnpm/process-nextick-args@2.0.1/node_modules/process-nextick-args/index.js"(exports,module){"use strict";typeof process>"u"||!process.version||process.version.indexOf("v0.")===0||process.version.indexOf("v1.")===0&&process.version.indexOf("v1.8.")!==0?module.exports={nextTick}:module.exports=process;function nextTick(fn,arg1,arg2,arg3){if(typeof fn!="function")throw new TypeError('"callback" argument must be a function');var len=arguments.length,args,i;switch(len){case 0:case 1:return process.nextTick(fn);case 2:return process.nextTick(function(){fn.call(null,arg1)});case 3:return process.nextTick(function(){fn.call(null,arg1,arg2)});case 4:return process.nextTick(function(){fn.call(null,arg1,arg2,arg3)});default:for(args=new Array(len-1),i=0;i<args.length;)args[i++]=arguments[i];return process.nextTick(function(){fn.apply(null,args)})}}}});var require_isarray=__commonJS({"../../node_modules/.pnpm/isarray@1.0.0/node_modules/isarray/index.js"(exports,module){var toString={}.toString;module.exports=Array.isArray||function(arr){return toString.call(arr)=="[object Array]"}}});var require_stream=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/lib/internal/streams/stream.js"(exports,module){module.exports=__require("stream")}});var require_safe_buffer=__commonJS({"../../node_modules/.pnpm/safe-buffer@5.1.2/node_modules/safe-buffer/index.js"(exports,module){var buffer=__require("buffer"),Buffer2=buffer.Buffer;function copyProps(src,dst){for(var key in src)dst[key]=src[key]}Buffer2.from&&Buffer2.alloc&&Buffer2.allocUnsafe&&Buffer2.allocUnsafeSlow?module.exports=buffer:(copyProps(buffer,exports),exports.Buffer=SafeBuffer);function SafeBuffer(arg,encodingOrOffset,length){return Buffer2(arg,encodingOrOffset,length)}copyProps(Buffer2,SafeBuffer);SafeBuffer.from=function(arg,encodingOrOffset,length){if(typeof arg=="number")throw new TypeError("Argument must not be a number");return Buffer2(arg,encodingOrOffset,length)};SafeBuffer.alloc=function(size,fill,encoding){if(typeof size!="number")throw new TypeError("Argument must be a number");var buf=Buffer2(size);return fill!==void 0?typeof encoding=="string"?buf.fill(fill,encoding):buf.fill(fill):buf.fill(0),buf};SafeBuffer.allocUnsafe=function(size){if(typeof size!="number")throw new TypeError("Argument must be a number");return Buffer2(size)};SafeBuffer.allocUnsafeSlow=function(size){if(typeof size!="number")throw new TypeError("Argument must be a number");return buffer.SlowBuffer(size)}}});var require_util=__commonJS({"../../node_modules/.pnpm/core-util-is@1.0.3/node_modules/core-util-is/lib/util.js"(exports){function isArray(arg){return Array.isArray?Array.isArray(arg):objectToString(arg)==="[object Array]"}exports.isArray=isArray;function isBoolean(arg){return typeof arg=="boolean"}exports.isBoolean=isBoolean;function isNull(arg){return arg===null}exports.isNull=isNull;function isNullOrUndefined(arg){return arg==null}exports.isNullOrUndefined=isNullOrUndefined;function isNumber(arg){return typeof arg=="number"}exports.isNumber=isNumber;function isString(arg){return typeof arg=="string"}exports.isString=isString;function isSymbol(arg){return typeof arg=="symbol"}exports.isSymbol=isSymbol;function isUndefined(arg){return arg===void 0}exports.isUndefined=isUndefined;function isRegExp(re){return objectToString(re)==="[object RegExp]"}exports.isRegExp=isRegExp;function isObject(arg){return typeof arg=="object"&&arg!==null}exports.isObject=isObject;function isDate(d){return objectToString(d)==="[object Date]"}exports.isDate=isDate;function isError(e){return objectToString(e)==="[object Error]"||e instanceof Error}exports.isError=isError;function isFunction(arg){return typeof arg=="function"}exports.isFunction=isFunction;function isPrimitive(arg){return arg===null||typeof arg=="boolean"||typeof arg=="number"||typeof arg=="string"||typeof arg=="symbol"||typeof arg>"u"}exports.isPrimitive=isPrimitive;exports.isBuffer=__require("buffer").Buffer.isBuffer;function objectToString(o){return Object.prototype.toString.call(o)}}});var require_BufferList=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/lib/internal/streams/BufferList.js"(exports,module){"use strict";function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}var Buffer2=require_safe_buffer().Buffer,util=__require("util");function copyBuffer(src,target,offset){src.copy(target,offset)}module.exports=function(){function BufferList(){_classCallCheck(this,BufferList),this.head=null,this.tail=null,this.length=0}return BufferList.prototype.push=function(v){var entry={data:v,next:null};this.length>0?this.tail.next=entry:this.head=entry,this.tail=entry,++this.length},BufferList.prototype.unshift=function(v){var entry={data:v,next:this.head};this.length===0&&(this.tail=entry),this.head=entry,++this.length},BufferList.prototype.shift=function(){if(this.length!==0){var ret=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,ret}},BufferList.prototype.clear=function(){this.head=this.tail=null,this.length=0},BufferList.prototype.join=function(s){if(this.length===0)return"";for(var p=this.head,ret=""+p.data;p=p.next;)ret+=s+p.data;return ret},BufferList.prototype.concat=function(n){if(this.length===0)return Buffer2.alloc(0);for(var ret=Buffer2.allocUnsafe(n>>>0),p=this.head,i=0;p;)copyBuffer(p.data,ret,i),i+=p.data.length,p=p.next;return ret},BufferList}();util&&util.inspect&&util.inspect.custom&&(module.exports.prototype[util.inspect.custom]=function(){var obj=util.inspect({length:this.length});return this.constructor.name+" "+obj})}});var require_destroy=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/lib/internal/streams/destroy.js"(exports,module){"use strict";var pna=require_process_nextick_args();function destroy(err,cb){var _this=this,readableDestroyed=this._readableState&&this._readableState.destroyed,writableDestroyed=this._writableState&&this._writableState.destroyed;return readableDestroyed||writableDestroyed?(cb?cb(err):err&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,pna.nextTick(emitErrorNT,this,err)):pna.nextTick(emitErrorNT,this,err)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(err||null,function(err2){!cb&&err2?_this._writableState?_this._writableState.errorEmitted||(_this._writableState.errorEmitted=!0,pna.nextTick(emitErrorNT,_this,err2)):pna.nextTick(emitErrorNT,_this,err2):cb&&cb(err2)}),this)}function undestroy(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function emitErrorNT(self2,err){self2.emit("error",err)}module.exports={destroy,undestroy}}});var require_node=__commonJS({"../../node_modules/.pnpm/util-deprecate@1.0.2/node_modules/util-deprecate/node.js"(exports,module){module.exports=__require("util").deprecate}});var require_stream_writable=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/lib/_stream_writable.js"(exports,module){"use strict";var pna=require_process_nextick_args();module.exports=Writable;function CorkedRequest(state){var _this=this;this.next=null,this.entry=null,this.finish=function(){onCorkedFinish(_this,state)}}var asyncWrite=!process.browser&&["v0.10","v0.9."].indexOf(process.version.slice(0,5))>-1?setImmediate:pna.nextTick,Duplex;Writable.WritableState=WritableState;var util=Object.create(require_util());util.inherits=require_inherits();var internalUtil={deprecate:require_node()},Stream=require_stream(),Buffer2=require_safe_buffer().Buffer,OurUint8Array=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function _uint8ArrayToBuffer(chunk){return Buffer2.from(chunk)}function _isUint8Array(obj){return Buffer2.isBuffer(obj)||obj instanceof OurUint8Array}var destroyImpl=require_destroy();util.inherits(Writable,Stream);function nop(){}function WritableState(options,stream){Duplex=Duplex||require_stream_duplex(),options=options||{};var isDuplex=stream instanceof Duplex;this.objectMode=!!options.objectMode,isDuplex&&(this.objectMode=this.objectMode||!!options.writableObjectMode);var hwm=options.highWaterMark,writableHwm=options.writableHighWaterMark,defaultHwm=this.objectMode?16:16*1024;hwm||hwm===0?this.highWaterMark=hwm:isDuplex&&(writableHwm||writableHwm===0)?this.highWaterMark=writableHwm:this.highWaterMark=defaultHwm,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var noDecode=options.decodeStrings===!1;this.decodeStrings=!noDecode,this.defaultEncoding=options.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(er){onwrite(stream,er)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new CorkedRequest(this)}WritableState.prototype.getBuffer=function(){for(var current=this.bufferedRequest,out=[];current;)out.push(current),current=current.next;return out};(function(){try{Object.defineProperty(WritableState.prototype,"buffer",{get:internalUtil.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var realHasInstance;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(realHasInstance=Function.prototype[Symbol.hasInstance],Object.defineProperty(Writable,Symbol.hasInstance,{value:function(object){return realHasInstance.call(this,object)?!0:this!==Writable?!1:object&&object._writableState instanceof WritableState}})):realHasInstance=function(object){return object instanceof this};function Writable(options){if(Duplex=Duplex||require_stream_duplex(),!realHasInstance.call(Writable,this)&&!(this instanceof Duplex))return new Writable(options);this._writableState=new WritableState(options,this),this.writable=!0,options&&(typeof options.write=="function"&&(this._write=options.write),typeof options.writev=="function"&&(this._writev=options.writev),typeof options.destroy=="function"&&(this._destroy=options.destroy),typeof options.final=="function"&&(this._final=options.final)),Stream.call(this)}Writable.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))};function writeAfterEnd(stream,cb){var er=new Error("write after end");stream.emit("error",er),pna.nextTick(cb,er)}function validChunk(stream,state,chunk,cb){var valid=!0,er=!1;return chunk===null?er=new TypeError("May not write null values to stream"):typeof chunk!="string"&&chunk!==void 0&&!state.objectMode&&(er=new TypeError("Invalid non-string/buffer chunk")),er&&(stream.emit("error",er),pna.nextTick(cb,er),valid=!1),valid}Writable.prototype.write=function(chunk,encoding,cb){var state=this._writableState,ret=!1,isBuf=!state.objectMode&&_isUint8Array(chunk);return isBuf&&!Buffer2.isBuffer(chunk)&&(chunk=_uint8ArrayToBuffer(chunk)),typeof encoding=="function"&&(cb=encoding,encoding=null),isBuf?encoding="buffer":encoding||(encoding=state.defaultEncoding),typeof cb!="function"&&(cb=nop),state.ended?writeAfterEnd(this,cb):(isBuf||validChunk(this,state,chunk,cb))&&(state.pendingcb++,ret=writeOrBuffer(this,state,isBuf,chunk,encoding,cb)),ret};Writable.prototype.cork=function(){var state=this._writableState;state.corked++};Writable.prototype.uncork=function(){var state=this._writableState;state.corked&&(state.corked--,!state.writing&&!state.corked&&!state.bufferProcessing&&state.bufferedRequest&&clearBuffer(this,state))};Writable.prototype.setDefaultEncoding=function(encoding){if(typeof encoding=="string"&&(encoding=encoding.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((encoding+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+encoding);return this._writableState.defaultEncoding=encoding,this};function decodeChunk(state,chunk,encoding){return!state.objectMode&&state.decodeStrings!==!1&&typeof chunk=="string"&&(chunk=Buffer2.from(chunk,encoding)),chunk}Object.defineProperty(Writable.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function writeOrBuffer(stream,state,isBuf,chunk,encoding,cb){if(!isBuf){var newChunk=decodeChunk(state,chunk,encoding);chunk!==newChunk&&(isBuf=!0,encoding="buffer",chunk=newChunk)}var len=state.objectMode?1:chunk.length;state.length+=len;var ret=state.length<state.highWaterMark;if(ret||(state.needDrain=!0),state.writing||state.corked){var last=state.lastBufferedRequest;state.lastBufferedRequest={chunk,encoding,isBuf,callback:cb,next:null},last?last.next=state.lastBufferedRequest:state.bufferedRequest=state.lastBufferedRequest,state.bufferedRequestCount+=1}else doWrite(stream,state,!1,len,chunk,encoding,cb);return ret}function doWrite(stream,state,writev,len,chunk,encoding,cb){state.writelen=len,state.writecb=cb,state.writing=!0,state.sync=!0,writev?stream._writev(chunk,state.onwrite):stream._write(chunk,encoding,state.onwrite),state.sync=!1}function onwriteError(stream,state,sync,er,cb){--state.pendingcb,sync?(pna.nextTick(cb,er),pna.nextTick(finishMaybe,stream,state),stream._writableState.errorEmitted=!0,stream.emit("error",er)):(cb(er),stream._writableState.errorEmitted=!0,stream.emit("error",er),finishMaybe(stream,state))}function onwriteStateUpdate(state){state.writing=!1,state.writecb=null,state.length-=state.writelen,state.writelen=0}function onwrite(stream,er){var state=stream._writableState,sync=state.sync,cb=state.writecb;if(onwriteStateUpdate(state),er)onwriteError(stream,state,sync,er,cb);else{var finished=needFinish(state);!finished&&!state.corked&&!state.bufferProcessing&&state.bufferedRequest&&clearBuffer(stream,state),sync?asyncWrite(afterWrite,stream,state,finished,cb):afterWrite(stream,state,finished,cb)}}function afterWrite(stream,state,finished,cb){finished||onwriteDrain(stream,state),state.pendingcb--,cb(),finishMaybe(stream,state)}function onwriteDrain(stream,state){state.length===0&&state.needDrain&&(state.needDrain=!1,stream.emit("drain"))}function clearBuffer(stream,state){state.bufferProcessing=!0;var entry=state.bufferedRequest;if(stream._writev&&entry&&entry.next){var l=state.bufferedRequestCount,buffer=new Array(l),holder=state.corkedRequestsFree;holder.entry=entry;for(var count=0,allBuffers=!0;entry;)buffer[count]=entry,entry.isBuf||(allBuffers=!1),entry=entry.next,count+=1;buffer.allBuffers=allBuffers,doWrite(stream,state,!0,state.length,buffer,"",holder.finish),state.pendingcb++,state.lastBufferedRequest=null,holder.next?(state.corkedRequestsFree=holder.next,holder.next=null):state.corkedRequestsFree=new CorkedRequest(state),state.bufferedRequestCount=0}else{for(;entry;){var chunk=entry.chunk,encoding=entry.encoding,cb=entry.callback,len=state.objectMode?1:chunk.length;if(doWrite(stream,state,!1,len,chunk,encoding,cb),entry=entry.next,state.bufferedRequestCount--,state.writing)break}entry===null&&(state.lastBufferedRequest=null)}state.bufferedRequest=entry,state.bufferProcessing=!1}Writable.prototype._write=function(chunk,encoding,cb){cb(new Error("_write() is not implemented"))};Writable.prototype._writev=null;Writable.prototype.end=function(chunk,encoding,cb){var state=this._writableState;typeof chunk=="function"?(cb=chunk,chunk=null,encoding=null):typeof encoding=="function"&&(cb=encoding,encoding=null),chunk!=null&&this.write(chunk,encoding),state.corked&&(state.corked=1,this.uncork()),state.ending||endWritable(this,state,cb)};function needFinish(state){return state.ending&&state.length===0&&state.bufferedRequest===null&&!state.finished&&!state.writing}function callFinal(stream,state){stream._final(function(err){state.pendingcb--,err&&stream.emit("error",err),state.prefinished=!0,stream.emit("prefinish"),finishMaybe(stream,state)})}function prefinish(stream,state){!state.prefinished&&!state.finalCalled&&(typeof stream._final=="function"?(state.pendingcb++,state.finalCalled=!0,pna.nextTick(callFinal,stream,state)):(state.prefinished=!0,stream.emit("prefinish")))}function finishMaybe(stream,state){var need=needFinish(state);return need&&(prefinish(stream,state),state.pendingcb===0&&(state.finished=!0,stream.emit("finish"))),need}function endWritable(stream,state,cb){state.ending=!0,finishMaybe(stream,state),cb&&(state.finished?pna.nextTick(cb):stream.once("finish",cb)),state.ended=!0,stream.writable=!1}function onCorkedFinish(corkReq,state,err){var entry=corkReq.entry;for(corkReq.entry=null;entry;){var cb=entry.callback;state.pendingcb--,cb(err),entry=entry.next}state.corkedRequestsFree.next=corkReq}Object.defineProperty(Writable.prototype,"destroyed",{get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(value){this._writableState&&(this._writableState.destroyed=value)}});Writable.prototype.destroy=destroyImpl.destroy;Writable.prototype._undestroy=destroyImpl.undestroy;Writable.prototype._destroy=function(err,cb){this.end(),cb(err)}}});var require_stream_duplex=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/lib/_stream_duplex.js"(exports,module){"use strict";var pna=require_process_nextick_args(),objectKeys=Object.keys||function(obj){var keys2=[];for(var key in obj)keys2.push(key);return keys2};module.exports=Duplex;var util=Object.create(require_util());util.inherits=require_inherits();var Readable=require_stream_readable(),Writable=require_stream_writable();util.inherits(Duplex,Readable);for(keys=objectKeys(Writable.prototype),v=0;v<keys.length;v++)method=keys[v],Duplex.prototype[method]||(Duplex.prototype[method]=Writable.prototype[method]);var keys,method,v;function Duplex(options){if(!(this instanceof Duplex))return new Duplex(options);Readable.call(this,options),Writable.call(this,options),options&&options.readable===!1&&(this.readable=!1),options&&options.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,options&&options.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",onend)}Object.defineProperty(Duplex.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function onend(){this.allowHalfOpen||this._writableState.ended||pna.nextTick(onEndNT,this)}function onEndNT(self2){self2.end()}Object.defineProperty(Duplex.prototype,"destroyed",{get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(value){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=value,this._writableState.destroyed=value)}});Duplex.prototype._destroy=function(err,cb){this.push(null),this.end(),pna.nextTick(cb,err)}}});var require_string_decoder=__commonJS({"../../node_modules/.pnpm/string_decoder@1.1.1/node_modules/string_decoder/lib/string_decoder.js"(exports){"use strict";var Buffer2=require_safe_buffer().Buffer,isEncoding=Buffer2.isEncoding||function(encoding){switch(encoding=""+encoding,encoding&&encoding.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function _normalizeEncoding(enc){if(!enc)return"utf8";for(var retried;;)switch(enc){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return enc;default:if(retried)return;enc=(""+enc).toLowerCase(),retried=!0}}function normalizeEncoding(enc){var nenc=_normalizeEncoding(enc);if(typeof nenc!="string"&&(Buffer2.isEncoding===isEncoding||!isEncoding(enc)))throw new Error("Unknown encoding: "+enc);return nenc||enc}exports.StringDecoder=StringDecoder;function StringDecoder(encoding){this.encoding=normalizeEncoding(encoding);var nb;switch(this.encoding){case"utf16le":this.text=utf16Text,this.end=utf16End,nb=4;break;case"utf8":this.fillLast=utf8FillLast,nb=4;break;case"base64":this.text=base64Text,this.end=base64End,nb=3;break;default:this.write=simpleWrite,this.end=simpleEnd;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=Buffer2.allocUnsafe(nb)}StringDecoder.prototype.write=function(buf){if(buf.length===0)return"";var r,i;if(this.lastNeed){if(r=this.fillLast(buf),r===void 0)return"";i=this.lastNeed,this.lastNeed=0}else i=0;return i<buf.length?r?r+this.text(buf,i):this.text(buf,i):r||""};StringDecoder.prototype.end=utf8End;StringDecoder.prototype.text=utf8Text;StringDecoder.prototype.fillLast=function(buf){if(this.lastNeed<=buf.length)return buf.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);buf.copy(this.lastChar,this.lastTotal-this.lastNeed,0,buf.length),this.lastNeed-=buf.length};function utf8CheckByte(byte){return byte<=127?0:byte>>5===6?2:byte>>4===14?3:byte>>3===30?4:byte>>6===2?-1:-2}function utf8CheckIncomplete(self2,buf,i){var j=buf.length-1;if(j<i)return 0;var nb=utf8CheckByte(buf[j]);return nb>=0?(nb>0&&(self2.lastNeed=nb-1),nb):--j<i||nb===-2?0:(nb=utf8CheckByte(buf[j]),nb>=0?(nb>0&&(self2.lastNeed=nb-2),nb):--j<i||nb===-2?0:(nb=utf8CheckByte(buf[j]),nb>=0?(nb>0&&(nb===2?nb=0:self2.lastNeed=nb-3),nb):0))}function utf8CheckExtraBytes(self2,buf,p){if((buf[0]&192)!==128)return self2.lastNeed=0,"\uFFFD";if(self2.lastNeed>1&&buf.length>1){if((buf[1]&192)!==128)return self2.lastNeed=1,"\uFFFD";if(self2.lastNeed>2&&buf.length>2&&(buf[2]&192)!==128)return self2.lastNeed=2,"\uFFFD"}}function utf8FillLast(buf){var p=this.lastTotal-this.lastNeed,r=utf8CheckExtraBytes(this,buf,p);if(r!==void 0)return r;if(this.lastNeed<=buf.length)return buf.copy(this.lastChar,p,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);buf.copy(this.lastChar,p,0,buf.length),this.lastNeed-=buf.length}function utf8Text(buf,i){var total=utf8CheckIncomplete(this,buf,i);if(!this.lastNeed)return buf.toString("utf8",i);this.lastTotal=total;var end=buf.length-(total-this.lastNeed);return buf.copy(this.lastChar,0,end),buf.toString("utf8",i,end)}function utf8End(buf){var r=buf&&buf.length?this.write(buf):"";return this.lastNeed?r+"\uFFFD":r}function utf16Text(buf,i){if((buf.length-i)%2===0){var r=buf.toString("utf16le",i);if(r){var c=r.charCodeAt(r.length-1);if(c>=55296&&c<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=buf[buf.length-2],this.lastChar[1]=buf[buf.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=buf[buf.length-1],buf.toString("utf16le",i,buf.length-1)}function utf16End(buf){var r=buf&&buf.length?this.write(buf):"";if(this.lastNeed){var end=this.lastTotal-this.lastNeed;return r+this.lastChar.toString("utf16le",0,end)}return r}function base64Text(buf,i){var n=(buf.length-i)%3;return n===0?buf.toString("base64",i):(this.lastNeed=3-n,this.lastTotal=3,n===1?this.lastChar[0]=buf[buf.length-1]:(this.lastChar[0]=buf[buf.length-2],this.lastChar[1]=buf[buf.length-1]),buf.toString("base64",i,buf.length-n))}function base64End(buf){var r=buf&&buf.length?this.write(buf):"";return this.lastNeed?r+this.lastChar.toString("base64",0,3-this.lastNeed):r}function simpleWrite(buf){return buf.toString(this.encoding)}function simpleEnd(buf){return buf&&buf.length?this.write(buf):""}}});var require_stream_readable=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/lib/_stream_readable.js"(exports,module){"use strict";var pna=require_process_nextick_args();module.exports=Readable;var isArray=require_isarray(),Duplex;Readable.ReadableState=ReadableState;var EE=__require("events").EventEmitter,EElistenerCount=function(emitter,type){return emitter.listeners(type).length},Stream=require_stream(),Buffer2=require_safe_buffer().Buffer,OurUint8Array=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function _uint8ArrayToBuffer(chunk){return Buffer2.from(chunk)}function _isUint8Array(obj){return Buffer2.isBuffer(obj)||obj instanceof OurUint8Array}var util=Object.create(require_util());util.inherits=require_inherits();var debugUtil=__require("util"),debug=void 0;debugUtil&&debugUtil.debuglog?debug=debugUtil.debuglog("stream"):debug=function(){};var BufferList=require_BufferList(),destroyImpl=require_destroy(),StringDecoder;util.inherits(Readable,Stream);var kProxyEvents=["error","close","destroy","pause","resume"];function prependListener(emitter,event,fn){if(typeof emitter.prependListener=="function")return emitter.prependListener(event,fn);!emitter._events||!emitter._events[event]?emitter.on(event,fn):isArray(emitter._events[event])?emitter._events[event].unshift(fn):emitter._events[event]=[fn,emitter._events[event]]}function ReadableState(options,stream){Duplex=Duplex||require_stream_duplex(),options=options||{};var isDuplex=stream instanceof Duplex;this.objectMode=!!options.objectMode,isDuplex&&(this.objectMode=this.objectMode||!!options.readableObjectMode);var hwm=options.highWaterMark,readableHwm=options.readableHighWaterMark,defaultHwm=this.objectMode?16:16*1024;hwm||hwm===0?this.highWaterMark=hwm:isDuplex&&(readableHwm||readableHwm===0)?this.highWaterMark=readableHwm:this.highWaterMark=defaultHwm,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new BufferList,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=options.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,options.encoding&&(StringDecoder||(StringDecoder=require_string_decoder().StringDecoder),this.decoder=new StringDecoder(options.encoding),this.encoding=options.encoding)}function Readable(options){if(Duplex=Duplex||require_stream_duplex(),!(this instanceof Readable))return new Readable(options);this._readableState=new ReadableState(options,this),this.readable=!0,options&&(typeof options.read=="function"&&(this._read=options.read),typeof options.destroy=="function"&&(this._destroy=options.destroy)),Stream.call(this)}Object.defineProperty(Readable.prototype,"destroyed",{get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(value){this._readableState&&(this._readableState.destroyed=value)}});Readable.prototype.destroy=destroyImpl.destroy;Readable.prototype._undestroy=destroyImpl.undestroy;Readable.prototype._destroy=function(err,cb){this.push(null),cb(err)};Readable.prototype.push=function(chunk,encoding){var state=this._readableState,skipChunkCheck;return state.objectMode?skipChunkCheck=!0:typeof chunk=="string"&&(encoding=encoding||state.defaultEncoding,encoding!==state.encoding&&(chunk=Buffer2.from(chunk,encoding),encoding=""),skipChunkCheck=!0),readableAddChunk(this,chunk,encoding,!1,skipChunkCheck)};Readable.prototype.unshift=function(chunk){return readableAddChunk(this,chunk,null,!0,!1)};function readableAddChunk(stream,chunk,encoding,addToFront,skipChunkCheck){var state=stream._readableState;if(chunk===null)state.reading=!1,onEofChunk(stream,state);else{var er;skipChunkCheck||(er=chunkInvalid(state,chunk)),er?stream.emit("error",er):state.objectMode||chunk&&chunk.length>0?(typeof chunk!="string"&&!state.objectMode&&Object.getPrototypeOf(chunk)!==Buffer2.prototype&&(chunk=_uint8ArrayToBuffer(chunk)),addToFront?state.endEmitted?stream.emit("error",new Error("stream.unshift() after end event")):addChunk(stream,state,chunk,!0):state.ended?stream.emit("error",new Error("stream.push() after EOF")):(state.reading=!1,state.decoder&&!encoding?(chunk=state.decoder.write(chunk),state.objectMode||chunk.length!==0?addChunk(stream,state,chunk,!1):maybeReadMore(stream,state)):addChunk(stream,state,chunk,!1))):addToFront||(state.reading=!1)}return needMoreData(state)}function addChunk(stream,state,chunk,addToFront){state.flowing&&state.length===0&&!state.sync?(stream.emit("data",chunk),stream.read(0)):(state.length+=state.objectMode?1:chunk.length,addToFront?state.buffer.unshift(chunk):state.buffer.push(chunk),state.needReadable&&emitReadable(stream)),maybeReadMore(stream,state)}function chunkInvalid(state,chunk){var er;return!_isUint8Array(chunk)&&typeof chunk!="string"&&chunk!==void 0&&!state.objectMode&&(er=new TypeError("Invalid non-string/buffer chunk")),er}function needMoreData(state){return!state.ended&&(state.needReadable||state.length<state.highWaterMark||state.length===0)}Readable.prototype.isPaused=function(){return this._readableState.flowing===!1};Readable.prototype.setEncoding=function(enc){return StringDecoder||(StringDecoder=require_string_decoder().StringDecoder),this._readableState.decoder=new StringDecoder(enc),this._readableState.encoding=enc,this};var MAX_HWM=8388608;function computeNewHighWaterMark(n){return n>=MAX_HWM?n=MAX_HWM:(n--,n|=n>>>1,n|=n>>>2,n|=n>>>4,n|=n>>>8,n|=n>>>16,n++),n}function howMuchToRead(n,state){return n<=0||state.length===0&&state.ended?0:state.objectMode?1:n!==n?state.flowing&&state.length?state.buffer.head.data.length:state.length:(n>state.highWaterMark&&(state.highWaterMark=computeNewHighWaterMark(n)),n<=state.length?n:state.ended?state.length:(state.needReadable=!0,0))}Readable.prototype.read=function(n){debug("read",n),n=parseInt(n,10);var state=this._readableState,nOrig=n;if(n!==0&&(state.emittedReadable=!1),n===0&&state.needReadable&&(state.length>=state.highWaterMark||state.ended))return debug("read: emitReadable",state.length,state.ended),state.length===0&&state.ended?endReadable(this):emitReadable(this),null;if(n=howMuchToRead(n,state),n===0&&state.ended)return state.length===0&&endReadable(this),null;var doRead=state.needReadable;debug("need readable",doRead),(state.length===0||state.length-n<state.highWaterMark)&&(doRead=!0,debug("length less than watermark",doRead)),state.ended||state.reading?(doRead=!1,debug("reading or ended",doRead)):doRead&&(debug("do read"),state.reading=!0,state.sync=!0,state.length===0&&(state.needReadable=!0),this._read(state.highWaterMark),state.sync=!1,state.reading||(n=howMuchToRead(nOrig,state)));var ret;return n>0?ret=fromList(n,state):ret=null,ret===null?(state.needReadable=!0,n=0):state.length-=n,state.length===0&&(state.ended||(state.needReadable=!0),nOrig!==n&&state.ended&&endReadable(this)),ret!==null&&this.emit("data",ret),ret};function onEofChunk(stream,state){if(!state.ended){if(state.decoder){var chunk=state.decoder.end();chunk&&chunk.length&&(state.buffer.push(chunk),state.length+=state.objectMode?1:chunk.length)}state.ended=!0,emitReadable(stream)}}function emitReadable(stream){var state=stream._readableState;state.needReadable=!1,state.emittedReadable||(debug("emitReadable",state.flowing),state.emittedReadable=!0,state.sync?pna.nextTick(emitReadable_,stream):emitReadable_(stream))}function emitReadable_(stream){debug("emit readable"),stream.emit("readable"),flow(stream)}function maybeReadMore(stream,state){state.readingMore||(state.readingMore=!0,pna.nextTick(maybeReadMore_,stream,state))}function maybeReadMore_(stream,state){for(var len=state.length;!state.reading&&!state.flowing&&!state.ended&&state.length<state.highWaterMark&&(debug("maybeReadMore read 0"),stream.read(0),len!==state.length);)len=state.length;state.readingMore=!1}Readable.prototype._read=function(n){this.emit("error",new Error("_read() is not implemented"))};Readable.prototype.pipe=function(dest,pipeOpts){var src=this,state=this._readableState;switch(state.pipesCount){case 0:state.pipes=dest;break;case 1:state.pipes=[state.pipes,dest];break;default:state.pipes.push(dest);break}state.pipesCount+=1,debug("pipe count=%d opts=%j",state.pipesCount,pipeOpts);var doEnd=(!pipeOpts||pipeOpts.end!==!1)&&dest!==process.stdout&&dest!==process.stderr,endFn=doEnd?onend:unpipe;state.endEmitted?pna.nextTick(endFn):src.once("end",endFn),dest.on("unpipe",onunpipe);function onunpipe(readable,unpipeInfo){debug("onunpipe"),readable===src&&unpipeInfo&&unpipeInfo.hasUnpiped===!1&&(unpipeInfo.hasUnpiped=!0,cleanup())}function onend(){debug("onend"),dest.end()}var ondrain=pipeOnDrain(src);dest.on("drain",ondrain);var cleanedUp=!1;function cleanup(){debug("cleanup"),dest.removeListener("close",onclose),dest.removeListener("finish",onfinish),dest.removeListener("drain",ondrain),dest.removeListener("error",onerror),dest.removeListener("unpipe",onunpipe),src.removeListener("end",onend),src.removeListener("end",unpipe),src.removeListener("data",ondata),cleanedUp=!0,state.awaitDrain&&(!dest._writableState||dest._writableState.needDrain)&&ondrain()}var increasedAwaitDrain=!1;src.on("data",ondata);function ondata(chunk){debug("ondata"),increasedAwaitDrain=!1;var ret=dest.write(chunk);ret===!1&&!increasedAwaitDrain&&((state.pipesCount===1&&state.pipes===dest||state.pipesCount>1&&indexOf(state.pipes,dest)!==-1)&&!cleanedUp&&(debug("false write response, pause",state.awaitDrain),state.awaitDrain++,increasedAwaitDrain=!0),src.pause())}function onerror(er){debug("onerror",er),unpipe(),dest.removeListener("error",onerror),EElistenerCount(dest,"error")===0&&dest.emit("error",er)}prependListener(dest,"error",onerror);function onclose(){dest.removeListener("finish",onfinish),unpipe()}dest.once("close",onclose);function onfinish(){debug("onfinish"),dest.removeListener("close",onclose),unpipe()}dest.once("finish",onfinish);function unpipe(){debug("unpipe"),src.unpipe(dest)}return dest.emit("pipe",src),state.flowing||(debug("pipe resume"),src.resume()),dest};function pipeOnDrain(src){return function(){var state=src._readableState;debug("pipeOnDrain",state.awaitDrain),state.awaitDrain&&state.awaitDrain--,state.awaitDrain===0&&EElistenerCount(src,"data")&&(state.flowing=!0,flow(src))}}Readable.prototype.unpipe=function(dest){var state=this._readableState,unpipeInfo={hasUnpiped:!1};if(state.pipesCount===0)return this;if(state.pipesCount===1)return dest&&dest!==state.pipes?this:(dest||(dest=state.pipes),state.pipes=null,state.pipesCount=0,state.flowing=!1,dest&&dest.emit("unpipe",this,unpipeInfo),this);if(!dest){var dests=state.pipes,len=state.pipesCount;state.pipes=null,state.pipesCount=0,state.flowing=!1;for(var i=0;i<len;i++)dests[i].emit("unpipe",this,{hasUnpiped:!1});return this}var index=indexOf(state.pipes,dest);return index===-1?this:(state.pipes.splice(index,1),state.pipesCount-=1,state.pipesCount===1&&(state.pipes=state.pipes[0]),dest.emit("unpipe",this,unpipeInfo),this)};Readable.prototype.on=function(ev,fn){var res=Stream.prototype.on.call(this,ev,fn);if(ev==="data")this._readableState.flowing!==!1&&this.resume();else if(ev==="readable"){var state=this._readableState;!state.endEmitted&&!state.readableListening&&(state.readableListening=state.needReadable=!0,state.emittedReadable=!1,state.reading?state.length&&emitReadable(this):pna.nextTick(nReadingNextTick,this))}return res};Readable.prototype.addListener=Readable.prototype.on;function nReadingNextTick(self2){debug("readable nexttick read 0"),self2.read(0)}Readable.prototype.resume=function(){var state=this._readableState;return state.flowing||(debug("resume"),state.flowing=!0,resume(this,state)),this};function resume(stream,state){state.resumeScheduled||(state.resumeScheduled=!0,pna.nextTick(resume_,stream,state))}function resume_(stream,state){state.reading||(debug("resume read 0"),stream.read(0)),state.resumeScheduled=!1,state.awaitDrain=0,stream.emit("resume"),flow(stream),state.flowing&&!state.reading&&stream.read(0)}Readable.prototype.pause=function(){return debug("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(debug("pause"),this._readableState.flowing=!1,this.emit("pause")),this};function flow(stream){var state=stream._readableState;for(debug("flow",state.flowing);state.flowing&&stream.read()!==null;);}Readable.prototype.wrap=function(stream){var _this=this,state=this._readableState,paused=!1;stream.on("end",function(){if(debug("wrapped end"),state.decoder&&!state.ended){var chunk=state.decoder.end();chunk&&chunk.length&&_this.push(chunk)}_this.push(null)}),stream.on("data",function(chunk){if(debug("wrapped data"),state.decoder&&(chunk=state.decoder.write(chunk)),!(state.objectMode&&chunk==null)&&!(!state.objectMode&&(!chunk||!chunk.length))){var ret=_this.push(chunk);ret||(paused=!0,stream.pause())}});for(var i in stream)this[i]===void 0&&typeof stream[i]=="function"&&(this[i]=function(method){return function(){return stream[method].apply(stream,arguments)}}(i));for(var n=0;n<kProxyEvents.length;n++)stream.on(kProxyEvents[n],this.emit.bind(this,kProxyEvents[n]));return this._read=function(n2){debug("wrapped _read",n2),paused&&(paused=!1,stream.resume())},this};Object.defineProperty(Readable.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Readable._fromList=fromList;function fromList(n,state){if(state.length===0)return null;var ret;return state.objectMode?ret=state.buffer.shift():!n||n>=state.length?(state.decoder?ret=state.buffer.join(""):state.buffer.length===1?ret=state.buffer.head.data:ret=state.buffer.concat(state.length),state.buffer.clear()):ret=fromListPartial(n,state.buffer,state.decoder),ret}function fromListPartial(n,list,hasStrings){var ret;return n<list.head.data.length?(ret=list.head.data.slice(0,n),list.head.data=list.head.data.slice(n)):n===list.head.data.length?ret=list.shift():ret=hasStrings?copyFromBufferString(n,list):copyFromBuffer(n,list),ret}function copyFromBufferString(n,list){var p=list.head,c=1,ret=p.data;for(n-=ret.length;p=p.next;){var str=p.data,nb=n>str.length?str.length:n;if(nb===str.length?ret+=str:ret+=str.slice(0,n),n-=nb,n===0){nb===str.length?(++c,p.next?list.head=p.next:list.head=list.tail=null):(list.head=p,p.data=str.slice(nb));break}++c}return list.length-=c,ret}function copyFromBuffer(n,list){var ret=Buffer2.allocUnsafe(n),p=list.head,c=1;for(p.data.copy(ret),n-=p.data.length;p=p.next;){var buf=p.data,nb=n>buf.length?buf.length:n;if(buf.copy(ret,ret.length-n,0,nb),n-=nb,n===0){nb===buf.length?(++c,p.next?list.head=p.next:list.head=list.tail=null):(list.head=p,p.data=buf.slice(nb));break}++c}return list.length-=c,ret}function endReadable(stream){var state=stream._readableState;if(state.length>0)throw new Error('"endReadable()" called on non-empty stream');state.endEmitted||(state.ended=!0,pna.nextTick(endReadableNT,state,stream))}function endReadableNT(state,stream){!state.endEmitted&&state.length===0&&(state.endEmitted=!0,stream.readable=!1,stream.emit("end"))}function indexOf(xs,x){for(var i=0,l=xs.length;i<l;i++)if(xs[i]===x)return i;return-1}}});var require_stream_transform=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/lib/_stream_transform.js"(exports,module){"use strict";module.exports=Transform;var Duplex=require_stream_duplex(),util=Object.create(require_util());util.inherits=require_inherits();util.inherits(Transform,Duplex);function afterTransform(er,data){var ts=this._transformState;ts.transforming=!1;var cb=ts.writecb;if(!cb)return this.emit("error",new Error("write callback called multiple times"));ts.writechunk=null,ts.writecb=null,data!=null&&this.push(data),cb(er);var rs=this._readableState;rs.reading=!1,(rs.needReadable||rs.length<rs.highWaterMark)&&this._read(rs.highWaterMark)}function Transform(options){if(!(this instanceof Transform))return new Transform(options);Duplex.call(this,options),this._transformState={afterTransform:afterTransform.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,options&&(typeof options.transform=="function"&&(this._transform=options.transform),typeof options.flush=="function"&&(this._flush=options.flush)),this.on("prefinish",prefinish)}function prefinish(){var _this=this;typeof this._flush=="function"?this._flush(function(er,data){done(_this,er,data)}):done(this,null,null)}Transform.prototype.push=function(chunk,encoding){return this._transformState.needTransform=!1,Duplex.prototype.push.call(this,chunk,encoding)};Transform.prototype._transform=function(chunk,encoding,cb){throw new Error("_transform() is not implemented")};Transform.prototype._write=function(chunk,encoding,cb){var ts=this._transformState;if(ts.writecb=cb,ts.writechunk=chunk,ts.writeencoding=encoding,!ts.transforming){var rs=this._readableState;(ts.needTransform||rs.needReadable||rs.length<rs.highWaterMark)&&this._read(rs.highWaterMark)}};Transform.prototype._read=function(n){var ts=this._transformState;ts.writechunk!==null&&ts.writecb&&!ts.transforming?(ts.transforming=!0,this._transform(ts.writechunk,ts.writeencoding,ts.afterTransform)):ts.needTransform=!0};Transform.prototype._destroy=function(err,cb){var _this2=this;Duplex.prototype._destroy.call(this,err,function(err2){cb(err2),_this2.emit("close")})};function done(stream,er,data){if(er)return stream.emit("error",er);if(data!=null&&stream.push(data),stream._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(stream._transformState.transforming)throw new Error("Calling transform done when still transforming");return stream.push(null)}}});var require_stream_passthrough=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/lib/_stream_passthrough.js"(exports,module){"use strict";module.exports=PassThrough;var Transform=require_stream_transform(),util=Object.create(require_util());util.inherits=require_inherits();util.inherits(PassThrough,Transform);function PassThrough(options){if(!(this instanceof PassThrough))return new PassThrough(options);Transform.call(this,options)}PassThrough.prototype._transform=function(chunk,encoding,cb){cb(null,chunk)}}});var require_readable=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/readable.js"(exports,module){var Stream=__require("stream");process.env.READABLE_STREAM==="disable"&&Stream?(module.exports=Stream,exports=module.exports=Stream.Readable,exports.Readable=Stream.Readable,exports.Writable=Stream.Writable,exports.Duplex=Stream.Duplex,exports.Transform=Stream.Transform,exports.PassThrough=Stream.PassThrough,exports.Stream=Stream):(exports=module.exports=require_stream_readable(),exports.Stream=Stream||exports,exports.Readable=exports,exports.Writable=require_stream_writable(),exports.Duplex=require_stream_duplex(),exports.Transform=require_stream_transform(),exports.PassThrough=require_stream_passthrough())}});var require_duplex=__commonJS({"../../node_modules/.pnpm/readable-stream@2.3.8/node_modules/readable-stream/duplex.js"(exports,module){module.exports=require_readable().Duplex}});var require_safe_buffer2=__commonJS({"../../node_modules/.pnpm/safe-buffer@5.2.1/node_modules/safe-buffer/index.js"(exports,module){var buffer=__require("buffer"),Buffer2=buffer.Buffer;function copyProps(src,dst){for(var key in src)dst[key]=src[key]}Buffer2.from&&Buffer2.alloc&&Buffer2.allocUnsafe&&Buffer2.allocUnsafeSlow?module.exports=buffer:(copyProps(buffer,exports),exports.Buffer=SafeBuffer);function SafeBuffer(arg,encodingOrOffset,length){return Buffer2(arg,encodingOrOffset,length)}SafeBuffer.prototype=Object.create(Buffer2.prototype);copyProps(Buffer2,SafeBuffer);SafeBuffer.from=function(arg,encodingOrOffset,length){if(typeof arg=="number")throw new TypeError("Argument must not be a number");return Buffer2(arg,encodingOrOffset,length)};SafeBuffer.alloc=function(size,fill,encoding){if(typeof size!="number")throw new TypeError("Argument must be a number");var buf=Buffer2(size);return fill!==void 0?typeof encoding=="string"?buf.fill(fill,encoding):buf.fill(fill):buf.fill(0),buf};SafeBuffer.allocUnsafe=function(size){if(typeof size!="number")throw new TypeError("Argument must be a number");return Buffer2(size)};SafeBuffer.allocUnsafeSlow=function(size){if(typeof size!="number")throw new TypeError("Argument must be a number");return buffer.SlowBuffer(size)}}});var require_bl=__commonJS({"../../node_modules/.pnpm/bl@1.2.3/node_modules/bl/bl.js"(exports,module){var DuplexStream=require_duplex(),util=__require("util"),Buffer2=require_safe_buffer2().Buffer;function BufferList(callback){if(!(this instanceof BufferList))return new BufferList(callback);if(this._bufs=[],this.length=0,typeof callback=="function"){this._callback=callback;var piper=function(err){this._callback&&(this._callback(err),this._callback=null)}.bind(this);this.on("pipe",function(src){src.on("error",piper)}),this.on("unpipe",function(src){src.removeListener("error",piper)})}else this.append(callback);DuplexStream.call(this)}util.inherits(BufferList,DuplexStream);BufferList.prototype._offset=function(offset){var tot=0,i=0,_t;if(offset===0)return[0,0];for(;i<this._bufs.length;i++){if(_t=tot+this._bufs[i].length,offset<_t||i==this._bufs.length-1)return[i,offset-tot];tot=_t}};BufferList.prototype.append=function(buf){var i=0;if(Buffer2.isBuffer(buf))this._appendBuffer(buf);else if(Array.isArray(buf))for(;i<buf.length;i++)this.append(buf[i]);else if(buf instanceof BufferList)for(;i<buf._bufs.length;i++)this.append(buf._bufs[i]);else buf!=null&&(typeof buf=="number"&&(buf=buf.toString()),this._appendBuffer(Buffer2.from(buf)));return this};BufferList.prototype._appendBuffer=function(buf){this._bufs.push(buf),this.length+=buf.length};BufferList.prototype._write=function(buf,encoding,callback){this._appendBuffer(buf),typeof callback=="function"&&callback()};BufferList.prototype._read=function(size){if(!this.length)return this.push(null);size=Math.min(size,this.length),this.push(this.slice(0,size)),this.consume(size)};BufferList.prototype.end=function(chunk){DuplexStream.prototype.end.call(this,chunk),this._callback&&(this._callback(null,this.slice()),this._callback=null)};BufferList.prototype.get=function(index){return this.slice(index,index+1)[0]};BufferList.prototype.slice=function(start,end){return typeof start=="number"&&start<0&&(start+=this.length),typeof end=="number"&&end<0&&(end+=this.length),this.copy(null,0,start,end)};BufferList.prototype.copy=function(dst,dstStart,srcStart,srcEnd){if((typeof srcStart!="number"||srcStart<0)&&(srcStart=0),(typeof srcEnd!="number"||srcEnd>this.length)&&(srcEnd=this.length),srcStart>=this.length||srcEnd<=0)return dst||Buffer2.alloc(0);var copy2=!!dst,off=this._offset(srcStart),len=srcEnd-srcStart,bytes=len,bufoff=copy2&&dstStart||0,start=off[1],l,i;if(srcStart===0&&srcEnd==this.length){if(!copy2)return this._bufs.length===1?this._bufs[0]:Buffer2.concat(this._bufs,this.length);for(i=0;i<this._bufs.length;i++)this._bufs[i].copy(dst,bufoff),bufoff+=this._bufs[i].length;return dst}if(bytes<=this._bufs[off[0]].length-start)return copy2?this._bufs[off[0]].copy(dst,dstStart,start,start+bytes):this._bufs[off[0]].slice(start,start+bytes);for(copy2||(dst=Buffer2.allocUnsafe(len)),i=off[0];i<this._bufs.length;i++){if(l=this._bufs[i].length-start,bytes>l)this._bufs[i].copy(dst,bufoff,start),bufoff+=l;else{this._bufs[i].copy(dst,bufoff,start,start+bytes),bufoff+=l;break}bytes-=l,start&&(start=0)}return dst.length>bufoff?dst.slice(0,bufoff):dst};BufferList.prototype.shallowSlice=function(start,end){start=start||0,end=end||this.length,start<0&&(start+=this.length),end<0&&(end+=this.length);var startOffset=this._offset(start),endOffset=this._offset(end),buffers=this._bufs.slice(startOffset[0],endOffset[0]+1);return endOffset[1]==0?buffers.pop():buffers[buffers.length-1]=buffers[buffers.length-1].slice(0,endOffset[1]),startOffset[1]!=0&&(buffers[0]=buffers[0].slice(startOffset[1])),new BufferList(buffers)};BufferList.prototype.toString=function(encoding,start,end){return this.slice(start,end).toString(encoding)};BufferList.prototype.consume=function(bytes){if(bytes=Math.trunc(bytes),Number.isNaN(bytes)||bytes<=0)return this;for(;this._bufs.length;)if(bytes>=this._bufs[0].length)bytes-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift();else{this._bufs[0]=this._bufs[0].slice(bytes),this.length-=bytes;break}return this};BufferList.prototype.duplicate=function(){for(var i=0,copy=new BufferList;i<this._bufs.length;i++)copy.append(this._bufs[i]);return copy};BufferList.prototype.destroy=function(){this._bufs.length=0,this.length=0,this.push(null)};(function(){var methods={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1};for(var m in methods)(function(m2){BufferList.prototype[m2]=function(offset){return this.slice(offset,offset+methods[m2])[m2](0)}})(m)})();module.exports=BufferList}});var require_immutable=__commonJS({"../../node_modules/.pnpm/xtend@4.0.2/node_modules/xtend/immutable.js"(exports,module){module.exports=extend;var hasOwnProperty=Object.prototype.hasOwnProperty;function extend(){for(var target={},i=0;i<arguments.length;i++){var source=arguments[i];for(var key in source)hasOwnProperty.call(source,key)&&(target[key]=source[key])}return target}}});var require_isarray2=__commonJS({"../../node_modules/.pnpm/isarray@2.0.5/node_modules/isarray/index.js"(exports,module){var toString={}.toString;module.exports=Array.isArray||function(arr){return toString.call(arr)=="[object Array]"}}});var require_type=__commonJS({"../../node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/type.js"(exports,module){"use strict";module.exports=TypeError}});var require_es_object_atoms=__commonJS({"../../node_modules/.pnpm/es-object-atoms@1.1.2/node_modules/es-object-atoms/index.js"(exports,module){"use strict";module.exports=Object}});var require_es_errors=__commonJS({"../../node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/index.js"(exports,module){"use strict";module.exports=Error}});var require_eval=__commonJS({"../../node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/eval.js"(exports,module){"use strict";module.exports=EvalError}});var require_range=__commonJS({"../../node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/range.js"(exports,module){"use strict";module.exports=RangeError}});var require_ref=__commonJS({"../../node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/ref.js"(exports,module){"use strict";module.exports=ReferenceError}});var require_syntax=__commonJS({"../../node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/syntax.js"(exports,module){"use strict";module.exports=SyntaxError}});var require_uri=__commonJS({"../../node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/uri.js"(exports,module){"use strict";module.exports=URIError}});var require_abs=__commonJS({"../../node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/abs.js"(exports,module){"use strict";module.exports=Math.abs}});var require_floor=__commonJS({"../../node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/floor.js"(exports,module){"use strict";module.exports=Math.floor}});var require_max=__commonJS({"../../node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/max.js"(exports,module){"use strict";module.exports=Math.max}});var require_min=__commonJS({"../../node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/min.js"(exports,module){"use strict";module.exports=Math.min}});var require_pow=__commonJS({"../../node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/pow.js"(exports,module){"use strict";module.exports=Math.pow}});var require_round=__commonJS({"../../node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/round.js"(exports,module){"use strict";module.exports=Math.round}});var require_isNaN=__commonJS({"../../node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/isNaN.js"(exports,module){"use strict";module.exports=Number.isNaN||function(a){return a!==a}}});var require_sign=__commonJS({"../../node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/sign.js"(exports,module){"use strict";var $isNaN=require_isNaN();module.exports=function(number){return $isNaN(number)||number===0?number:number<0?-1:1}}});var require_gOPD=__commonJS({"../../node_modules/.pnpm/gopd@1.2.0/node_modules/gopd/gOPD.js"(exports,module){"use strict";module.exports=Object.getOwnPropertyDescriptor}});var require_gopd=__commonJS({"../../node_modules/.pnpm/gopd@1.2.0/node_modules/gopd/index.js"(exports,module){"use strict";var $gOPD=require_gOPD();if($gOPD)try{$gOPD([],"length")}catch{$gOPD=null}module.exports=$gOPD}});var require_es_define_property=__commonJS({"../../node_modules/.pnpm/es-define-property@1.0.1/node_modules/es-define-property/index.js"(exports,module){"use strict";var $defineProperty=Object.defineProperty||!1;if($defineProperty)try{$defineProperty({},"a",{value:1})}catch{$defineProperty=!1}module.exports=$defineProperty}});var require_shams=__commonJS({"../../node_modules/.pnpm/has-symbols@1.1.0/node_modules/has-symbols/shams.js"(exports,module){"use strict";module.exports=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var obj={},sym=Symbol("test"),symObj=Object(sym);if(typeof sym=="string"||Object.prototype.toString.call(sym)!=="[object Symbol]"||Object.prototype.toString.call(symObj)!=="[object Symbol]")return!1;var symVal=42;obj[sym]=symVal;for(var _ in obj)return!1;if(typeof Object.keys=="function"&&Object.keys(obj).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(obj).length!==0)return!1;var syms=Object.getOwnPropertySymbols(obj);if(syms.length!==1||syms[0]!==sym||!Object.prototype.propertyIsEnumerable.call(obj,sym))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var descriptor=Object.getOwnPropertyDescriptor(obj,sym);if(descriptor.value!==symVal||descriptor.enumerable!==!0)return!1}return!0}}});var require_has_symbols=__commonJS({"../../node_modules/.pnpm/has-symbols@1.1.0/node_modules/has-symbols/index.js"(exports,module){"use strict";var origSymbol=typeof Symbol<"u"&&Symbol,hasSymbolSham=require_shams();module.exports=function(){return typeof origSymbol!="function"||typeof Symbol!="function"||typeof origSymbol("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:hasSymbolSham()}}});var require_Reflect_getPrototypeOf=__commonJS({"../../node_modules/.pnpm/get-proto@1.0.1/node_modules/get-proto/Reflect.getPrototypeOf.js"(exports,module){"use strict";module.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null}});var require_Object_getPrototypeOf=__commonJS({"../../node_modules/.pnpm/get-proto@1.0.1/node_modules/get-proto/Object.getPrototypeOf.js"(exports,module){"use strict";var $Object=require_es_object_atoms();module.exports=$Object.getPrototypeOf||null}});var require_implementation=__commonJS({"../../node_modules/.pnpm/function-bind@1.1.2/node_modules/function-bind/implementation.js"(exports,module){"use strict";var ERROR_MESSAGE="Function.prototype.bind called on incompatible ",toStr=Object.prototype.toString,max=Math.max,funcType="[object Function]",concatty=function(a,b){for(var arr=[],i=0;i<a.length;i+=1)arr[i]=a[i];for(var j=0;j<b.length;j+=1)arr[j+a.length]=b[j];return arr},slicy=function(arrLike,offset){for(var arr=[],i=offset||0,j=0;i<arrLike.length;i+=1,j+=1)arr[j]=arrLike[i];return arr},joiny=function(arr,joiner){for(var str="",i=0;i<arr.length;i+=1)str+=arr[i],i+1<arr.length&&(str+=joiner);return str};module.exports=function(that){var target=this;if(typeof target!="function"||toStr.apply(target)!==funcType)throw new TypeError(ERROR_MESSAGE+target);for(var args=slicy(arguments,1),bound,binder=function(){if(this instanceof bound){var result=target.apply(this,concatty(args,arguments));return Object(result)===result?result:this}return target.apply(that,concatty(args,arguments))},boundLength=max(0,target.length-args.length),boundArgs=[],i=0;i<boundLength;i++)boundArgs[i]="$"+i;if(bound=Function("binder","return function ("+joiny(boundArgs,",")+"){ return binder.apply(this,arguments); }")(binder),target.prototype){var Empty=function(){};Empty.prototype=target.prototype,bound.prototype=new Empty,Empty.prototype=null}return bound}}});var require_function_bind=__commonJS({"../../node_modules/.pnpm/function-bind@1.1.2/node_modules/function-bind/index.js"(exports,module){"use strict";var implementation=require_implementation();module.exports=Function.prototype.bind||implementation}});var require_functionCall=__commonJS({"../../node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/functionCall.js"(exports,module){"use strict";module.exports=Function.prototype.call}});var require_functionApply=__commonJS({"../../node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/functionApply.js"(exports,module){"use strict";module.exports=Function.prototype.apply}});var require_reflectApply=__commonJS({"../../node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/reflectApply.js"(exports,module){"use strict";module.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply}});var require_actualApply=__commonJS({"../../node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/actualApply.js"(exports,module){"use strict";var bind=require_function_bind(),$apply=require_functionApply(),$call=require_functionCall(),$reflectApply=require_reflectApply();module.exports=$reflectApply||bind.call($call,$apply)}});var require_call_bind_apply_helpers=__commonJS({"../../node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/index.js"(exports,module){"use strict";var bind=require_function_bind(),$TypeError=require_type(),$call=require_functionCall(),$actualApply=require_actualApply();module.exports=function(args){if(args.length<1||typeof args[0]!="function")throw new $TypeError("a function is required");return $actualApply(bind,$call,args)}}});var require_get=__commonJS({"../../node_modules/.pnpm/dunder-proto@1.0.1/node_modules/dunder-proto/get.js"(exports,module){"use strict";var callBind=require_call_bind_apply_helpers(),gOPD=require_gopd(),hasProtoAccessor;try{hasProtoAccessor=[].__proto__===Array.prototype}catch(e){if(!e||typeof e!="object"||!("code"in e)||e.code!=="ERR_PROTO_ACCESS")throw e}var desc=!!hasProtoAccessor&&gOPD&&gOPD(Object.prototype,"__proto__"),$Object=Object,$getPrototypeOf=$Object.getPrototypeOf;module.exports=desc&&typeof desc.get=="function"?callBind([desc.get]):typeof $getPrototypeOf=="function"?function(value){return $getPrototypeOf(value==null?value:$Object(value))}:!1}});var require_get_proto=__commonJS({"../../node_modules/.pnpm/get-proto@1.0.1/node_modules/get-proto/index.js"(exports,module){"use strict";var reflectGetProto=require_Reflect_getPrototypeOf(),originalGetProto=require_Object_getPrototypeOf(),getDunderProto=require_get();module.exports=reflectGetProto?function(O){return reflectGetProto(O)}:originalGetProto?function(O){if(!O||typeof O!="object"&&typeof O!="function")throw new TypeError("getProto: not an object");return originalGetProto(O)}:getDunderProto?function(O){return getDunderProto(O)}:null}});var require_hasown=__commonJS({"../../node_modules/.pnpm/hasown@2.0.4/node_modules/hasown/index.js"(exports,module){"use strict";var call=Function.prototype.call,$hasOwn=Object.prototype.hasOwnProperty,bind=require_function_bind();module.exports=bind.call(call,$hasOwn)}});var require_get_intrinsic=__commonJS({"../../node_modules/.pnpm/get-intrinsic@1.3.0/node_modules/get-intrinsic/index.js"(exports,module){"use strict";var undefined2,$Object=require_es_object_atoms(),$Error=require_es_errors(),$EvalError=require_eval(),$RangeError=require_range(),$ReferenceError=require_ref(),$SyntaxError=require_syntax(),$TypeError=require_type(),$URIError=require_uri(),abs=require_abs(),floor=require_floor(),max=require_max(),min=require_min(),pow=require_pow(),round=require_round(),sign=require_sign(),$Function=Function,getEvalledConstructor=function(expressionSyntax){try{return $Function('"use strict"; return ('+expressionSyntax+").constructor;")()}catch{}},$gOPD=require_gopd(),$defineProperty=require_es_define_property(),throwTypeError=function(){throw new $TypeError},ThrowTypeError=$gOPD?function(){try{return arguments.callee,throwTypeError}catch{try{return $gOPD(arguments,"callee").get}catch{return throwTypeError}}}():throwTypeError,hasSymbols=require_has_symbols()(),getProto=require_get_proto(),$ObjectGPO=require_Object_getPrototypeOf(),$ReflectGPO=require_Reflect_getPrototypeOf(),$apply=require_functionApply(),$call=require_functionCall(),needsEval={},TypedArray=typeof Uint8Array>"u"||!getProto?undefined2:getProto(Uint8Array),INTRINSICS={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?undefined2:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?undefined2:ArrayBuffer,"%ArrayIteratorPrototype%":hasSymbols&&getProto?getProto([][Symbol.iterator]()):undefined2,"%AsyncFromSyncIteratorPrototype%":undefined2,"%AsyncFunction%":needsEval,"%AsyncGenerator%":needsEval,"%AsyncGeneratorFunction%":needsEval,"%AsyncIteratorPrototype%":needsEval,"%Atomics%":typeof Atomics>"u"?undefined2:Atomics,"%BigInt%":typeof BigInt>"u"?undefined2:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?undefined2:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?undefined2:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?undefined2:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":$Error,"%eval%":eval,"%EvalError%":$EvalError,"%Float16Array%":typeof Float16Array>"u"?undefined2:Float16Array,"%Float32Array%":typeof Float32Array>"u"?undefined2:Float32Array,"%Float64Array%":typeof Float64Array>"u"?undefined2:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?undefined2:FinalizationRegistry,"%Function%":$Function,"%GeneratorFunction%":needsEval,"%Int8Array%":typeof Int8Array>"u"?undefined2:Int8Array,"%Int16Array%":typeof Int16Array>"u"?undefined2:Int16Array,"%Int32Array%":typeof Int32Array>"u"?undefined2:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":hasSymbols&&getProto?getProto(getProto([][Symbol.iterator]())):undefined2,"%JSON%":typeof JSON=="object"?JSON:undefined2,"%Map%":typeof Map>"u"?undefined2:Map,"%MapIteratorPrototype%":typeof Map>"u"||!hasSymbols||!getProto?undefined2:getProto(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":$Object,"%Object.getOwnPropertyDescriptor%":$gOPD,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?undefined2:Promise,"%Proxy%":typeof Proxy>"u"?undefined2:Proxy,"%RangeError%":$RangeError,"%ReferenceError%":$ReferenceError,"%Reflect%":typeof Reflect>"u"?undefined2:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?undefined2:Set,"%SetIteratorPrototype%":typeof Set>"u"||!hasSymbols||!getProto?undefined2:getProto(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?undefined2:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":hasSymbols&&getProto?getProto(""[Symbol.iterator]()):undefined2,"%Symbol%":hasSymbols?Symbol:undefined2,"%SyntaxError%":$SyntaxError,"%ThrowTypeError%":ThrowTypeError,"%TypedArray%":TypedArray,"%TypeError%":$TypeError,"%Uint8Array%":typeof Uint8Array>"u"?undefined2:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?undefined2:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?undefined2:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?undefined2:Uint32Array,"%URIError%":$URIError,"%WeakMap%":typeof WeakMap>"u"?undefined2:WeakMap,"%WeakRef%":typeof WeakRef>"u"?undefined2:WeakRef,"%WeakSet%":typeof WeakSet>"u"?undefined2:WeakSet,"%Function.prototype.call%":$call,"%Function.prototype.apply%":$apply,"%Object.defineProperty%":$defineProperty,"%Object.getPrototypeOf%":$ObjectGPO,"%Math.abs%":abs,"%Math.floor%":floor,"%Math.max%":max,"%Math.min%":min,"%Math.pow%":pow,"%Math.round%":round,"%Math.sign%":sign,"%Reflect.getPrototypeOf%":$ReflectGPO};if(getProto)try{null.error}catch(e){errorProto=getProto(getProto(e)),INTRINSICS["%Error.prototype%"]=errorProto}var errorProto,doEval=function doEval2(name){var value;if(name==="%AsyncFunction%")value=getEvalledConstructor("async function () {}");else if(name==="%GeneratorFunction%")value=getEvalledConstructor("function* () {}");else if(name==="%AsyncGeneratorFunction%")value=getEvalledConstructor("async function* () {}");else if(name==="%AsyncGenerator%"){var fn=doEval2("%AsyncGeneratorFunction%");fn&&(value=fn.prototype)}else if(name==="%AsyncIteratorPrototype%"){var gen=doEval2("%AsyncGenerator%");gen&&getProto&&(value=getProto(gen.prototype))}return INTRINSICS[name]=value,value},LEGACY_ALIASES={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},bind=require_function_bind(),hasOwn=require_hasown(),$concat=bind.call($call,Array.prototype.concat),$spliceApply=bind.call($apply,Array.prototype.splice),$replace=bind.call($call,String.prototype.replace),$strSlice=bind.call($call,String.prototype.slice),$exec=bind.call($call,RegExp.prototype.exec),rePropName=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,reEscapeChar=/\\(\\)?/g,stringToPath=function(string){var first=$strSlice(string,0,1),last=$strSlice(string,-1);if(first==="%"&&last!=="%")throw new $SyntaxError("invalid intrinsic syntax, expected closing `%`");if(last==="%"&&first!=="%")throw new $SyntaxError("invalid intrinsic syntax, expected opening `%`");var result=[];return $replace(string,rePropName,function(match,number,quote,subString){result[result.length]=quote?$replace(subString,reEscapeChar,"$1"):number||match}),result},getBaseIntrinsic=function(name,allowMissing){var intrinsicName=name,alias;if(hasOwn(LEGACY_ALIASES,intrinsicName)&&(alias=LEGACY_ALIASES[intrinsicName],intrinsicName="%"+alias[0]+"%"),hasOwn(INTRINSICS,intrinsicName)){var value=INTRINSICS[intrinsicName];if(value===needsEval&&(value=doEval(intrinsicName)),typeof value>"u"&&!allowMissing)throw new $TypeError("intrinsic "+name+" exists, but is not available. Please file an issue!");return{alias,name:intrinsicName,value}}throw new $SyntaxError("intrinsic "+name+" does not exist!")};module.exports=function(name,allowMissing){if(typeof name!="string"||name.length===0)throw new $TypeError("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof allowMissing!="boolean")throw new $TypeError('"allowMissing" argument must be a boolean');if($exec(/^%?[^%]*%?$/,name)===null)throw new $SyntaxError("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var parts=stringToPath(name),intrinsicBaseName=parts.length>0?parts[0]:"",intrinsic=getBaseIntrinsic("%"+intrinsicBaseName+"%",allowMissing),intrinsicRealName=intrinsic.name,value=intrinsic.value,skipFurtherCaching=!1,alias=intrinsic.alias;alias&&(intrinsicBaseName=alias[0],$spliceApply(parts,$concat([0,1],alias)));for(var i=1,isOwn=!0;i<parts.length;i+=1){var part=parts[i],first=$strSlice(part,0,1),last=$strSlice(part,-1);if((first==='"'||first==="'"||first==="`"||last==='"'||last==="'"||last==="`")&&first!==last)throw new $SyntaxError("property names with quotes must have matching quotes");if((part==="constructor"||!isOwn)&&(skipFurtherCaching=!0),intrinsicBaseName+="."+part,intrinsicRealName="%"+intrinsicBaseName+"%",hasOwn(INTRINSICS,intrinsicRealName))value=INTRINSICS[intrinsicRealName];else if(value!=null){if(!(part in value)){if(!allowMissing)throw new $TypeError("base intrinsic for "+name+" exists, but the property is not available.");return}if($gOPD&&i+1>=parts.length){var desc=$gOPD(value,part);isOwn=!!desc,isOwn&&"get"in desc&&!("originalValue"in desc.get)?value=desc.get:value=value[part]}else isOwn=hasOwn(value,part),value=value[part];isOwn&&!skipFurtherCaching&&(INTRINSICS[intrinsicRealName]=value)}}return value}}});var require_call_bound=__commonJS({"../../node_modules/.pnpm/call-bound@1.0.4/node_modules/call-bound/index.js"(exports,module){"use strict";var GetIntrinsic=require_get_intrinsic(),callBindBasic=require_call_bind_apply_helpers(),$indexOf=callBindBasic([GetIntrinsic("%String.prototype.indexOf%")]);module.exports=function(name,allowMissing){var intrinsic=GetIntrinsic(name,!!allowMissing);return typeof intrinsic=="function"&&$indexOf(name,".prototype.")>-1?callBindBasic([intrinsic]):intrinsic}}});var require_is_callable=__commonJS({"../../node_modules/.pnpm/is-callable@1.2.7/node_modules/is-callable/index.js"(exports,module){"use strict";var fnToStr=Function.prototype.toString,reflectApply=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,badArrayLike,isCallableMarker;if(typeof reflectApply=="function"&&typeof Object.defineProperty=="function")try{badArrayLike=Object.defineProperty({},"length",{get:function(){throw isCallableMarker}}),isCallableMarker={},reflectApply(function(){throw 42},null,badArrayLike)}catch(_){_!==isCallableMarker&&(reflectApply=null)}else reflectApply=null;var constructorRegex=/^\s*class\b/,isES6ClassFn=function(value){try{var fnStr=fnToStr.call(value);return constructorRegex.test(fnStr)}catch{return!1}},tryFunctionObject=function(value){try{return isES6ClassFn(value)?!1:(fnToStr.call(value),!0)}catch{return!1}},toStr=Object.prototype.toString,objectClass="[object Object]",fnClass="[object Function]",genClass="[object GeneratorFunction]",ddaClass="[object HTMLAllCollection]",ddaClass2="[object HTML document.all class]",ddaClass3="[object HTMLCollection]",hasToStringTag=typeof Symbol=="function"&&!!Symbol.toStringTag,isIE68=!(0 in[,]),isDDA=function(){return!1};typeof document=="object"&&(all=document.all,toStr.call(all)===toStr.call(document.all)&&(isDDA=function(value){if((isIE68||!value)&&(typeof value>"u"||typeof value=="object"))try{var str=toStr.call(value);return(str===ddaClass||str===ddaClass2||str===ddaClass3||str===objectClass)&&value("")==null}catch{}return!1}));var all;module.exports=reflectApply?function(value){if(isDDA(value))return!0;if(!value||typeof value!="function"&&typeof value!="object")return!1;try{reflectApply(value,null,badArrayLike)}catch(e){if(e!==isCallableMarker)return!1}return!isES6ClassFn(value)&&tryFunctionObject(value)}:function(value){if(isDDA(value))return!0;if(!value||typeof value!="function"&&typeof value!="object")return!1;if(hasToStringTag)return tryFunctionObject(value);if(isES6ClassFn(value))return!1;var strClass=toStr.call(value);return strClass!==fnClass&&strClass!==genClass&&!/^\[object HTML/.test(strClass)?!1:tryFunctionObject(value)}}});var require_for_each=__commonJS({"../../node_modules/.pnpm/for-each@0.3.5/node_modules/for-each/index.js"(exports,module){"use strict";var isCallable=require_is_callable(),toStr=Object.prototype.toString,hasOwnProperty=Object.prototype.hasOwnProperty,forEachArray=function(array,iterator,receiver){for(var i=0,len=array.length;i<len;i++)hasOwnProperty.call(array,i)&&(receiver==null?iterator(array[i],i,array):iterator.call(receiver,array[i],i,array))},forEachString=function(string,iterator,receiver){for(var i=0,len=string.length;i<len;i++)receiver==null?iterator(string.charAt(i),i,string):iterator.call(receiver,string.charAt(i),i,string)},forEachObject=function(object,iterator,receiver){for(var k in object)hasOwnProperty.call(object,k)&&(receiver==null?iterator(object[k],k,object):iterator.call(receiver,object[k],k,object))};function isArray(x){return toStr.call(x)==="[object Array]"}module.exports=function(list,iterator,thisArg){if(!isCallable(iterator))throw new TypeError("iterator must be a function");var receiver;arguments.length>=3&&(receiver=thisArg),isArray(list)?forEachArray(list,iterator,receiver):typeof list=="string"?forEachString(list,iterator,receiver):forEachObject(list,iterator,receiver)}}});var require_possible_typed_array_names=__commonJS({"../../node_modules/.pnpm/possible-typed-array-names@1.1.0/node_modules/possible-typed-array-names/index.js"(exports,module){"use strict";module.exports=["Float16Array","Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]}});var require_available_typed_arrays=__commonJS({"../../node_modules/.pnpm/available-typed-arrays@1.0.7/node_modules/available-typed-arrays/index.js"(exports,module){"use strict";var possibleNames=require_possible_typed_array_names(),g=typeof globalThis>"u"?global:globalThis;module.exports=function(){for(var out=[],i=0;i<possibleNames.length;i++)typeof g[possibleNames[i]]=="function"&&(out[out.length]=possibleNames[i]);return out}}});var require_define_data_property=__commonJS({"../../node_modules/.pnpm/define-data-property@1.1.4/node_modules/define-data-property/index.js"(exports,module){"use strict";var $defineProperty=require_es_define_property(),$SyntaxError=require_syntax(),$TypeError=require_type(),gopd=require_gopd();module.exports=function(obj,property,value){if(!obj||typeof obj!="object"&&typeof obj!="function")throw new $TypeError("`obj` must be an object or a function`");if(typeof property!="string"&&typeof property!="symbol")throw new $TypeError("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new $TypeError("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new $TypeError("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new $TypeError("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new $TypeError("`loose`, if provided, must be a boolean");var nonEnumerable=arguments.length>3?arguments[3]:null,nonWritable=arguments.length>4?arguments[4]:null,nonConfigurable=arguments.length>5?arguments[5]:null,loose=arguments.length>6?arguments[6]:!1,desc=!!gopd&&gopd(obj,property);if($defineProperty)$defineProperty(obj,property,{configurable:nonConfigurable===null&&desc?desc.configurable:!nonConfigurable,enumerable:nonEnumerable===null&&desc?desc.enumerable:!nonEnumerable,value,writable:nonWritable===null&&desc?desc.writable:!nonWritable});else if(loose||!nonEnumerable&&!nonWritable&&!nonConfigurable)obj[property]=value;else throw new $SyntaxError("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}}});var require_has_property_descriptors=__commonJS({"../../node_modules/.pnpm/has-property-descriptors@1.0.2/node_modules/has-property-descriptors/index.js"(exports,module){"use strict";var $defineProperty=require_es_define_property(),hasPropertyDescriptors=function(){return!!$defineProperty};hasPropertyDescriptors.hasArrayLengthDefineBug=function(){if(!$defineProperty)return null;try{return $defineProperty([],"length",{value:1}).length!==1}catch{return!0}};module.exports=hasPropertyDescriptors}});var require_set_function_length=__commonJS({"../../node_modules/.pnpm/set-function-length@1.2.2/node_modules/set-function-length/index.js"(exports,module){"use strict";var GetIntrinsic=require_get_intrinsic(),define=require_define_data_property(),hasDescriptors=require_has_property_descriptors()(),gOPD=require_gopd(),$TypeError=require_type(),$floor=GetIntrinsic("%Math.floor%");module.exports=function(fn,length){if(typeof fn!="function")throw new $TypeError("`fn` is not a function");if(typeof length!="number"||length<0||length>4294967295||$floor(length)!==length)throw new $TypeError("`length` must be a positive 32-bit integer");var loose=arguments.length>2&&!!arguments[2],functionLengthIsConfigurable=!0,functionLengthIsWritable=!0;if("length"in fn&&gOPD){var desc=gOPD(fn,"length");desc&&!desc.configurable&&(functionLengthIsConfigurable=!1),desc&&!desc.writable&&(functionLengthIsWritable=!1)}return(functionLengthIsConfigurable||functionLengthIsWritable||!loose)&&(hasDescriptors?define(fn,"length",length,!0,!0):define(fn,"length",length)),fn}}});var require_applyBind=__commonJS({"../../node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/applyBind.js"(exports,module){"use strict";var bind=require_function_bind(),$apply=require_functionApply(),actualApply=require_actualApply();module.exports=function(){return actualApply(bind,$apply,arguments)}}});var require_call_bind=__commonJS({"../../node_modules/.pnpm/call-bind@1.0.9/node_modules/call-bind/index.js"(exports,module){"use strict";var setFunctionLength=require_set_function_length(),$defineProperty=require_es_define_property(),callBindBasic=require_call_bind_apply_helpers(),applyBind=require_applyBind();module.exports=function(originalFunction){var func=callBindBasic(arguments),adjustedLength=1+originalFunction.length-(arguments.length-1);return setFunctionLength(func,adjustedLength>0?adjustedLength:0,!0)};$defineProperty?$defineProperty(module.exports,"apply",{value:applyBind}):module.exports.apply=applyBind}});var require_shams2=__commonJS({"../../node_modules/.pnpm/has-tostringtag@1.0.2/node_modules/has-tostringtag/shams.js"(exports,module){"use strict";var hasSymbols=require_shams();module.exports=function(){return hasSymbols()&&!!Symbol.toStringTag}}});var require_which_typed_array=__commonJS({"../../node_modules/.pnpm/which-typed-array@1.1.21/node_modules/which-typed-array/index.js"(exports,module){"use strict";var forEach=require_for_each(),availableTypedArrays=require_available_typed_arrays(),callBind=require_call_bind(),callBound=require_call_bound(),gOPD=require_gopd(),getProto=require_get_proto(),$toString=callBound("Object.prototype.toString"),hasToStringTag=require_shams2()(),g=typeof globalThis>"u"?global:globalThis,typedArrays=availableTypedArrays(),$slice=callBound("String.prototype.slice"),$indexOf=callBound("Array.prototype.indexOf",!0)||function(array,value){for(var i=0;i<array.length;i+=1)if(array[i]===value)return i;return-1},cache={__proto__:null};hasToStringTag&&gOPD&&getProto?forEach(typedArrays,function(typedArray){var arr=new g[typedArray];if(Symbol.toStringTag in arr&&getProto){var proto=getProto(arr),descriptor=gOPD(proto,Symbol.toStringTag);if(!descriptor&&proto){var superProto=getProto(proto);descriptor=gOPD(superProto,Symbol.toStringTag)}if(descriptor&&descriptor.get){var bound=callBind(descriptor.get);cache["$"+typedArray]=bound}}}):forEach(typedArrays,function(typedArray){var arr=new g[typedArray],fn=arr.slice||arr.set;if(fn){var bound=callBind(fn);cache["$"+typedArray]=bound}});var tryTypedArrays=function(value){var found=!1;return forEach(cache,function(getter,typedArray){if(!found)try{"$"+getter(value)===typedArray&&(found=$slice(typedArray,1))}catch{}}),found},trySlices=function(value){var found=!1;return forEach(cache,function(getter,name){if(!found)try{getter(value),found=$slice(name,1)}catch{}}),found};module.exports=function(value){if(!value||typeof value!="object")return!1;if(!hasToStringTag){var tag=$slice($toString(value),8,-1);return $indexOf(typedArrays,tag)>-1?tag:tag!=="Object"?!1:trySlices(value)}return gOPD?tryTypedArrays(value):null}}});var require_is_typed_array=__commonJS({"../../node_modules/.pnpm/is-typed-array@1.1.15/node_modules/is-typed-array/index.js"(exports,module){"use strict";var whichTypedArray=require_which_typed_array();module.exports=function(value){return!!whichTypedArray(value)}}});var require_typed_array_buffer=__commonJS({"../../node_modules/.pnpm/typed-array-buffer@1.0.3/node_modules/typed-array-buffer/index.js"(exports,module){"use strict";var $TypeError=require_type(),callBound=require_call_bound(),$typedArrayBuffer=callBound("TypedArray.prototype.buffer",!0),isTypedArray=require_is_typed_array();module.exports=$typedArrayBuffer||function(x){if(!isTypedArray(x))throw new $TypeError("Not a Typed Array");return x.buffer}}});var require_to_buffer=__commonJS({"../../node_modules/.pnpm/to-buffer@1.2.2/node_modules/to-buffer/index.js"(exports,module){"use strict";var Buffer2=require_safe_buffer2().Buffer,isArray=require_isarray2(),typedArrayBuffer=require_typed_array_buffer(),isView=ArrayBuffer.isView||function(obj){try{return typedArrayBuffer(obj),!0}catch{return!1}},useUint8Array=typeof Uint8Array<"u",useArrayBuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",useFromArrayBuffer=useArrayBuffer&&(Buffer2.prototype instanceof Uint8Array||Buffer2.TYPED_ARRAY_SUPPORT);module.exports=function(data,encoding){if(Buffer2.isBuffer(data))return data.constructor&&!("isBuffer"in data)?Buffer2.from(data):data;if(typeof data=="string")return Buffer2.from(data,encoding);if(useArrayBuffer&&isView(data)){if(data.byteLength===0)return Buffer2.alloc(0);if(useFromArrayBuffer){var res=Buffer2.from(data.buffer,data.byteOffset,data.byteLength);if(res.byteLength===data.byteLength)return res}var uint8=data instanceof Uint8Array?data:new Uint8Array(data.buffer,data.byteOffset,data.byteLength),result=Buffer2.from(uint8);if(result.length===data.byteLength)return result}if(useUint8Array&&data instanceof Uint8Array)return Buffer2.from(data);var isArr=isArray(data);if(isArr)for(var i=0;i<data.length;i+=1){var x=data[i];if(typeof x!="number"||x<0||x>255||~~x!==x)throw new RangeError("Array items must be numbers in the range 0-255.")}if(isArr||Buffer2.isBuffer(data)&&data.constructor&&typeof data.constructor.isBuffer=="function"&&data.constructor.isBuffer(data))return Buffer2.from(data);throw new TypeError('The "data" argument must be a string, an Array, a Buffer, a Uint8Array, or a DataView.')}}});var require_buffer_fill=__commonJS({"../../node_modules/.pnpm/buffer-fill@1.0.0/node_modules/buffer-fill/index.js"(exports,module){var hasFullSupport=function(){try{if(!Buffer.isEncoding("latin1"))return!1;var buf=Buffer.alloc?Buffer.alloc(4):new Buffer(4);return buf.fill("ab","ucs2"),buf.toString("hex")==="61006200"}catch{return!1}}();function isSingleByte(val){return val.length===1&&val.charCodeAt(0)<256}function fillWithNumber(buffer,val,start,end){if(start<0||end>buffer.length)throw new RangeError("Out of range index");return start=start>>>0,end=end===void 0?buffer.length:end>>>0,end>start&&buffer.fill(val,start,end),buffer}function fillWithBuffer(buffer,val,start,end){if(start<0||end>buffer.length)throw new RangeError("Out of range index");if(end<=start)return buffer;start=start>>>0,end=end===void 0?buffer.length:end>>>0;for(var pos=start,len=val.length;pos<=end-len;)val.copy(buffer,pos),pos+=len;return pos!==end&&val.copy(buffer,pos,0,end-pos),buffer}function fill(buffer,val,start,end,encoding){if(hasFullSupport)return buffer.fill(val,start,end,encoding);if(typeof val=="number")return fillWithNumber(buffer,val,start,end);if(typeof val=="string"){if(typeof start=="string"?(encoding=start,start=0,end=buffer.length):typeof end=="string"&&(encoding=end,end=buffer.length),encoding!==void 0&&typeof encoding!="string")throw new TypeError("encoding must be a string");if(encoding==="latin1"&&(encoding="binary"),typeof encoding=="string"&&!Buffer.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);if(val==="")return fillWithNumber(buffer,0,start,end);if(isSingleByte(val))return fillWithNumber(buffer,val.charCodeAt(0),start,end);val=new Buffer(val,encoding)}return Buffer.isBuffer(val)?fillWithBuffer(buffer,val,start,end):fillWithNumber(buffer,0,start,end)}module.exports=fill}});var require_buffer_alloc_unsafe=__commonJS({"../../node_modules/.pnpm/buffer-alloc-unsafe@1.1.0/node_modules/buffer-alloc-unsafe/index.js"(exports,module){function allocUnsafe(size){if(typeof size!="number")throw new TypeError('"size" argument must be a number');if(size<0)throw new RangeError('"size" argument must not be negative');return Buffer.allocUnsafe?Buffer.allocUnsafe(size):new Buffer(size)}module.exports=allocUnsafe}});var require_buffer_alloc=__commonJS({"../../node_modules/.pnpm/buffer-alloc@1.2.0/node_modules/buffer-alloc/index.js"(exports,module){var bufferFill=require_buffer_fill(),allocUnsafe=require_buffer_alloc_unsafe();module.exports=function(size,fill,encoding){if(typeof size!="number")throw new TypeError('"size" argument must be a number');if(size<0)throw new RangeError('"size" argument must not be negative');if(Buffer.alloc)return Buffer.alloc(size,fill,encoding);var buffer=allocUnsafe(size);return size===0?buffer:fill===void 0?bufferFill(buffer,0):(typeof encoding!="string"&&(encoding=void 0),bufferFill(buffer,fill,encoding))}}});var require_headers=__commonJS({"../../node_modules/.pnpm/tar-stream@1.6.2/node_modules/tar-stream/headers.js"(exports){var toBuffer=require_to_buffer(),alloc=require_buffer_alloc(),ZEROS="0000000000000000000",SEVENS="7777777777777777777",ZERO_OFFSET="0".charCodeAt(0),USTAR="ustar\x0000",MASK=parseInt("7777",8),clamp=function(index,len,defaultValue){return typeof index!="number"?defaultValue:(index=~~index,index>=len?len:index>=0||(index+=len,index>=0)?index:0)},toType=function(flag){switch(flag){case 0:return"file";case 1:return"link";case 2:return"symlink";case 3:return"character-device";case 4:return"block-device";case 5:return"directory";case 6:return"fifo";case 7:return"contiguous-file";case 72:return"pax-header";case 55:return"pax-global-header";case 27:return"gnu-long-link-path";case 28:case 30:return"gnu-long-path"}return null},toTypeflag=function(flag){switch(flag){case"file":return 0;case"link":return 1;case"symlink":return 2;case"character-device":return 3;case"block-device":return 4;case"directory":return 5;case"fifo":return 6;case"contiguous-file":return 7;case"pax-header":return 72}return 0},indexOf=function(block,num,offset,end){for(;offset<end;offset++)if(block[offset]===num)return offset;return end},cksum=function(block){for(var sum=256,i=0;i<148;i++)sum+=block[i];for(var j=156;j<512;j++)sum+=block[j];return sum},encodeOct=function(val,n){return val=val.toString(8),val.length>n?SEVENS.slice(0,n)+" ":ZEROS.slice(0,n-val.length)+val+" "};function parse256(buf){var positive;if(buf[0]===128)positive=!0;else if(buf[0]===255)positive=!1;else return null;for(var zero=!1,tuple=[],i=buf.length-1;i>0;i--){var byte=buf[i];positive?tuple.push(byte):zero&&byte===0?tuple.push(0):zero?(zero=!1,tuple.push(256-byte)):tuple.push(255-byte)}var sum=0,l=tuple.length;for(i=0;i<l;i++)sum+=tuple[i]*Math.pow(256,i);return positive?sum:-1*sum}var decodeOct=function(val,offset,length){if(val=val.slice(offset,offset+length),offset=0,val[offset]&128)return parse256(val);for(;offset<val.length&&val[offset]===32;)offset++;for(var end=clamp(indexOf(val,32,offset,val.length),val.length,val.length);offset<end&&val[offset]===0;)offset++;return end===offset?0:parseInt(val.slice(offset,end).toString(),8)},decodeStr=function(val,offset,length,encoding){return val.slice(offset,indexOf(val,0,offset,offset+length)).toString(encoding)},addLength=function(str){var len=Buffer.byteLength(str),digits=Math.floor(Math.log(len)/Math.log(10))+1;return len+digits>=Math.pow(10,digits)&&digits++,len+digits+str};exports.decodeLongPath=function(buf,encoding){return decodeStr(buf,0,buf.length,encoding)};exports.encodePax=function(opts){var result="";opts.name&&(result+=addLength(" path="+opts.name+`
|
|
8
|
+
`)),opts.linkname&&(result+=addLength(" linkpath="+opts.linkname+`
|
|
9
|
+
`));var pax=opts.pax;if(pax)for(var key in pax)result+=addLength(" "+key+"="+pax[key]+`
|
|
10
|
+
`);return toBuffer(result)};exports.decodePax=function(buf){for(var result={};buf.length;){for(var i=0;i<buf.length&&buf[i]!==32;)i++;var len=parseInt(buf.slice(0,i).toString(),10);if(!len)return result;var b=buf.slice(i+1,len-1).toString(),keyIndex=b.indexOf("=");if(keyIndex===-1)return result;result[b.slice(0,keyIndex)]=b.slice(keyIndex+1),buf=buf.slice(len)}return result};exports.encode=function(opts){var buf=alloc(512),name=opts.name,prefix="";if(opts.typeflag===5&&name[name.length-1]!=="/"&&(name+="/"),Buffer.byteLength(name)!==name.length)return null;for(;Buffer.byteLength(name)>100;){var i=name.indexOf("/");if(i===-1)return null;prefix+=prefix?"/"+name.slice(0,i):name.slice(0,i),name=name.slice(i+1)}return Buffer.byteLength(name)>100||Buffer.byteLength(prefix)>155||opts.linkname&&Buffer.byteLength(opts.linkname)>100?null:(buf.write(name),buf.write(encodeOct(opts.mode&MASK,6),100),buf.write(encodeOct(opts.uid,6),108),buf.write(encodeOct(opts.gid,6),116),buf.write(encodeOct(opts.size,11),124),buf.write(encodeOct(opts.mtime.getTime()/1e3|0,11),136),buf[156]=ZERO_OFFSET+toTypeflag(opts.type),opts.linkname&&buf.write(opts.linkname,157),buf.write(USTAR,257),opts.uname&&buf.write(opts.uname,265),opts.gname&&buf.write(opts.gname,297),buf.write(encodeOct(opts.devmajor||0,6),329),buf.write(encodeOct(opts.devminor||0,6),337),prefix&&buf.write(prefix,345),buf.write(encodeOct(cksum(buf),6),148),buf)};exports.decode=function(buf,filenameEncoding){var typeflag=buf[156]===0?0:buf[156]-ZERO_OFFSET,name=decodeStr(buf,0,100,filenameEncoding),mode=decodeOct(buf,100,8),uid=decodeOct(buf,108,8),gid=decodeOct(buf,116,8),size=decodeOct(buf,124,12),mtime=decodeOct(buf,136,12),type=toType(typeflag),linkname=buf[157]===0?null:decodeStr(buf,157,100,filenameEncoding),uname=decodeStr(buf,265,32),gname=decodeStr(buf,297,32),devmajor=decodeOct(buf,329,8),devminor=decodeOct(buf,337,8);buf[345]&&(name=decodeStr(buf,345,155,filenameEncoding)+"/"+name),typeflag===0&&name&&name[name.length-1]==="/"&&(typeflag=5);var c=cksum(buf);if(c===8*32)return null;if(c!==decodeOct(buf,148,8))throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?");return{name,mode,uid,gid,size,mtime:new Date(1e3*mtime),type,linkname,uname,gname,devmajor,devminor}}}});var require_extract=__commonJS({"../../node_modules/.pnpm/tar-stream@1.6.2/node_modules/tar-stream/extract.js"(exports,module){var util=__require("util"),bl=require_bl(),xtend=require_immutable(),headers=require_headers(),Writable=require_readable().Writable,PassThrough=require_readable().PassThrough,noop=function(){},overflow=function(size){return size&=511,size&&512-size},emptyStream=function(self2,offset){var s=new Source(self2,offset);return s.end(),s},mixinPax=function(header,pax){return pax.path&&(header.name=pax.path),pax.linkpath&&(header.linkname=pax.linkpath),pax.size&&(header.size=parseInt(pax.size,10)),header.pax=pax,header},Source=function(self2,offset){this._parent=self2,this.offset=offset,PassThrough.call(this)};util.inherits(Source,PassThrough);Source.prototype.destroy=function(err){this._parent.destroy(err)};var Extract=function(opts){if(!(this instanceof Extract))return new Extract(opts);Writable.call(this,opts),opts=opts||{},this._offset=0,this._buffer=bl(),this._missing=0,this._partial=!1,this._onparse=noop,this._header=null,this._stream=null,this._overflow=null,this._cb=null,this._locked=!1,this._destroyed=!1,this._pax=null,this._paxGlobal=null,this._gnuLongPath=null,this._gnuLongLinkPath=null;var self2=this,b=self2._buffer,oncontinue=function(){self2._continue()},onunlock=function(err){if(self2._locked=!1,err)return self2.destroy(err);self2._stream||oncontinue()},onstreamend=function(){self2._stream=null;var drain=overflow(self2._header.size);drain?self2._parse(drain,ondrain):self2._parse(512,onheader),self2._locked||oncontinue()},ondrain=function(){self2._buffer.consume(overflow(self2._header.size)),self2._parse(512,onheader),oncontinue()},onpaxglobalheader=function(){var size=self2._header.size;self2._paxGlobal=headers.decodePax(b.slice(0,size)),b.consume(size),onstreamend()},onpaxheader=function(){var size=self2._header.size;self2._pax=headers.decodePax(b.slice(0,size)),self2._paxGlobal&&(self2._pax=xtend(self2._paxGlobal,self2._pax)),b.consume(size),onstreamend()},ongnulongpath=function(){var size=self2._header.size;this._gnuLongPath=headers.decodeLongPath(b.slice(0,size),opts.filenameEncoding),b.consume(size),onstreamend()},ongnulonglinkpath=function(){var size=self2._header.size;this._gnuLongLinkPath=headers.decodeLongPath(b.slice(0,size),opts.filenameEncoding),b.consume(size),onstreamend()},onheader=function(){var offset=self2._offset,header;try{header=self2._header=headers.decode(b.slice(0,512),opts.filenameEncoding)}catch(err){self2.emit("error",err)}if(b.consume(512),!header){self2._parse(512,onheader),oncontinue();return}if(header.type==="gnu-long-path"){self2._parse(header.size,ongnulongpath),oncontinue();return}if(header.type==="gnu-long-link-path"){self2._parse(header.size,ongnulonglinkpath),oncontinue();return}if(header.type==="pax-global-header"){self2._parse(header.size,onpaxglobalheader),oncontinue();return}if(header.type==="pax-header"){self2._parse(header.size,onpaxheader),oncontinue();return}if(self2._gnuLongPath&&(header.name=self2._gnuLongPath,self2._gnuLongPath=null),self2._gnuLongLinkPath&&(header.linkname=self2._gnuLongLinkPath,self2._gnuLongLinkPath=null),self2._pax&&(self2._header=header=mixinPax(header,self2._pax),self2._pax=null),self2._locked=!0,!header.size||header.type==="directory"){self2._parse(512,onheader),self2.emit("entry",header,emptyStream(self2,offset),onunlock);return}self2._stream=new Source(self2,offset),self2.emit("entry",header,self2._stream,onunlock),self2._parse(header.size,onstreamend),oncontinue()};this._onheader=onheader,this._parse(512,onheader)};util.inherits(Extract,Writable);Extract.prototype.destroy=function(err){this._destroyed||(this._destroyed=!0,err&&this.emit("error",err),this.emit("close"),this._stream&&this._stream.emit("close"))};Extract.prototype._parse=function(size,onparse){this._destroyed||(this._offset+=size,this._missing=size,onparse===this._onheader&&(this._partial=!1),this._onparse=onparse)};Extract.prototype._continue=function(){if(!this._destroyed){var cb=this._cb;this._cb=noop,this._overflow?this._write(this._overflow,void 0,cb):cb()}};Extract.prototype._write=function(data,enc,cb){if(!this._destroyed){var s=this._stream,b=this._buffer,missing=this._missing;if(data.length&&(this._partial=!0),data.length<missing)return this._missing-=data.length,this._overflow=null,s?s.write(data,cb):(b.append(data),cb());this._cb=cb,this._missing=0;var overflow2=null;data.length>missing&&(overflow2=data.slice(missing),data=data.slice(0,missing)),s?s.end(data):b.append(data),this._overflow=overflow2,this._onparse()}};Extract.prototype._final=function(cb){if(this._partial)return this.destroy(new Error("Unexpected end of data"));cb()};module.exports=Extract}});var require_fs_constants=__commonJS({"../../node_modules/.pnpm/fs-constants@1.0.0/node_modules/fs-constants/index.js"(exports,module){module.exports=__require("fs").constants||__require("constants")}});var require_pack=__commonJS({"../../node_modules/.pnpm/tar-stream@1.6.2/node_modules/tar-stream/pack.js"(exports,module){var constants=require_fs_constants(),eos=require_end_of_stream(),util=__require("util"),alloc=require_buffer_alloc(),toBuffer=require_to_buffer(),Readable=require_readable().Readable,Writable=require_readable().Writable,StringDecoder=__require("string_decoder").StringDecoder,headers=require_headers(),DMODE=parseInt("755",8),FMODE=parseInt("644",8),END_OF_TAR=alloc(1024),noop=function(){},overflow=function(self2,size){size&=511,size&&self2.push(END_OF_TAR.slice(0,512-size))};function modeToType(mode){switch(mode&constants.S_IFMT){case constants.S_IFBLK:return"block-device";case constants.S_IFCHR:return"character-device";case constants.S_IFDIR:return"directory";case constants.S_IFIFO:return"fifo";case constants.S_IFLNK:return"symlink"}return"file"}var Sink=function(to){Writable.call(this),this.written=0,this._to=to,this._destroyed=!1};util.inherits(Sink,Writable);Sink.prototype._write=function(data,enc,cb){if(this.written+=data.length,this._to.push(data))return cb();this._to._drain=cb};Sink.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var LinkSink=function(){Writable.call(this),this.linkname="",this._decoder=new StringDecoder("utf-8"),this._destroyed=!1};util.inherits(LinkSink,Writable);LinkSink.prototype._write=function(data,enc,cb){this.linkname+=this._decoder.write(data),cb()};LinkSink.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var Void=function(){Writable.call(this),this._destroyed=!1};util.inherits(Void,Writable);Void.prototype._write=function(data,enc,cb){cb(new Error("No body allowed for this entry"))};Void.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var Pack=function(opts){if(!(this instanceof Pack))return new Pack(opts);Readable.call(this,opts),this._drain=noop,this._finalized=!1,this._finalizing=!1,this._destroyed=!1,this._stream=null};util.inherits(Pack,Readable);Pack.prototype.entry=function(header,buffer,callback){if(this._stream)throw new Error("already piping an entry");if(!(this._finalized||this._destroyed)){typeof buffer=="function"&&(callback=buffer,buffer=null),callback||(callback=noop);var self2=this;if((!header.size||header.type==="symlink")&&(header.size=0),header.type||(header.type=modeToType(header.mode)),header.mode||(header.mode=header.type==="directory"?DMODE:FMODE),header.uid||(header.uid=0),header.gid||(header.gid=0),header.mtime||(header.mtime=new Date),typeof buffer=="string"&&(buffer=toBuffer(buffer)),Buffer.isBuffer(buffer))return header.size=buffer.length,this._encode(header),this.push(buffer),overflow(self2,header.size),process.nextTick(callback),new Void;if(header.type==="symlink"&&!header.linkname){var linkSink=new LinkSink;return eos(linkSink,function(err){if(err)return self2.destroy(),callback(err);header.linkname=linkSink.linkname,self2._encode(header),callback()}),linkSink}if(this._encode(header),header.type!=="file"&&header.type!=="contiguous-file")return process.nextTick(callback),new Void;var sink=new Sink(this);return this._stream=sink,eos(sink,function(err){if(self2._stream=null,err)return self2.destroy(),callback(err);if(sink.written!==header.size)return self2.destroy(),callback(new Error("size mismatch"));overflow(self2,header.size),self2._finalizing&&self2.finalize(),callback()}),sink}};Pack.prototype.finalize=function(){if(this._stream){this._finalizing=!0;return}this._finalized||(this._finalized=!0,this.push(END_OF_TAR),this.push(null))};Pack.prototype.destroy=function(err){this._destroyed||(this._destroyed=!0,err&&this.emit("error",err),this.emit("close"),this._stream&&this._stream.destroy&&this._stream.destroy())};Pack.prototype._encode=function(header){if(!header.pax){var buf=headers.encode(header);if(buf){this.push(buf);return}}this._encodePax(header)};Pack.prototype._encodePax=function(header){var paxHeader=headers.encodePax({name:header.name,linkname:header.linkname,pax:header.pax}),newHeader={name:"PaxHeader",mode:header.mode,uid:header.uid,gid:header.gid,size:paxHeader.length,mtime:header.mtime,type:"pax-header",linkname:header.linkname&&"PaxHeader",uname:header.uname,gname:header.gname,devmajor:header.devmajor,devminor:header.devminor};this.push(headers.encode(newHeader)),this.push(paxHeader),overflow(this,paxHeader.length),newHeader.size=header.size,newHeader.type=header.type,this.push(headers.encode(newHeader))};Pack.prototype._read=function(n){var drain=this._drain;this._drain=noop,drain()};module.exports=Pack}});var require_tar_stream=__commonJS({"../../node_modules/.pnpm/tar-stream@1.6.2/node_modules/tar-stream/index.js"(exports){exports.extract=require_extract();exports.pack=require_pack()}});var require_pump=__commonJS({"../../node_modules/.pnpm/pump@1.0.3/node_modules/pump/index.js"(exports,module){var once=require_once(),eos=require_end_of_stream(),fs=__require("fs"),noop=function(){},isFn=function(fn){return typeof fn=="function"},isFS=function(stream){return fs?(stream instanceof(fs.ReadStream||noop)||stream instanceof(fs.WriteStream||noop))&&isFn(stream.close):!1},isRequest=function(stream){return stream.setHeader&&isFn(stream.abort)},destroyer=function(stream,reading,writing,callback){callback=once(callback);var closed=!1;stream.on("close",function(){closed=!0}),eos(stream,{readable:reading,writable:writing},function(err){if(err)return callback(err);closed=!0,callback()});var destroyed=!1;return function(err){if(!closed&&!destroyed){if(destroyed=!0,isFS(stream))return stream.close(noop);if(isRequest(stream))return stream.abort();if(isFn(stream.destroy))return stream.destroy();callback(err||new Error("stream was destroyed"))}}},call=function(fn){fn()},pipe=function(from,to){return from.pipe(to)},pump=function(){var streams=Array.prototype.slice.call(arguments),callback=isFn(streams[streams.length-1]||noop)&&streams.pop()||noop;if(Array.isArray(streams[0])&&(streams=streams[0]),streams.length<2)throw new Error("pump requires two streams per minimum");var error,destroys=streams.map(function(stream,i){var reading=i<streams.length-1,writing=i>0;return destroyer(stream,reading,writing,function(err){error||(error=err),err&&destroys.forEach(call),!reading&&(destroys.forEach(call),callback(error))})});return streams.reduce(pipe)};module.exports=pump}});var require_mkdirp=__commonJS({"../../node_modules/.pnpm/mkdirp@0.5.6/node_modules/mkdirp/index.js"(exports,module){var path=__require("path"),fs=__require("fs"),_0777=parseInt("0777",8);module.exports=mkdirP.mkdirp=mkdirP.mkdirP=mkdirP;function mkdirP(p,opts,f,made){typeof opts=="function"?(f=opts,opts={}):(!opts||typeof opts!="object")&&(opts={mode:opts});var mode=opts.mode,xfs=opts.fs||fs;mode===void 0&&(mode=_0777),made||(made=null);var cb=f||function(){};p=path.resolve(p),xfs.mkdir(p,mode,function(er){if(!er)return made=made||p,cb(null,made);switch(er.code){case"ENOENT":if(path.dirname(p)===p)return cb(er);mkdirP(path.dirname(p),opts,function(er2,made2){er2?cb(er2,made2):mkdirP(p,opts,cb,made2)});break;default:xfs.stat(p,function(er2,stat){er2||!stat.isDirectory()?cb(er,made):cb(null,made)});break}})}mkdirP.sync=function sync(p,opts,made){(!opts||typeof opts!="object")&&(opts={mode:opts});var mode=opts.mode,xfs=opts.fs||fs;mode===void 0&&(mode=_0777),made||(made=null),p=path.resolve(p);try{xfs.mkdirSync(p,mode),made=made||p}catch(err0){switch(err0.code){case"ENOENT":made=sync(path.dirname(p),opts,made),sync(p,opts,made);break;default:var stat;try{stat=xfs.statSync(p)}catch{throw err0}if(!stat.isDirectory())throw err0;break}}return made}}});export{require_chownr,require_tar_stream,require_pump,require_mkdirp};
|
|
11
|
+
/*! Bundled license information:
|
|
12
|
+
|
|
13
|
+
safe-buffer/index.js:
|
|
14
|
+
(*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> *)
|
|
15
|
+
*/
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from 'node:module';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __dirname_ } from 'node:path';
|
|
4
|
+
const require = __createRequire(import.meta.url);
|
|
5
|
+
const __filename = __fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = __dirname_(__filename);
|
|
7
|
+
function baseQuery(scope){return new URLSearchParams({teamId:scope.teamId,projectId:scope.projectId})}function repositoriesPath(scope,opts={}){let query=baseQuery(scope);return opts.limit!==void 0&&query.set("limit",String(opts.limit)),opts.cursor&&query.set("cursor",opts.cursor),`/v1/vcr/repository?${query.toString()}`}function repositoryPath(scope,idOrName){return`/v1/vcr/repository/${encodeURIComponent(idOrName)}?${baseQuery(scope).toString()}`}function repositoryImagesPath(scope,idOrName,opts={}){let query=baseQuery(scope);return opts.limit!==void 0&&query.set("limit",String(opts.limit)),opts.cursor&&query.set("cursor",opts.cursor),opts.untagged&&query.set("untagged","true"),`/v1/vcr/repository/${encodeURIComponent(idOrName)}/images?${query.toString()}`}function imagePath(scope,idOrName,imageId){return`/v1/vcr/repository/${encodeURIComponent(idOrName)}/images/${encodeURIComponent(imageId)}?${baseQuery(scope).toString()}`}function repositoryTagsPath(scope,idOrName,opts={}){let query=baseQuery(scope);return opts.limit!==void 0&&query.set("limit",String(opts.limit)),opts.cursor&&query.set("cursor",opts.cursor),opts.sortBy&&query.set("sortBy",opts.sortBy),opts.sortOrder&&query.set("sortOrder",opts.sortOrder),`/v1/vcr/repository/${encodeURIComponent(idOrName)}/tags?${query.toString()}`}function repositoryTagPath(scope,idOrName,tag){return`/v1/vcr/repository/${encodeURIComponent(idOrName)}/tags/${encodeURIComponent(tag)}?${baseQuery(scope).toString()}`}function repositoryPermissionsPath(scope,idOrName,opts={}){let query=baseQuery(scope);return opts.limit!==void 0&&query.set("limit",String(opts.limit)),opts.cursor&&query.set("cursor",opts.cursor),`/v1/vcr/repository/${encodeURIComponent(idOrName)}/permissions?${query.toString()}`}function repositoryPermissionsClearPath(scope,idOrName){return`/v1/vcr/repository/${encodeURIComponent(idOrName)}/permissions/all?${baseQuery(scope).toString()}`}export{repositoriesPath,repositoryPath,repositoryImagesPath,imagePath,repositoryTagsPath,repositoryTagPath,repositoryPermissionsPath,repositoryPermissionsClearPath};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from 'node:module';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __dirname_ } from 'node:path';
|
|
4
|
+
const require = __createRequire(import.meta.url);
|
|
5
|
+
const __filename = __fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = __dirname_(__filename);
|
|
7
|
+
import{linkCommand}from"./chunk-IUXSJWL3.js";import{quoteArg,teamCache}from"./chunk-F53OKXYI.js";import{arg_common_default,getFlagsSpecification,getGlobalFlagsFromArgs,normalizeFlagName,stripSensitiveAuthArgs,suggestionFlagTakesSeparateValue}from"./chunk-AWMQGOS2.js";import{LinkRequiredError,ProjectNotFound,isAPIError}from"./chunk-6VH56CX2.js";import{getCommandName,packageName}from"./chunk-JESNVRVR.js";import{recordCliError}from"./chunk-XP3FT56R.js";import{require_dist}from"./chunk-RM3ZDRYE.js";import{pkg_default}from"./chunk-OO572JUC.js";import{__toESM}from"./chunk-BZENIQ7N.js";var AGENT_STATUS={ERROR:"error",ACTION_REQUIRED:"action_required",OK:"ok"},AGENT_REASON={MISSING_ARGUMENTS:"missing_arguments",INVALID_ARGUMENTS:"invalid_arguments",CONFIRMATION_REQUIRED:"confirmation_required",INTERACTIVE_CONFIRMATION_REQUIRED:"interactive_confirmation_required",LOGIN_REQUIRED:"login_required",PROJECT_SETTINGS_REQUIRED:"project_settings_required",NOT_LINKED:"not_linked",NOT_FOUND:"not_found",PROJECT_NOT_FOUND:"project_not_found",MISSING_SCOPE:"missing_scope",SCOPE_NOT_ACCESSIBLE:"scope_not_accessible",AGENT_CANNOT_SWITCH:"agent_cannot_switch",API_ERROR:"api_error",STDIN_ERROR:"stdin_error",RATE_LIMITED:"rate_limited",NETWORK_ERROR:"network_error",UNKNOWN_COMMAND:"unknown_command",SEGMENT_IN_USE:"segment_in_use",ENTITY_IN_USE:"entity_in_use",MISSING_REQUIREMENTS:"missing_requirements",MISSING_NAME:"missing_name",MISSING_VALUE:"missing_value",MISSING_ENVIRONMENT:"missing_environment",ENV_NOT_FOUND:"env_not_found",MULTIPLE_ENVS:"multiple_envs",ENV_FILE_EXISTS:"env_file_exists",GIT_BRANCH_REQUIRED:"git_branch_required",ENV_KEY_SENSITIVE:"env_key_sensitive",AMBIGUOUS_ROUTE:"ambiguous_route",ROUTE_CREATE_FAILED:"route_create_failed",ROUTE_GENERATION_FAILED:"route_generation_failed",DOMAIN_NOT_FOUND:"domain_not_found",PRICE_CHANGED:"price_changed",CONFLICT:"conflict",DOMAIN_NOT_AVAILABLE:"domain_not_available",TLD_NOT_SUPPORTED:"tld_not_supported",PAYMENT_FAILED:"payment_failed",UNKNOWN_OUTCOME:"unknown_outcome",DNS_RECORD_NOT_FOUND:"dns_record_not_found",INCOMPLETE_RECORD:"incomplete_record",PERMISSION_DENIED:"permission_denied",INVALID_PORT:"invalid_port",INVALID_DNS_TYPE:"invalid_dns_type",DNS_ADD_FAILED:"dns_add_failed",INVALID_DOMAIN:"invalid_domain",CONFIGURED_CORRECTLY:"configured_correctly",VERIFICATION_NEEDED:"verification_needed",INVALID_CONFIGURATION:"invalid_configuration",DNS_CHANGE_REQUIRED:"dns_change_required",DNS_CHANGE_RECOMMENDED:"dns_change_recommended",DNSSEC_NEEDS_TO_BE_DISABLED:"dnssec_needs_to_be_disabled",PROJECT_ATTACHMENT_RECOMMENDED:"project_attachment_recommended",PROJECT_DOMAIN_MISSING:"project_domain_missing",INTEGRATION_TERMS_ACCEPTANCE_REQUIRED:"integration_terms_acceptance_required",INTEGRATION_SETUP_REQUIRED:"integration_setup_required",HAS_RESOURCES:"has_resources",INTEGRATION_SANDBOX_CLAIM_REQUIRED:"integration_sandbox_claim_required",CLASSIC_TOKEN_REQUIRED:"classic_token_required",TOKEN_USER_SCOPE_REQUIRED:"token_user_scope_required",MISSING_URL:"missing_url",MISSING_EVENTS:"missing_events",INVALID_URL:"invalid_url",INVALID_EVENT:"invalid_event",INVALID_BUDGET:"invalid_budget",INVALID_REFRESH_PERIOD:"invalid_refresh_period",INVALID_EXPIRATION:"invalid_expiration",INVALID_ALERT_THRESHOLDS:"invalid_alert_thresholds",REQUIRES_CONSENT:"requires_consent",MISSING_ISSUER_ID:"missing_issuer_id",MISSING_KEY:"missing_key",MISSING_KEY_ID:"missing_key_id",MISSING_PROJECT:"missing_project",ISSUER_NOT_FOUND:"issuer_not_found",ISSUER_MANAGED:"issuer_managed",ISSUER_REQUIRES_IMPORTED_KEY:"issuer_requires_imported_key",ISSUER_REQUIRES_GENERATED_KEY:"issuer_requires_generated_key",KEY_NOT_REVOKING:"key_not_revoking",NO_CHANGES_REQUESTED:"no_changes_requested",GIT_REPOSITORY_REQUIRED:"git_repository_required",CI_RUN_NOT_FOUND:"ci_run_not_found",CI_RUN_IN_PROGRESS:"ci_run_in_progress",CI_RUN_NOT_RETRYABLE:"ci_run_not_retryable",SCHEDULES_NOT_ENABLED:"schedules_not_enabled",SCHEDULE_ALREADY_EXISTS:"schedule_already_exists",SCHEDULE_SINGLE_AT_PASSED:"schedule_single_at_passed",SCHEDULE_ALREADY_ACTIVE:"schedule_already_active",STATIC_SCHEDULE:"static_schedule",INVALID_CRON_EXPRESSION:"invalid_cron_expression",INVALID_JITTER:"invalid_jitter",JITTER_EXCEEDS_CADENCE:"jitter_exceeds_cadence",SINGLE_AT_TOO_SOON:"single_at_too_soon",SCHEDULE_PAYLOAD_TOO_LARGE:"payload_too_large",SCHEDULE_PAYLOAD_STORE_FAILED:"payload_store_failed",SCHEDULE_SERVICE_UNAVAILABLE:"service_unavailable",SCHEDULE_SERVICE_ERROR:"service_error",REDIRECT_NOT_FOUND:"redirect_not_found",VERSION_NOT_FOUND:"version_not_found",VERSION_ALREADY_LIVE:"version_already_live",VERSION_IS_STAGING:"version_is_staging",PLAN_UPGRADE_REQUIRED:"plan_upgrade_required",PLAN_LIMIT:"plan_limit",NOT_TEAM_MEMBER:"not_team_member",INVALID_ROLE_COMBINATION:"invalid_role_combination",TARGET_CONFLICT:"target_conflict",DEPRECATED:"deprecated",LIMIT_CLAMPED:"limit_clamped",METRICS_UNAVAILABLE:"metrics_unavailable",STREAM_GAP:"stream_gap",INCOMPLETE_RESULTS:"incomplete_results"},USAGE_ERROR_REASONS=new Set(["invalid_arguments","missing_arguments","unknown_command","missing_command","invalid_environment","invalid_type","missing_id","missing_value","missing_name","missing_flags","missing_clients","invalid_clients","conflicting_type_flags","missing_environment","invalid_slug","invalid_name","invalid_alert_thresholds","invalid_budget","invalid_dns_type","invalid_event","invalid_expiration","invalid_port","invalid_refresh_period","invalid_role_combination","invalid_url","missing_events","missing_issuer_id","missing_key_id","missing_key","missing_url"]);function getExitCodeForReason(reason){return reason!==void 0&&USAGE_ERROR_REASONS.has(reason)?2:1}var AGENT_ACTION={MISSING_ARGUMENTS:"missing_arguments",CONFIRMATION_REQUIRED:"confirmation_required",LOGIN_REQUIRED:"login_required"};var import_error_utils=__toESM(require_dist(),1);var OBSERVABILITY_PLUS_PURCHASE_COMMAND="buy addon observability-plus",PRIORITY_PROJECT_ENABLE_COMMAND="project priority enable",BUY_PRO_COMMAND="buy pro",PROJECT_ENABLE_COMMAND="project observability enable";function mentionsObservabilityPlus(message){return/observability\s+plus/i.test(message)}function mentionsPriorityProject(message){return/priority\s+project/i.test(message)||/priority\s+tier/i.test(message)}function observabilityPlusDenialReason(error){if(!error||typeof error!="object"||!("meta"in error))return;let meta=error.meta;if(meta&&typeof meta=="object"&&"reason"in meta&&typeof meta.reason=="string")return meta.reason}function observabilityPlusPurchaseHint(){return`Subscribe with ${getCommandName(OBSERVABILITY_PLUS_PURCHASE_COMMAND)}.`}function isHobbyLikePlan(plan){return plan==="hobby"||plan==="oss"}function isProOrEnterprisePlan(plan){return plan==="pro"||plan==="enterprise"}function currentTeamPlan(client){let id=client?.config?.currentTeam;if(id)return teamCache.get(id)?.billing?.plan}function planForTeam(idOrSlug){return teamCache.get(idOrSlug)?.billing?.plan}function buyProFix(hint){return{command:BUY_PRO_COMMAND,hint:hint??`Upgrade with ${getCommandName(BUY_PRO_COMMAND)}.`,when:"a person has approved upgrading the plan"}}function observabilityPlusPurchaseFix(){return{command:OBSERVABILITY_PLUS_PURCHASE_COMMAND,hint:observabilityPlusPurchaseHint(),when:"a person has approved buying the add-on"}}function inferDenialReason(message){if(/(?:disabled|switched off|re-enable)/i.test(message))return"subscription_disabled";if(/excluded from it|include the project/i.test(message))return"project_excluded";if(/upgrade your plan/i.test(message)&&/pro and enterprise/i.test(message))return"plan_upgrade_required";if(/(?:quota|usage limit|query limit)/i.test(message))return"quota"}function plusNeedsPlanUpgradeHint(){return`Observability Plus is available on Pro and Enterprise. Upgrade with ${getCommandName(BUY_PRO_COMMAND)}. The add-on cannot be purchased on Hobby.`}function observabilityPlusRecovery(message,denialReason,plan){if(mentionsObservabilityPlus(message))switch(denialReason??inferDenialReason(message)){case"subscription_disabled":return{hint:"Observability Plus is disabled. Ask a team owner to enable it for the intended team or project, then retry. A new subscription may not be needed."};case"project_excluded":return{command:PROJECT_ENABLE_COMMAND,excludeFlags:["--non-interactive","--project","--yes"],hint:`Observability Plus is on for the team, but this project is excluded. Enable it with ${getCommandName(PROJECT_ENABLE_COMMAND)}. A new subscription is not needed.`,preserveProject:!1,when:"a person has approved enabling Observability Plus for this project"};case"plan_upgrade_required":return buyProFix(plusNeedsPlanUpgradeHint());case"quota":return{hint:"The usage limit was reached. Ask a team owner to review the limit before retrying."};default:return isHobbyLikePlan(plan)?buyProFix(plusNeedsPlanUpgradeHint()):{...observabilityPlusPurchaseFix(),hint:`Check whether Observability Plus is disabled for this project or the team needs a subscription. Enable it if already subscribed. Otherwise, ${observabilityPlusPurchaseHint()}`,when:"the team has no subscription and a person has approved buying the add-on"}}}function priorityProjectRecovery(message,plan){if(mentionsPriorityProject(message))return isHobbyLikePlan(plan)?buyProFix(`Priority Projects are only available on Pro or Enterprise team plans. Upgrade with ${getCommandName(BUY_PRO_COMMAND)}, then run ${getCommandName(PRIORITY_PROJECT_ENABLE_COMMAND)}.`):{command:PRIORITY_PROJECT_ENABLE_COMMAND,excludeFlags:["--non-interactive","--project","--yes"],hint:getCommandName(PRIORITY_PROJECT_ENABLE_COMMAND),preserveProject:!1,when:"user runs this command in an interactive terminal"}}function observabilityPlanRecovery(message,denialReason,plan){return priorityProjectRecovery(message,plan)??observabilityPlusRecovery(message,denialReason,plan)}var PROJECT_POSITIONAL_COMMANDS=new Set([PRIORITY_PROJECT_ENABLE_COMMAND,PROJECT_ENABLE_COMMAND]);function currentTeamScope(client){let id=client?.config?.currentTeam;if(id)return teamCache.get(id)?.slug??id}function targetRecovery(fix,target){if(!fix)return;let targeted=command=>{let out=command;return target.projectName&&PROJECT_POSITIONAL_COMMANDS.has(command)&&(out+=` ${quoteArg(target.projectName)}`),target.scope&&(out+=` --scope ${quoteArg(target.scope)}`),out},hint=fix.hint;for(let command of[BUY_PRO_COMMAND,OBSERVABILITY_PLUS_PURCHASE_COMMAND,PRIORITY_PROJECT_ENABLE_COMMAND,PROJECT_ENABLE_COMMAND])hint=hint.split(getCommandName(command)).join(getCommandName(targeted(command)));if(!fix.command)return{...fix,hint};let excludeFlags=new Set(fix.excludeFlags??[]),preserveProject=fix.preserveProject;return target.projectName&&PROJECT_POSITIONAL_COMMANDS.has(fix.command)&&(excludeFlags.add("--project"),preserveProject=!1),fix.command===BUY_PRO_COMMAND&&excludeFlags.add("--project"),target.scope&&(excludeFlags.add("--scope"),excludeFlags.add("--team")),{...fix,command:targeted(fix.command),hint,...excludeFlags.size?{excludeFlags:Array.from(excludeFlags)}:{},...preserveProject!==void 0?{preserveProject}:{}}}function clientObservabilityPlanRecovery(client,error,message,projectName,scope){return targetRecovery(observabilityPlanRecovery(message,observabilityPlusDenialReason(error),scope?planForTeam(scope):currentTeamPlan(client)),{projectName,scope:scope??currentTeamScope(client)})}function errorContext(client){let teamId=client?.config?.currentTeam;return teamId?client?.teams?.find(team=>team.id===teamId||team.slug===teamId)?.slug??teamCache.get(teamId)?.slug:client?.user?.username||client?.user?.email}function getErrorRecovery(error,client){let reason=error.reason?.toLowerCase(),scope=errorContext(client);if(error.status===403||["forbidden","permission_denied","scope_not_accessible"].includes(reason??""))return{hint:`Check that the selected team is correct${scope?` (${scope})`:""}. If it is, ask a team owner to grant the required access. Retry only after the team or access changes.`,retryable:!1,userActionRequired:!0,...scope&&{scope},...error.action&&{action:error.action},...error.resource&&{resource:error.resource}};if(error.status===401||reason==="not_authorized")return{hint:"Provide valid credentials for the intended account and team, then retry.",retryable:!1,userActionRequired:!0};if(error.status===402||["payment_required","plan_upgrade_required"].includes(reason??"")){let message=error.serverMessage??error.message??"";return{hint:observabilityPlanRecovery(message,observabilityPlusDenialReason(error),currentTeamPlan(client))?.hint??(/(?:disabled|switched off|re-enable)/i.test(message)?"Enable the feature for the selected team or project, then retry.":/(?:overdue|payment method|unpaid|balance)/i.test(message)?"Ask a team owner to resolve the billing issue, then retry.":/(?:plan|subscription)/i.test(message)?"Ask a team owner to confirm the required plan or subscription before changing billing. Retry after access is enabled.":"Check the billing or feature requirement reported above with a team owner. Retry after that requirement is resolved."),retryable:!1,userActionRequired:!0,...scope&&{scope}}}if(error.status===429||reason==="rate_limited"){let wait=error.retryAfterMs;return{hint:typeof wait=="number"&&Number.isFinite(wait)&&wait>0?`Wait at least ${Math.ceil(wait/1e3)} seconds before trying again.`:wait==="never"?"This request cannot be retried with the current limit. Ask a team owner to review the limit.":"The request limit was reached. Wait before trying again; no retry time was provided.",retryable:wait!=="never",...typeof wait=="number"&&Number.isFinite(wait)&&wait>0&&{retryAfterMs:wait}}}return{}}import{randomUUID}from"node:crypto";function agentErrorMetadata(client){return client.isAgent?{cliVersion:pkg_default.version,invocationId:client.telemetryEventStore?.currentInvocationId}:{}}function agentErrorCategory(reason){return/^(forbidden|permission_denied|scope_not_accessible)$/i.test(reason)?"permission":/^(payment_required|plan_upgrade_required)$/i.test(reason)?"billing":/^(not_authorized|login_required)$/i.test(reason)?"authentication":/^(rate_limited|too_many_requests)$/i.test(reason)?"rate_limit":/^(invalid_arguments|unknown_command|ARG_UNKNOWN_OPTION)$/i.test(reason)?"usage":/^(link_required|project_not_found|not_found)$/i.test(reason)?"project_context":"other"}function trackAgentError(client,error){!client.isAgent||!client.telemetryEventStore||client.telemetryEventStore.add({id:randomUUID(),eventTime:Date.now(),key:"agent_error",value:JSON.stringify({invocationId:client.telemetryEventStore.currentInvocationId,category:agentErrorCategory(error.reason),hasRecovery:!!error.hint,retryable:error.retryable,userActionRequired:error.userActionRequired})})}function isHelpInvocation(argv){let args=argv.slice(2),separator=args.indexOf("--");return args.slice(0,separator<0?args.length:separator).some(arg=>arg==="--help"||arg==="-h")}function trackAgentCommandOutcome(client,exitCode){if(!client.isAgent||!client.telemetryEventStore)return;let help=isHelpInvocation(client.argv);client.telemetryEventStore.add({id:randomUUID(),eventTime:Date.now(),key:"agent_command_outcome",value:JSON.stringify({invocationId:client.telemetryEventStore.currentInvocationId,exitCode,outcome:help&&(exitCode===0||exitCode===2)?"help":exitCode===0?"success":"failure"})})}function buildCommandWithYes(argv,pkgName=packageName){let args=stripSensitiveAuthArgs(argv.slice(2)),out=args.some(a=>a==="--yes"||a==="-y")?args:[...args,"--yes"];return`${pkgName} ${out.join(" ")}`.trim()}function redactEnvValueArgs(argv){let redacted=[...argv];for(let i=0;i<redacted.length;i++)redacted[i]==="--value"&&i+1<redacted.length?(redacted[i+1]='"<value>"',i++):redacted[i].startsWith("--value=")&&(redacted[i]='--value="<value>"');return redacted}var GLOBAL_FLAG_NAMES=new Set(["--cwd","--config","--yes","-y","--non-interactive","--scope","--team","-S","-T"]),GLOBAL_FLAG_SHORTHANDS={"-y":"--yes","-S":"--scope","-T":"--team"};function canonicalGlobalFlagName(name){return GLOBAL_FLAG_SHORTHANDS[name]??name}function getGlobalFlagsFromArgv(argv){let args=getGlobalFlagsFromArgs(argv.slice(2),{preserveConfig:!0,preserveYes:!0}),out=[];for(let i=0;i<args.length;i++){let arg=args[i],name=arg.startsWith("--")?arg.split("=")[0]:arg;GLOBAL_FLAG_NAMES.has(name)&&(out.push(arg),suggestionFlagTakesSeparateValue(name)&&!arg.includes("=")&&i+1<args.length&&!args[i+1].startsWith("-")&&(out.push(args[i+1]),i++))}return out}function omitGlobalFlagsFromArgs(args){let safeArgs=stripSensitiveAuthArgs(args),out=[];for(let i=0;i<safeArgs.length;i++){let arg=safeArgs[i],name=arg.startsWith("--")?arg.split("=")[0]:arg;if(GLOBAL_FLAG_NAMES.has(name)){suggestionFlagTakesSeparateValue(name)&&!arg.includes("=")&&i+1<safeArgs.length&&!safeArgs[i+1].startsWith("-")&&i++;continue}out.push(arg)}return out}function buildIntegrationCommandTailFromArgv(argv){let args=argv.slice(2),idx=args.indexOf("integration");return idx===-1?"integration":omitGlobalFlagsFromArgs(args.slice(idx)).join(" ")}function buildCommandWithGlobalFlags(argv,commandTemplate,pkgName=packageName,options){let preserved=options?.globalFlags==="all"?getGlobalFlagsFromArgs(argv.slice(2),{preserveProject:options.preserveProject}):getGlobalFlagsFromArgv(argv);if(options?.globalFlags!=="all"&&options?.preserveProject){let globalArgs=getGlobalFlagsFromArgs(argv.slice(2)),contextArgs=getGlobalFlagsFromArgs(argv.slice(2),{preserveProject:!0});preserved.push(...contextArgs.slice(globalArgs.length))}let exclude=new Set(commandTemplate.split(/\s+/).filter(token=>token.startsWith("-")).map(token=>canonicalGlobalFlagName(token.split("=")[0])));for(let flag of options?.excludeFlags??[])exclude.add(canonicalGlobalFlagName(flag));if(exclude.size){let out=[];for(let i=0;i<preserved.length;i++){let arg=preserved[i],name=arg.startsWith("--")?arg.split("=")[0]:arg;if(exclude.has(canonicalGlobalFlagName(name))){!arg.includes("=")&&i+1<preserved.length&&!preserved[i+1].startsWith("-")&&i++;continue}out.push(arg)}preserved=out}let base=`${pkgName} ${commandTemplate}`;return preserved.length===0?base:options?.prependGlobalFlags?`${pkgName} ${preserved.join(" ")} ${commandTemplate}`:`${base} ${preserved.join(" ")}`}function withGlobalFlags(client,commandTemplate,options={}){return buildCommandWithGlobalFlags(client.argv,commandTemplate,packageName,{globalFlags:"all",preserveProject:options.preserveProject})}function getPreservedArgsAfterEnvSubcommand(argv,subcommands,positionalCount){let args=stripSensitiveAuthArgs(argv.slice(2)),envIdx=args.findIndex((arg,index)=>arg==="env"&&subcommands.includes(args[index+1])),subcommandIdx=envIdx+1;if(envIdx===-1)return args;let preserved=[],positionals=0,optionsEnded=!1;for(let i=subcommandIdx+1;i<args.length;i++){let arg=args[i];if(arg==="--"&&!optionsEnded){optionsEnded=!0;continue}if(!optionsEnded&&arg.startsWith("-")){let flag=arg==="-e"?"--environment":arg;preserved.push(flag),!flag.includes("=")&&suggestionFlagTakesSeparateValue(flag)&&i+1<args.length&&!args[i+1].startsWith("-")&&preserved.push(args[++i]);continue}if(positionals<positionalCount){positionals++;continue}optionsEnded&&!preserved.includes("--")&&preserved.push("--"),preserved.push(arg)}return preserved}function omitPreservedFlagsAlreadyInTemplate(args,commandTemplate){let templateFlags=new Set(commandTemplate.split(/\s+/).filter(token=>token.startsWith("-")).map(token=>canonicalGlobalFlagName(token.split("=")[0]))),out=[];for(let i=0;i<args.length;i++){let arg=args[i],name=arg.startsWith("-")?arg.split("=")[0]:arg;if(!templateFlags.has(canonicalGlobalFlagName(name))){out.push(arg);continue}!arg.includes("=")&&suggestionFlagTakesSeparateValue(name)&&i+1<args.length&&!args[i+1].startsWith("-")&&i++}return out}function getPreservedArgsForEnvAdd(argv){return getPreservedArgsAfterEnvSubcommand(argv,["add"],3)}function buildEnvAddCommandWithPreservedArgs(argv,commandTemplate,pkgName=packageName){let preserved=omitPreservedFlagsAlreadyInTemplate(getPreservedArgsForEnvAdd(argv),commandTemplate),base=`${pkgName} ${commandTemplate}`;return preserved.length===0?base:`${base} ${preserved.map(quoteArg).join(" ")}`}function getPreservedArgsForEnvPull(argv){return getPreservedArgsAfterEnvSubcommand(argv,["pull"],1)}function getPreservedArgsForEnvRm(argv){return getPreservedArgsAfterEnvSubcommand(argv,["rm","remove"],3)}function buildEnvRmCommandWithPreservedArgs(argv,commandTemplate,pkgName=packageName){let preserved=omitPreservedFlagsAlreadyInTemplate(getPreservedArgsForEnvRm(argv),commandTemplate),base=`${pkgName} ${commandTemplate}`;return preserved.length===0?base:`${base} ${preserved.map(quoteArg).join(" ")}`}var LINK_FLAGS={...arg_common_default(),...getFlagsSpecification(linkCommand.options)};function getLinkSuggestionArgs(args){let out=[];for(let i=0;i<args.length;i++){let arg=args[i];if(!arg.startsWith("-"))continue;let spec=LINK_FLAGS[normalizeFlagName(arg)],handler=typeof spec=="string"?LINK_FLAGS[spec]:spec,hasSeparateValue=!arg.includes("=")&&i+1<args.length&&!args[i+1].startsWith("-");if(handler===void 0){hasSeparateValue&&suggestionFlagTakesSeparateValue(arg)&&i++;continue}out.push(arg),hasSeparateValue&&handler!==Boolean&&out.push(args[++i])}return out}function getPreservedArgsForEnvUpdate(argv){return getPreservedArgsAfterEnvSubcommand(argv,["update"],3)}function buildEnvUpdateCommandWithPreservedArgs(argv,commandTemplate,pkgName=packageName){let preserved=omitPreservedFlagsAlreadyInTemplate(getPreservedArgsForEnvUpdate(argv),commandTemplate),base=`${pkgName} ${commandTemplate}`;return preserved.length===0?base:`${base} ${preserved.map(quoteArg).join(" ")}`}function buildCommandWithScope(argv,scopeSlug,pkgName=packageName){let args=stripSensitiveAuthArgs(argv.slice(2)),out=[];for(let i=0;i<args.length;i++){if(args[i]==="--scope"||args[i]==="--team"||args[i]==="-S"||args[i]==="-T"){i++;continue}args[i].startsWith("--scope=")||args[i].startsWith("--team=")||out.push(args[i])}return out.push("--scope",scopeSlug),`${pkgName} ${out.join(" ")}`}function enrichActionRequiredWithInvokingCommand(payload,argv){if(payload.reason!=="missing_scope"||!payload.choices?.length)return payload;let next=[],linkCommand2=buildCommandWithGlobalFlags(argv,"link",packageName,{preserveProject:!0,excludeFlags:["--scope","--team"]});for(let choice of payload.choices){let slug=choice.name;next.push({command:`${linkCommand2} --scope ${slug}`,when:"Link first (then run any command without --scope)"}),next.push({command:buildCommandWithScope(argv,slug),when:"Run this command with scope (no link)"})}return{...payload,next}}function outputActionRequired(client,payload,exitCode=getExitCodeForReason(payload.reason)){shouldEmitNonInteractiveCommandError(client)&&(writeActionRequired(client,payload),process.exit(exitCode))}function writeActionRequired(client,payload){let enriched=enrichActionRequiredWithInvokingCommand(payload,client.argv);!enriched.hint&&enriched.next?.length&&(enriched.hint="Run one of the commands in next[] to complete without prompting."),recordCliError({code:payload.reason}),client.stdout.write(`${JSON.stringify(enriched,null,2)}
|
|
8
|
+
`)}function argvHasNonInteractive(argv){if(!argv?.length)return!1;for(let i=0;i<argv.length;i++){let a=argv[i];if(a==="--non-interactive")return argv[i+1]!=="false";if(a.startsWith("--non-interactive="))return a.slice(18)!=="false"}return!1}function shouldEmitNonInteractiveCommandError(client){return client.nonInteractive||argvHasNonInteractive(client.argv??[])}function outputAgentError(client,payload,exitCode=getExitCodeForReason(payload.reason)){shouldEmitNonInteractiveCommandError(client)&&(writeAgentError(client,payload),process.exit(exitCode))}function writeAgentError(client,payload){let enriched={...getErrorRecovery(payload,client),...payload,...agentErrorMetadata(client)};recordCliError({code:payload.reason,reportOnSuccess:!0}),trackAgentError(client,enriched),client.stdout.write(`${JSON.stringify(enriched,null,2)}
|
|
9
|
+
`)}function outputAgentSuccess(client,payload,exitCode=0){shouldEmitNonInteractiveCommandError(client)&&(!payload.hint&&payload.next?.length&&(payload.hint="Follow up with one of the commands in next[]."),client.stdout.write(`${JSON.stringify(payload,null,2)}
|
|
10
|
+
`),process.exit(exitCode))}function buildNextStepsForGlobalConfig(client){return[{command:buildCommandWithGlobalFlags(client.argv,"global-config list"),when:"List Global Config stores in the current team scope"},{command:buildCommandWithGlobalFlags(client.argv,"teams switch"),when:"Switch to the team that owns the Global Config"},{command:buildCommandWithGlobalFlags(client.argv,"whoami"),when:"Verify the current team or user scope"}]}var GLOBAL_CONFIG_NON_INTERACTIVE_HINT="Global Config commands use your current team scope. Pass --scope or run `vercel teams switch` if the store is missing.",LIST_ERROR_HINT="Project names are team-scoped. Use --scope when the project belongs to another team, or `list --all` to list deployments across all projects.";function buildNextStepsForList(client,projectName){return[projectName?{command:buildCommandWithGlobalFlags(client.argv,`project ls --filter ${projectName}`),when:"Search projects matching the attempted name to find the right one"}:{command:buildCommandWithGlobalFlags(client.argv,"project ls --filter <name>"),when:"Search projects by name substring to find the right one (replace <name>)"},{command:buildCommandWithGlobalFlags(client.argv,"list --all"),when:"List deployments across all projects in the current scope"},{command:buildCommandWithGlobalFlags(client.argv,"link"),when:"Re-link this directory to the correct Vercel project"}]}function buildNextStepsForProjectSubcommands(client,variant){let byName=variant==="access-groups"?{template:"project access-groups <name>",when:"List access groups by project name (replace <name>)"}:variant==="access-summary"?{template:"project access-summary <name>",when:"Show role counts by project name (replace <name>)"}:variant==="protection"?{template:"project protection <name>",when:"Show deployment protection by project name (replace <name>)"}:variant==="update"?{template:"project update <name> --framework <slug>",when:"Update a framework preset by project name (replace <name> and <slug>)"}:variant==="speed-insights"?{template:"project speed-insights <name>",when:"Enable Speed Insights by project name (replace <name>)"}:variant==="web-analytics"?{template:"project web-analytics <name>",when:"Enable Web Analytics by project name (replace <name>)"}:variant==="observability"?{template:"project observability enable <name>",when:"Enable Observability Plus by project name (replace <name>)"}:variant==="checks"?{template:"project checks add <name>",when:"Create a deployment check by project name (replace <name>)"}:variant==="inspect"?{template:"project inspect <name>",when:"Inspect a project by name (replace <name>)"}:variant==="resume"?{template:"project resume <name>",when:"Resume production traffic by project name (replace <name>)"}:{template:"project members <name>",when:"List members by project name (replace <name>)"};return[{command:buildCommandWithGlobalFlags(client.argv,"link"),when:"Re-link this directory to the correct Vercel project"},{command:buildCommandWithGlobalFlags(client.argv,byName.template),when:byName.when},{command:buildCommandWithGlobalFlags(client.argv,"project ls"),when:"List projects in the current team to pick a name"}]}var PROJECT_SUBCOMMAND_ERROR_HINT="If you use --cwd, ensure that folder is linked to the right project, or pass an explicit project name. Use --scope when the project belongs to another team.";function resolveNonInteractiveDefaults(client,variant){return variant==="global-config"?{next:buildNextStepsForGlobalConfig(client),hint:GLOBAL_CONFIG_NON_INTERACTIVE_HINT}:variant==="list"?{next:buildNextStepsForList(client),hint:LIST_ERROR_HINT}:{next:buildNextStepsForProjectSubcommands(client,variant),hint:PROJECT_SUBCOMMAND_ERROR_HINT}}function writeAgentErrorPayloadAndExit(client,payload,exitCode,variant){let defaults=["link_required","project_not_found","not_found"].includes(payload.reason)?resolveNonInteractiveDefaults(client,variant):{},out={...payload,next:payload.next??defaults.next,hint:payload.hint??defaults.hint};writeAgentError(client,out),process.exit(exitCode)}function isProjectNotFoundLike(err){return!!(err instanceof ProjectNotFound||(0,import_error_utils.isError)(err)&&"code"in err&&err.code==="PROJECT_NOT_FOUND")}function isLinkRequiredLike(err){return err instanceof LinkRequiredError}function normalizeApiErrorText(message){return message.replace(/\s*\(\d{3}\)\s*$/,"").trim()}function exitWithNonInteractiveError(client,err,exitCode=1,options={variant:"members"}){if(!shouldEmitNonInteractiveCommandError(client))return;let{variant}=options;if(isLinkRequiredLike(err)){if(variant==="global-config"){writeAgentErrorPayloadAndExit(client,{status:"error",reason:"link_required",message:err instanceof Error?err.message:String(err),next:buildNextStepsForGlobalConfig(client),hint:GLOBAL_CONFIG_NON_INTERACTIVE_HINT},exitCode,"global-config");return}writeAgentErrorPayloadAndExit(client,{status:"error",reason:"link_required",message:err instanceof Error?err.message:String(err)},exitCode,variant);return}if(isProjectNotFoundLike(err)){writeAgentErrorPayloadAndExit(client,{status:"error",reason:"project_not_found",message:err instanceof Error?err.message:String(err),...variant==="list"&&options.projectName?{next:buildNextStepsForList(client,options.projectName)}:{}},exitCode,variant);return}if(isAPIError(err)){let rawMessage=err.serverMessage||err.message,message=normalizeApiErrorText(rawMessage),reason=err.status===403?"forbidden":err.status===402?"payment_required":err.status===401?"not_authorized":err.status===404?variant==="global-config"?"not_found":"project_not_found":err.status===429?"rate_limited":"api_error";writeAgentErrorPayloadAndExit(client,{status:"error",reason,message,...getErrorRecovery(err,client),...err.action&&{action:err.action},...err.resource&&{resource:err.resource}},exitCode,variant)}writeAgentErrorPayloadAndExit(client,{status:"error",reason:"unexpected_error",message:err instanceof Error?err.message:String(err)},exitCode,variant)}function openUrlInBrowserCommand(url){return process.platform==="win32"?`start ${url}`:process.platform==="darwin"?`open '${url}'`:`xdg-open '${url}'`}export{AGENT_STATUS,AGENT_REASON,getExitCodeForReason,AGENT_ACTION,PRIORITY_PROJECT_ENABLE_COMMAND,BUY_PRO_COMMAND,isProOrEnterprisePlan,buyProFix,targetRecovery,clientObservabilityPlanRecovery,getErrorRecovery,agentErrorMetadata,trackAgentError,isHelpInvocation,trackAgentCommandOutcome,buildCommandWithYes,redactEnvValueArgs,getGlobalFlagsFromArgv,omitGlobalFlagsFromArgs,buildIntegrationCommandTailFromArgv,buildCommandWithGlobalFlags,withGlobalFlags,getPreservedArgsForEnvAdd,buildEnvAddCommandWithPreservedArgs,getPreservedArgsForEnvPull,getPreservedArgsForEnvRm,buildEnvRmCommandWithPreservedArgs,getLinkSuggestionArgs,getPreservedArgsForEnvUpdate,buildEnvUpdateCommandWithPreservedArgs,outputActionRequired,writeActionRequired,argvHasNonInteractive,shouldEmitNonInteractiveCommandError,outputAgentError,writeAgentError,outputAgentSuccess,exitWithNonInteractiveError,openUrlInBrowserCommand};
|