vercel 65.2.0 → 65.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/chunks/add-7NS6HIWC.js +8 -0
- package/dist/chunks/add-NMYFDVXW.js +8 -0
- package/dist/chunks/add-PMJ5BECU.js +8 -0
- package/dist/chunks/build-BCY6HQJG.js +7 -0
- package/dist/chunks/{chunk-3XCXKOBR.js → chunk-2K3ISCQ6.js} +1 -1
- package/dist/chunks/{chunk-QEAQNRWM.js → chunk-2TUVL6WE.js} +1 -1
- package/dist/chunks/{chunk-22FDWPWY.js → chunk-363SJ4TN.js} +1 -1
- package/dist/chunks/chunk-462YCCJZ.js +7 -0
- package/dist/chunks/{chunk-VBWQRK3O.js → chunk-4N6LMERQ.js} +6 -6
- package/dist/chunks/chunk-527GBU3K.js +7 -0
- package/dist/chunks/chunk-5IWFRZQT.js +10 -0
- package/dist/chunks/chunk-5KUUMQ3M.js +7 -0
- package/dist/chunks/{chunk-6URZLHEK.js → chunk-5V53NA6C.js} +1 -1
- package/dist/chunks/chunk-6I6QJHCY.js +7 -0
- package/dist/chunks/chunk-6TXEVQA4.js +7 -0
- package/dist/chunks/{chunk-2PKEEQ5W.js → chunk-6YXIWZ3X.js} +1 -1
- package/dist/chunks/{chunk-KTNBXM43.js → chunk-7E3WREH5.js} +1 -1
- package/dist/chunks/{chunk-CVDK3IYT.js → chunk-7L2K4OKM.js} +1 -1
- package/dist/chunks/{chunk-K3FFPKIV.js → chunk-7L5QUDUR.js} +1 -1
- package/dist/chunks/{chunk-X4762EE4.js → chunk-7QAGSRCU.js} +1 -1
- package/dist/chunks/{chunk-NTZ5WWYV.js → chunk-7R6TRRG5.js} +1 -1
- package/dist/chunks/{chunk-AJCM43E4.js → chunk-AYUUSAB7.js} +1 -1
- package/dist/chunks/chunk-BVGGTBYE.js +7 -0
- package/dist/chunks/{chunk-BZXSCHI7.js → chunk-C7FQMC6D.js} +1 -1
- package/dist/chunks/{chunk-XK6SNITB.js → chunk-CBVKB3DT.js} +1 -1
- package/dist/chunks/{chunk-FDNYYENK.js → chunk-CC6FLKIP.js} +1 -1
- package/dist/chunks/chunk-CR3NBTHV.js +7 -0
- package/dist/chunks/{chunk-BBKEP7RO.js → chunk-CWM2F235.js} +1 -1
- package/dist/chunks/{chunk-IUXSJWL3.js → chunk-DKJL2KV7.js} +1 -1
- package/dist/chunks/{chunk-QOCZPYRV.js → chunk-DQ2SVW4R.js} +1 -1
- package/dist/chunks/{chunk-SLI2O5X7.js → chunk-EAXMWCOL.js} +2 -2
- package/dist/chunks/{chunk-LBNOOFB6.js → chunk-ECEDD646.js} +1 -1
- package/dist/chunks/{chunk-IGDG5CWT.js → chunk-EEUJLJEJ.js} +1 -1
- package/dist/chunks/chunk-EGNR2DEI.js +7 -0
- package/dist/chunks/chunk-EISD3RG7.js +11 -0
- package/dist/chunks/{chunk-GVTXA6HG.js → chunk-EKZTFGDX.js} +1 -1
- package/dist/chunks/{chunk-CEMPU323.js → chunk-EU2GBIPC.js} +1 -1
- package/dist/chunks/{chunk-3ADDGPEN.js → chunk-F6EBOT64.js} +1 -1
- package/dist/chunks/chunk-FHU2O7ZJ.js +8 -0
- package/dist/chunks/{chunk-KH6565YH.js → chunk-FLHO75XC.js} +1 -1
- package/dist/chunks/chunk-FSPPKNKN.js +7 -0
- package/dist/chunks/{chunk-FI4SNRSM.js → chunk-GCZVIDNG.js} +1 -1
- package/dist/chunks/chunk-GYVJIIYL.js +7 -0
- package/dist/chunks/{chunk-G4T7VBGN.js → chunk-HSFKISDH.js} +1 -1
- package/dist/chunks/{chunk-N4HJGVRB.js → chunk-HTXDC7E2.js} +2 -2
- package/dist/chunks/{chunk-WUORIKOE.js → chunk-IOZ3I765.js} +1 -1
- package/dist/chunks/{chunk-JNVVIU6L.js → chunk-JLE7K4SY.js} +1 -1
- package/dist/chunks/{chunk-BL3GEBL6.js → chunk-JP33AIDQ.js} +1 -1
- package/dist/chunks/{chunk-UC2SUUL2.js → chunk-JRPNHWA3.js} +1 -1
- package/dist/chunks/{chunk-CF2FOU7X.js → chunk-JUSR7V2L.js} +1 -1
- package/dist/chunks/{chunk-MBDXRSHX.js → chunk-JWCEHQQF.js} +1 -1
- package/dist/chunks/chunk-K5U47EVH.js +7 -0
- package/dist/chunks/{chunk-VOCZ34ON.js → chunk-KCKYPLIH.js} +1 -1
- package/dist/chunks/{chunk-LH7X2ZJQ.js → chunk-KGBIRIFF.js} +1 -1
- package/dist/chunks/{chunk-7EC6KLFJ.js → chunk-KJA2GKPT.js} +1 -1
- package/dist/chunks/{chunk-S5IWVPYT.js → chunk-KPQLUGFI.js} +1 -1
- package/dist/chunks/{chunk-L7AHFYDS.js → chunk-KQCFC2JL.js} +1 -1
- package/dist/chunks/{chunk-XXXRTHTP.js → chunk-KQCROPL3.js} +1 -1
- package/dist/chunks/{chunk-BNQXEQWO.js → chunk-KY335KWI.js} +1 -1
- package/dist/chunks/{chunk-DHSOA6LP.js → chunk-L3JYCXVB.js} +1 -1
- package/dist/chunks/chunk-LFOWP74R.js +7 -0
- package/dist/chunks/{chunk-PFNYWWLI.js → chunk-LOBA3E72.js} +1 -1
- package/dist/chunks/{chunk-Y54GKXGG.js → chunk-LQVSU5HR.js} +1 -1
- package/dist/chunks/{chunk-CLFCR4UZ.js → chunk-LW4N3CW6.js} +1 -1
- package/dist/chunks/{chunk-SQE63XFX.js → chunk-M2NXKZKX.js} +1 -1
- package/dist/chunks/{chunk-65TGOMRK.js → chunk-MBEKRUTQ.js} +1 -1
- package/dist/chunks/{chunk-AGBNDJBH.js → chunk-N2FLYCCO.js} +1 -1
- package/dist/chunks/{chunk-DGG3YML4.js → chunk-N6JBQMOF.js} +2 -2
- package/dist/chunks/{chunk-P6ZHH3HQ.js → chunk-NAX6IARA.js} +1 -1
- package/dist/chunks/{chunk-H2HV2IWG.js → chunk-NGKO2OOU.js} +1 -1
- package/dist/chunks/chunk-NW7WWUCQ.js +9 -0
- package/dist/chunks/chunk-O4WNSKQR.js +15 -0
- package/dist/chunks/{chunk-7Z3WUAO5.js → chunk-O72YDZKD.js} +1 -1
- package/dist/chunks/{chunk-LKLH6DZP.js → chunk-OHEOYFBU.js} +1 -1
- package/dist/chunks/{chunk-LJBUJ23M.js → chunk-OZCQTXI4.js} +1 -1
- package/dist/chunks/{chunk-LCHECISY.js → chunk-Q4KTAQB3.js} +1 -1
- package/dist/chunks/{chunk-GENZ5QV5.js → chunk-QB7F3UAP.js} +1 -1
- package/dist/chunks/{chunk-TZFDVQ72.js → chunk-QIVX6SCR.js} +1 -1
- package/dist/chunks/{chunk-DA37HMCW.js → chunk-QVHXFHBV.js} +1 -1
- package/dist/chunks/chunk-QVXS234E.js +7 -0
- package/dist/chunks/{chunk-SXOSF4O6.js → chunk-QVZAAMGQ.js} +1 -1
- package/dist/chunks/chunk-R2BUF6Z7.js +7 -0
- package/dist/chunks/{chunk-7SYW5HXA.js → chunk-R2XHJDAP.js} +1 -1
- package/dist/chunks/{chunk-JVKIWEPJ.js → chunk-RMZTB2IU.js} +1 -1
- package/dist/chunks/{chunk-RTQ6ERZF.js → chunk-SLGUYM42.js} +1 -1
- package/dist/chunks/{chunk-4MTD47Y2.js → chunk-SYFG2RM6.js} +1 -1
- package/dist/chunks/chunk-T6243EDS.js +7 -0
- package/dist/chunks/chunk-TAISZMA2.js +7 -0
- package/dist/chunks/{chunk-TO5PJDEN.js → chunk-TEYREL44.js} +1 -1
- package/dist/chunks/{chunk-LZWQBY2I.js → chunk-TIPQQ4TG.js} +1 -1
- package/dist/chunks/{chunk-LC6D6S24.js → chunk-U2OBPULW.js} +1 -1
- package/dist/chunks/{chunk-QMGXVTLQ.js → chunk-UGNIIDHR.js} +1 -1
- package/dist/chunks/{chunk-NQWGRKF4.js → chunk-UHBMX3OK.js} +1 -1
- package/dist/chunks/{chunk-QMCHGGDX.js → chunk-VNIKIQVE.js} +1 -1
- package/dist/chunks/{chunk-DGYHWXD2.js → chunk-WDXW6A4H.js} +2 -2
- package/dist/chunks/{chunk-XSE75NFU.js → chunk-WEH6XC4Y.js} +1 -1
- package/dist/chunks/{chunk-TKBORMUF.js → chunk-WKZ6JSGZ.js} +1 -1
- package/dist/chunks/{chunk-WGXKX24Q.js → chunk-WVHCBDTB.js} +1 -1
- package/dist/chunks/{chunk-EEEYN6B4.js → chunk-XC46OAAT.js} +1 -1
- package/dist/chunks/{chunk-WBF36MYT.js → chunk-XVDRGWXM.js} +1 -1
- package/dist/chunks/{chunk-IKQTP764.js → chunk-Y5ZMKL7E.js} +1 -1
- package/dist/chunks/{chunk-QQVGXIFM.js → chunk-YEZJNXQX.js} +1 -1
- package/dist/chunks/{chunk-FEI6O5QD.js → chunk-YHULP2KK.js} +1 -1
- package/dist/chunks/{chunk-MX3RY7HH.js → chunk-YMZ6WBKB.js} +2 -2
- package/dist/chunks/{chunk-RUA6EEAJ.js → chunk-ZN6CQWVP.js} +1 -1
- package/dist/chunks/{chunk-KECUEAMH.js → chunk-ZQBSAMFL.js} +1 -1
- package/dist/chunks/clear-FKVWDCVA.js +8 -0
- package/dist/chunks/{compile-vercel-config-QHWJCKJV.js → compile-vercel-config-GWAJE44R.js} +1 -1
- package/dist/chunks/config-5WVLG5SE.js +8 -0
- package/dist/chunks/{config-3ZSKJULZ.js → config-RMOHN5YT.js} +1 -1
- package/dist/chunks/config-validator.mjs +1 -1
- package/dist/chunks/{constants-ICJL2EO5.js → constants-JAB7MRSK.js} +1 -1
- package/dist/chunks/delete-5WMB4WFR.js +9 -0
- package/dist/chunks/delete-EM4JZPFA.js +10 -0
- package/dist/chunks/{detect-projects-NLAYKNQX.js → detect-projects-OD4JEAW2.js} +1 -1
- package/dist/chunks/{detect-services-D6HLLAI4.js → detect-services-BSJGB4RM.js} +1 -1
- package/dist/chunks/disable-QOM7UHQC.js +7 -0
- package/dist/chunks/discard-L5ZH7P5B.js +14 -0
- package/dist/chunks/edit-F3VJGCG2.js +9 -0
- package/dist/chunks/edit-TM7YCWBU.js +8 -0
- package/dist/chunks/enable-72C3QX34.js +7 -0
- package/dist/chunks/{export-XOMKFSVY.js → export-EPLYZF2Q.js} +1 -1
- package/dist/chunks/{future-XGH5EADE.js → future-V77DRMQG.js} +1 -1
- package/dist/chunks/generate-cert-for-deploy-Y3YHBMPU.js +7 -0
- package/dist/chunks/{image-J2SIGGGB.js → image-CVXEXU5R.js} +1 -1
- package/dist/chunks/{import-builders-MBKD4ERV.js → import-builders-PGRKJOOE.js} +1 -1
- package/dist/chunks/inspect-BTRNXRJT.js +9 -0
- package/dist/chunks/{inspect-MR3XFJSZ.js → inspect-CZ7WXYE5.js} +1 -1
- package/dist/chunks/inspect-FGDVWAQP.js +13 -0
- package/dist/chunks/{inspect-MY3WMAQO.js → inspect-HFDGZNWC.js} +1 -1
- package/dist/chunks/{inspect-SNN4G5IH.js → inspect-T2AIREYK.js} +1 -1
- package/dist/chunks/list-CKRRHAOE.js +12 -0
- package/dist/chunks/{list-5HYYTOOF.js → list-FLREMGJR.js} +1 -1
- package/dist/chunks/{list-7LMA6KKH.js → list-ON4YTQRN.js} +1 -1
- package/dist/chunks/login-55LJ5ZA6.js +9 -0
- package/dist/chunks/{login-TVTT7VFC.js → login-DQRZSD4Z.js} +1 -1
- package/dist/chunks/logs-2HQXWOHM.js +7 -0
- package/dist/chunks/{ls-QPOCM5P2.js → ls-2HUJHVLA.js} +1 -1
- package/dist/chunks/{ls-NBMLWOON.js → ls-3DVM5HLK.js} +1 -1
- package/dist/chunks/ls-4B3QYHCI.js +8 -0
- package/dist/chunks/{ls-6NO2RHSW.js → ls-A7K4XDQB.js} +1 -1
- package/dist/chunks/{ls-WHEKRXAT.js → ls-FK5XEJEU.js} +1 -1
- package/dist/chunks/{ls-BHP75R3B.js → ls-QGUKJJY5.js} +1 -1
- package/dist/chunks/ls-VTKHPDWS.js +11 -0
- package/dist/chunks/mutate-7ADZBCZM.js +9 -0
- package/dist/chunks/{notifications-F7GGQGPQ.js → notifications-XZJXE2K4.js} +1 -1
- package/dist/chunks/open-EE5IZQD7.js +7 -0
- package/dist/chunks/{openapi-JGYEFJJV.js → openapi-QBX62ZXC.js} +1 -1
- package/dist/chunks/{permissions-KSPXNTFT.js → permissions-VYJ4LL5R.js} +1 -1
- package/dist/chunks/{plugin-offer-4U77LNYA.js → plugin-offer-TEGYA3TA.js} +1 -1
- package/dist/chunks/{prompt-missing-credentials-JJP6AV5V.js → prompt-missing-credentials-VP6OVCFM.js} +1 -1
- package/dist/chunks/publish-2HEK5UMJ.js +15 -0
- package/dist/chunks/pull-WRTTSY7J.js +7 -0
- package/dist/chunks/purchase-domain-if-available-6S3NLTUI.js +7 -0
- package/dist/chunks/push-L3QRGGLC.js +7 -0
- package/dist/chunks/{query-XCRX43SR.js → query-FXXLX6UB.js} +3 -3
- package/dist/chunks/{reauthenticate-LRJ5APNU.js → reauthenticate-IXQDC4UZ.js} +1 -1
- package/dist/chunks/reorder-B4OXSYCI.js +10 -0
- package/dist/chunks/reply-F637K6XH.js +9 -0
- package/dist/chunks/resolve-E3F6NYQZ.js +12 -0
- package/dist/chunks/{resolve-agent-team-OGT4SLRJ.js → resolve-agent-team-EIPCH766.js} +1 -1
- package/dist/chunks/restore-Q25KRZPH.js +16 -0
- package/dist/chunks/rm-FWD2NUGX.js +8 -0
- package/dist/chunks/rm-JMQ4QKCC.js +8 -0
- package/dist/chunks/rm-PPG7P3GN.js +8 -0
- package/dist/chunks/rm-SH3DYKNS.js +8 -0
- package/dist/chunks/rm-UEBLKFVC.js +8 -0
- package/dist/chunks/{routes-P6LKQCWH.js → routes-PKTWMDWQ.js} +1 -1
- package/dist/chunks/rule-inspect-LKQA5I4V.js +8 -0
- package/dist/chunks/{schema-NYKJCOCR.js → schema-FBV42W7N.js} +1 -1
- package/dist/chunks/{schema-NSGCBPHF.js → schema-ZWE5MNMG.js} +1 -1
- package/dist/chunks/{select-org-AZVHP7AQ.js → select-org-WMB752Z6.js} +1 -1
- package/dist/chunks/set-UTYIPOLC.js +7 -0
- package/dist/chunks/setup-and-link-ZLY5XQW5.js +7 -0
- package/dist/chunks/{skills-4J2NC2QI.js → skills-RKIGVVNM.js} +2 -2
- package/dist/chunks/{tags-CCM7IGNC.js → tags-UCLZ5UMX.js} +1 -1
- package/dist/chunks/{types-SK6J2HFE.js → types-YM7TMHXW.js} +1 -1
- package/dist/chunks/{update-TFDQQXYZ.js → update-BGDQ5TXO.js} +1 -1
- package/dist/commands/build/index.js +1 -1
- package/dist/commands/deploy/index.js +4 -4
- package/dist/commands/dev/index.js +8 -8
- package/dist/commands/env/index.js +1 -1
- package/dist/commands/link/index.js +1 -1
- package/dist/commands/list/index.js +1 -1
- package/dist/commands/project/index.js +8 -8
- package/dist/commands-account.js +9 -9
- package/dist/commands-ai.js +12 -12
- package/dist/commands-blob.js +8 -8
- package/dist/commands-core.js +11 -11
- package/dist/commands-deployments.js +1 -1
- package/dist/commands-flags.js +6 -6
- package/dist/commands-integrations.js +16 -16
- package/dist/commands-observability.js +39 -10
- package/dist/commands-routing.js +18 -18
- package/dist/help.js +1 -1
- package/dist/index.js +5 -3
- package/dist/internal-build.js +1 -1
- package/dist/root-help-commands.mjs +1 -1
- package/dist/vc.js +198 -97
- package/dist/version.mjs +1 -1
- package/package.json +60 -60
- package/dist/chunks/add-6XE2EK66.js +0 -8
- package/dist/chunks/add-WITOGFYA.js +0 -8
- package/dist/chunks/add-YSIECJTJ.js +0 -8
- package/dist/chunks/build-DNYYPGF2.js +0 -7
- package/dist/chunks/chunk-3AYYFYZG.js +0 -7
- package/dist/chunks/chunk-5IASAERQ.js +0 -7
- package/dist/chunks/chunk-76KGQU2G.js +0 -7
- package/dist/chunks/chunk-7N67TEDX.js +0 -10
- package/dist/chunks/chunk-ABZEMNDR.js +0 -7
- package/dist/chunks/chunk-AWMQGOS2.js +0 -7
- package/dist/chunks/chunk-B4YYOSPY.js +0 -7
- package/dist/chunks/chunk-E2SADN6I.js +0 -7
- package/dist/chunks/chunk-F6FTWDLS.js +0 -7
- package/dist/chunks/chunk-GGSM5AHN.js +0 -8
- package/dist/chunks/chunk-IA3MXJRC.js +0 -8
- package/dist/chunks/chunk-IEPW2YRH.js +0 -7
- package/dist/chunks/chunk-LUBUI5GF.js +0 -7
- package/dist/chunks/chunk-OKEBIUKZ.js +0 -7
- package/dist/chunks/chunk-QYCGL36Q.js +0 -7
- package/dist/chunks/chunk-QZX7VG2V.js +0 -9
- package/dist/chunks/chunk-R5B5ISRX.js +0 -15
- package/dist/chunks/chunk-UNEGQPD3.js +0 -7
- package/dist/chunks/chunk-YHQ7PPXP.js +0 -7
- package/dist/chunks/clear-KLE7JYWS.js +0 -8
- package/dist/chunks/config-F5QZ5IGE.js +0 -8
- package/dist/chunks/delete-GKUCUSHP.js +0 -9
- package/dist/chunks/delete-TLC65SZD.js +0 -10
- package/dist/chunks/disable-ORTTESHC.js +0 -7
- package/dist/chunks/discard-TGWEOYRT.js +0 -14
- package/dist/chunks/edit-3XLIA7OG.js +0 -8
- package/dist/chunks/edit-IE2X5ZQD.js +0 -9
- package/dist/chunks/enable-DK3YZA4V.js +0 -7
- package/dist/chunks/generate-cert-for-deploy-RGFAQHRI.js +0 -7
- package/dist/chunks/inspect-CPXTLLSJ.js +0 -13
- package/dist/chunks/inspect-Q7D2TTXV.js +0 -9
- package/dist/chunks/list-6WEW57IO.js +0 -12
- package/dist/chunks/login-PFJ4ZSUI.js +0 -9
- package/dist/chunks/logs-WAOHH4MP.js +0 -7
- package/dist/chunks/ls-VDMCJ53V.js +0 -11
- package/dist/chunks/ls-ZL4DBDXR.js +0 -8
- package/dist/chunks/mutate-C6FYX2DM.js +0 -9
- package/dist/chunks/open-EX4PGTAE.js +0 -7
- package/dist/chunks/publish-UZES2VJC.js +0 -15
- package/dist/chunks/pull-WUTJTCOT.js +0 -7
- package/dist/chunks/purchase-domain-if-available-XMNJGSPL.js +0 -7
- package/dist/chunks/push-ST6KQ2OK.js +0 -7
- package/dist/chunks/reorder-QSZPOIBU.js +0 -10
- package/dist/chunks/reply-CAWLLEJ6.js +0 -9
- package/dist/chunks/resolve-GO4RFRQY.js +0 -12
- package/dist/chunks/restore-NHHAVT4H.js +0 -16
- package/dist/chunks/rm-5FFPHHK6.js +0 -8
- package/dist/chunks/rm-7WHWMHAY.js +0 -8
- package/dist/chunks/rm-IFTLVW4R.js +0 -8
- package/dist/chunks/rm-TDUKZY7D.js +0 -8
- package/dist/chunks/rm-XIN5CPXB.js +0 -8
- package/dist/chunks/rule-inspect-4EIDKQL6.js +0 -8
- package/dist/chunks/set-OC6KN3G4.js +0 -7
- package/dist/chunks/setup-and-link-WEXKJDAQ.js +0 -7
package/dist/vc.js
CHANGED
|
@@ -11,16 +11,18 @@ try {
|
|
|
11
11
|
}
|
|
12
12
|
} catch {}
|
|
13
13
|
|
|
14
|
-
//
|
|
15
|
-
//
|
|
14
|
+
// Run the one package this platform maps to: the native binary on macOS and
|
|
15
|
+
// Linux x64/arm64, @vercel/cli-support everywhere else. This package's own JS
|
|
16
|
+
// CLI (./index.js) is only a fallback, recorded in telemetry.
|
|
16
17
|
import { spawnSync } from 'node:child_process';
|
|
17
|
-
import { existsSync } from 'node:fs';
|
|
18
|
+
import { existsSync, readFileSync, statSync, writeFileSync } from 'node:fs';
|
|
18
19
|
import { dirname, join, resolve } from 'node:path';
|
|
19
|
-
import { fileURLToPath } from 'node:url';
|
|
20
|
+
import { fileURLToPath, pathToFileURL } from 'node:url';
|
|
20
21
|
|
|
21
22
|
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
22
23
|
|
|
23
|
-
// Keep in sync with packages/vc-native/scripts/platforms.mjs.
|
|
24
|
+
// Keep in sync with packages/vc-native/scripts/platforms.mjs. Windows runs
|
|
25
|
+
// only the Node CLI until its native binaries are signed.
|
|
24
26
|
const NATIVE_TARGETS = [
|
|
25
27
|
'darwin-arm64',
|
|
26
28
|
'darwin-x64',
|
|
@@ -28,8 +30,6 @@ const NATIVE_TARGETS = [
|
|
|
28
30
|
'linux-arm64-musl',
|
|
29
31
|
'linux-x64',
|
|
30
32
|
'linux-x64-musl',
|
|
31
|
-
'win32-arm64',
|
|
32
|
-
'win32-x64',
|
|
33
33
|
];
|
|
34
34
|
|
|
35
35
|
// musl's `ldd` names itself. npm and pnpm skip the other libc's package via
|
|
@@ -40,69 +40,65 @@ function isMusl() {
|
|
|
40
40
|
return `${ldd.stdout ?? ''}${ldd.stderr ?? ''}`.includes('musl');
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
function
|
|
43
|
+
function platformTarget() {
|
|
44
44
|
const target = `${process.platform}-${process.arch}`;
|
|
45
45
|
return process.platform === 'linux' && isMusl() ? `${target}-musl` : target;
|
|
46
46
|
}
|
|
47
47
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
const binName = process.platform === 'win32' ? 'vercel.exe' : 'vercel';
|
|
53
|
-
// Walk up from this install's own tree looking for a sibling native
|
|
54
|
-
// package. `require.resolve()` is not used because it falls back to
|
|
55
|
-
// NODE_PATH and the global folders even when `paths` is given.
|
|
48
|
+
// Walk up from this install's own tree. `require.resolve()` is not used
|
|
49
|
+
// because it falls back to NODE_PATH and the global folders even when `paths`
|
|
50
|
+
// is given.
|
|
51
|
+
function findPackage(name) {
|
|
56
52
|
let dir = __dirname;
|
|
57
53
|
while (true) {
|
|
58
|
-
const pkgDir = join(dir, 'node_modules',
|
|
59
|
-
if (existsSync(join(pkgDir, 'package.json')))
|
|
60
|
-
const a = join(pkgDir, 'bin', binName);
|
|
61
|
-
if (existsSync(a)) return a;
|
|
62
|
-
const b = join(pkgDir, binName);
|
|
63
|
-
if (existsSync(b)) return b;
|
|
64
|
-
}
|
|
54
|
+
const pkgDir = join(dir, 'node_modules', name);
|
|
55
|
+
if (existsSync(join(pkgDir, 'package.json'))) return pkgDir;
|
|
65
56
|
const parent = dirname(dir);
|
|
66
57
|
if (parent === dir) return null;
|
|
67
58
|
dir = parent;
|
|
68
59
|
}
|
|
69
60
|
}
|
|
70
61
|
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
62
|
+
// The package this platform maps to: a native target or `cli-support`.
|
|
63
|
+
function mappedTarget() {
|
|
64
|
+
const target = platformTarget();
|
|
65
|
+
return NATIVE_TARGETS.includes(target) ? target : 'cli-support';
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
function resolveTarget() {
|
|
69
|
+
const target = mappedTarget();
|
|
70
|
+
if (target === 'cli-support') {
|
|
71
|
+
const pkgDir = findPackage('@vercel/cli-support');
|
|
72
|
+
const entry = pkgDir && join(pkgDir, 'dist', 'index.js');
|
|
73
|
+
return {
|
|
74
|
+
target: 'cli-support',
|
|
75
|
+
entry: entry && existsSync(entry) && entry,
|
|
76
|
+
};
|
|
78
77
|
}
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
78
|
+
const pkgDir = findPackage(`@vercel/vc-native-${target}`);
|
|
79
|
+
const bin =
|
|
80
|
+
pkgDir &&
|
|
81
|
+
[join(pkgDir, 'bin', 'vercel'), join(pkgDir, 'vercel')].find(existsSync);
|
|
82
|
+
return { target, bin };
|
|
83
83
|
}
|
|
84
84
|
|
|
85
|
-
//
|
|
86
|
-
function
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
}
|
|
93
|
-
if (arg.startsWith('--global-config=')) {
|
|
94
|
-
return arg.slice('--global-config='.length);
|
|
95
|
-
}
|
|
85
|
+
// This file also ships in @vercel/cli-support, which is its own JS CLI.
|
|
86
|
+
function isCliSupport() {
|
|
87
|
+
try {
|
|
88
|
+
const pkg = JSON.parse(readFileSync(join(__dirname, '..', 'package.json')));
|
|
89
|
+
return pkg.name === '@vercel/cli-support';
|
|
90
|
+
} catch {
|
|
91
|
+
return false;
|
|
96
92
|
}
|
|
97
|
-
return undefined;
|
|
98
93
|
}
|
|
99
94
|
|
|
100
|
-
//
|
|
101
|
-
|
|
95
|
+
// The native binary is the default, but this release still honors an explicit
|
|
96
|
+
// opt-out: VERCEL_CLI_USE_NATIVE_BINARY, then a persisted `useNativeBinary`
|
|
97
|
+
// preference. Any failure to read config counts as no preference.
|
|
98
|
+
async function isNativeBinaryOptedOut() {
|
|
102
99
|
const envOverride = process.env.VERCEL_CLI_USE_NATIVE_BINARY;
|
|
103
|
-
if (envOverride === '
|
|
104
|
-
if (envOverride === '
|
|
105
|
-
|
|
100
|
+
if (envOverride === '0' || envOverride === 'false') return true;
|
|
101
|
+
if (envOverride === '1' || envOverride === 'true') return false;
|
|
106
102
|
try {
|
|
107
103
|
// Zod-free subpath to avoid loading zod + schemas on this hot path.
|
|
108
104
|
const config = await import('@vercel/cli-config/paths');
|
|
@@ -110,56 +106,89 @@ async function isNativeBinaryOptedIn() {
|
|
|
110
106
|
const configDir = argDir
|
|
111
107
|
? resolve(process.cwd(), argDir)
|
|
112
108
|
: config.getGlobalPathConfig();
|
|
113
|
-
const configPath = config.getConfigFilePath(configDir);
|
|
114
|
-
const preference = config.readGlobalConfigFlag(
|
|
115
|
-
configPath,
|
|
116
|
-
'useNativeBinary'
|
|
117
|
-
);
|
|
118
|
-
if (typeof preference === 'boolean') return preference;
|
|
119
|
-
// All macOS machines are opted in unless they explicitly opt out above.
|
|
120
|
-
if (process.platform === 'darwin') return true;
|
|
121
109
|
return (
|
|
122
|
-
config.readGlobalConfigFlag(
|
|
110
|
+
config.readGlobalConfigFlag(
|
|
111
|
+
config.getConfigFilePath(configDir),
|
|
112
|
+
'useNativeBinary'
|
|
113
|
+
) === false
|
|
123
114
|
);
|
|
124
115
|
} catch {
|
|
125
116
|
return false;
|
|
126
117
|
}
|
|
127
118
|
}
|
|
128
119
|
|
|
129
|
-
//
|
|
130
|
-
//
|
|
131
|
-
const
|
|
132
|
-
const nativeBin = resolveNative();
|
|
133
|
-
const bin = disableBinary ? null : nativeBin;
|
|
120
|
+
// When the OS cannot start the binary at all, no command code has run, so
|
|
121
|
+
// Node.js can safely run the command instead.
|
|
122
|
+
const NATIVE_SPAWN_FALLBACK_CODES = ['ENOENT', 'EACCES', 'ENOEXEC'];
|
|
134
123
|
|
|
135
|
-
//
|
|
136
|
-
//
|
|
137
|
-
//
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
},
|
|
152
|
-
});
|
|
153
|
-
if (r.error) {
|
|
154
|
-
console.error(r.error.message);
|
|
155
|
-
process.exit(1);
|
|
124
|
+
// Read by src/index.ts and reported in telemetry. Inside the native binary,
|
|
125
|
+
// pkg.js sets it to `native` before re-entering this file with
|
|
126
|
+
// VERCEL_VC_NATIVE=1.
|
|
127
|
+
const LAUNCH = Symbol.for('vercel.cli.launch');
|
|
128
|
+
let launch;
|
|
129
|
+
let cliSupportEntry;
|
|
130
|
+
if (process.env.VERCEL_VC_NATIVE === '1') {
|
|
131
|
+
if (globalThis[LAUNCH]?.runtime !== 'native') {
|
|
132
|
+
// Not the native binary: a process it spawned (a build script, a dev
|
|
133
|
+
// command) inherited VERCEL_VC_NATIVE=1 and ran this package's JS CLI.
|
|
134
|
+
launch = {
|
|
135
|
+
runtime: 'dist',
|
|
136
|
+
target: mappedTarget(),
|
|
137
|
+
reason: 'inherited_native_env',
|
|
138
|
+
};
|
|
139
|
+
globalThis[LAUNCH] = launch;
|
|
156
140
|
}
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
141
|
+
} else {
|
|
142
|
+
const resolved = resolveTarget();
|
|
143
|
+
if (resolved.bin && (await isNativeBinaryOptedOut())) {
|
|
144
|
+
launch = { runtime: 'dist', target: resolved.target, reason: 'opt_out' };
|
|
145
|
+
} else if (resolved.bin) {
|
|
146
|
+
// Internal worker arguments intentionally trampoline too. The packaged
|
|
147
|
+
// native binary sets VERCEL_VC_NATIVE=1 in pkg.js and re-enters this file,
|
|
148
|
+
// where the worker branch below handles the request.
|
|
149
|
+
const r = spawnSync(resolved.bin, process.argv.slice(2), {
|
|
150
|
+
stdio: 'inherit',
|
|
151
|
+
windowsHide: true,
|
|
152
|
+
env: {
|
|
153
|
+
...process.env,
|
|
154
|
+
VERCEL_VC_NATIVE: '1',
|
|
155
|
+
// Upgrades belong to the vercel package, not its native runtime
|
|
156
|
+
// dependency. Always replace an inherited value with this launcher's
|
|
157
|
+
// own entrypoint.
|
|
158
|
+
VERCEL_CLI_PACKAGE_ENTRYPOINT: fileURLToPath(import.meta.url),
|
|
159
|
+
VERCEL_CLI_PACKAGE_EXECUTABLE: resolved.bin,
|
|
160
|
+
},
|
|
161
|
+
});
|
|
162
|
+
// Never fall back on an exit status: a loader failure (e.g. glibc
|
|
163
|
+
// mismatch) and a command's own failure are indistinguishable, and
|
|
164
|
+
// retrying a command in Node.js could repeat remote mutations.
|
|
165
|
+
if (!(r.error && NATIVE_SPAWN_FALLBACK_CODES.includes(r.error.code))) {
|
|
166
|
+
if (r.error) {
|
|
167
|
+
console.error(r.error.message);
|
|
168
|
+
process.exit(1);
|
|
169
|
+
}
|
|
170
|
+
if (r.signal) {
|
|
171
|
+
try {
|
|
172
|
+
process.kill(process.pid, r.signal);
|
|
173
|
+
} catch {}
|
|
174
|
+
}
|
|
175
|
+
process.exit(r.status ?? 1);
|
|
176
|
+
}
|
|
177
|
+
console.error(
|
|
178
|
+
`! The native Vercel CLI binary could not start (${r.error.code}), so Node.js is running this command.`
|
|
179
|
+
);
|
|
180
|
+
launch = { runtime: 'dist', target: resolved.target, reason: r.error.code };
|
|
181
|
+
} else if (resolved.entry || isCliSupport()) {
|
|
182
|
+
launch = { runtime: 'cli-support' };
|
|
183
|
+
} else {
|
|
184
|
+
launch = {
|
|
185
|
+
runtime: 'dist',
|
|
186
|
+
target: resolved.target,
|
|
187
|
+
reason: 'target_missing',
|
|
188
|
+
};
|
|
161
189
|
}
|
|
162
|
-
|
|
190
|
+
globalThis[LAUNCH] = launch;
|
|
191
|
+
cliSupportEntry = resolved.entry;
|
|
163
192
|
}
|
|
164
193
|
|
|
165
194
|
if (process.argv[2] === '--internal-build-worker') {
|
|
@@ -205,6 +234,71 @@ if (process.argv[2] === '--internal-build-worker') {
|
|
|
205
234
|
process.exit(process.exitCode ?? 0);
|
|
206
235
|
}
|
|
207
236
|
|
|
237
|
+
// Read `--global-config`/`-Q` without loading the full CLI arg parser.
|
|
238
|
+
function globalConfigDirFromArgv() {
|
|
239
|
+
const argv = process.argv.slice(2);
|
|
240
|
+
for (let i = 0; i < argv.length; i++) {
|
|
241
|
+
const arg = argv[i];
|
|
242
|
+
if (arg === '--global-config' || arg === '-Q') {
|
|
243
|
+
return argv[i + 1];
|
|
244
|
+
}
|
|
245
|
+
if (arg.startsWith('--global-config=')) {
|
|
246
|
+
return arg.slice('--global-config='.length);
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
return undefined;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
// Linux on anything but x64/arm64 has no native binary, and will lose the JS
|
|
253
|
+
// CLI from `vercel` itself in a future release.
|
|
254
|
+
async function warnDeprecatedArch() {
|
|
255
|
+
if (
|
|
256
|
+
process.platform !== 'linux' ||
|
|
257
|
+
['x64', 'arm64'].includes(process.arch) ||
|
|
258
|
+
process.env.VERCEL_VC_NATIVE === '1'
|
|
259
|
+
) {
|
|
260
|
+
return;
|
|
261
|
+
}
|
|
262
|
+
const argv = process.argv.slice(2);
|
|
263
|
+
const formatIndex = argv.indexOf('--format');
|
|
264
|
+
if (
|
|
265
|
+
argv.some(arg =>
|
|
266
|
+
[
|
|
267
|
+
'--non-interactive',
|
|
268
|
+
'--non-interactive=true',
|
|
269
|
+
'--json',
|
|
270
|
+
'--format=json',
|
|
271
|
+
].includes(arg)
|
|
272
|
+
) ||
|
|
273
|
+
(formatIndex !== -1 && argv[formatIndex + 1] === 'json')
|
|
274
|
+
) {
|
|
275
|
+
return;
|
|
276
|
+
}
|
|
277
|
+
let stamp;
|
|
278
|
+
try {
|
|
279
|
+
const config = await import('@vercel/cli-config/paths');
|
|
280
|
+
const argDir = globalConfigDirFromArgv();
|
|
281
|
+
const configDir = argDir
|
|
282
|
+
? resolve(process.cwd(), argDir)
|
|
283
|
+
: config.getGlobalPathConfig();
|
|
284
|
+
if (existsSync(configDir)) {
|
|
285
|
+
stamp = join(configDir, '.arch-deprecation-warned');
|
|
286
|
+
if (Date.now() - statSync(stamp).mtimeMs < 24 * 60 * 60 * 1000) return;
|
|
287
|
+
}
|
|
288
|
+
} catch {}
|
|
289
|
+
const target = `${process.platform}-${process.arch}`;
|
|
290
|
+
console.error(
|
|
291
|
+
`! Support for ${target} will be removed from the vercel package in a future release.`
|
|
292
|
+
);
|
|
293
|
+
if (stamp) {
|
|
294
|
+
try {
|
|
295
|
+
writeFileSync(stamp, '');
|
|
296
|
+
} catch {}
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
await warnDeprecatedArch();
|
|
301
|
+
|
|
208
302
|
// Fast path for --version to avoid loading the entire CLI
|
|
209
303
|
if (
|
|
210
304
|
process.argv.length === 3 &&
|
|
@@ -248,16 +342,23 @@ if (
|
|
|
248
342
|
}
|
|
249
343
|
|
|
250
344
|
try {
|
|
251
|
-
await
|
|
345
|
+
await (cliSupportEntry
|
|
346
|
+
? import(pathToFileURL(cliSupportEntry).href)
|
|
347
|
+
: import('./index.js'));
|
|
252
348
|
} catch (error) {
|
|
253
|
-
//
|
|
254
|
-
//
|
|
349
|
+
// The mapped package is missing and this package's own JS CLI cannot load
|
|
350
|
+
// either, so name the package to install.
|
|
255
351
|
if (
|
|
256
|
-
|
|
257
|
-
process.env.VERCEL_VC_NATIVE !== '1' &&
|
|
352
|
+
launch?.reason === 'target_missing' &&
|
|
258
353
|
error?.code === 'ERR_MODULE_NOT_FOUND'
|
|
259
354
|
) {
|
|
260
|
-
|
|
355
|
+
const pkg =
|
|
356
|
+
launch.target === 'cli-support'
|
|
357
|
+
? '@vercel/cli-support'
|
|
358
|
+
: `@vercel/vc-native-${launch.target}`;
|
|
359
|
+
console.error(
|
|
360
|
+
`Error: ${pkg} is not installed. Reinstall vercel without omitting optional dependencies (for example, npm i -g vercel@latest).`
|
|
361
|
+
);
|
|
261
362
|
console.error(error.message);
|
|
262
363
|
process.exit(1);
|
|
263
364
|
}
|
package/dist/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const version = "65.
|
|
1
|
+
export const version = "65.4.0";
|
|
2
2
|
export const buildLabel = "";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vercel",
|
|
3
|
-
"version": "65.
|
|
3
|
+
"version": "65.4.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"preferGlobal": true,
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -35,51 +35,51 @@
|
|
|
35
35
|
"undici": "5.29.0",
|
|
36
36
|
"uuid": "14.0.1",
|
|
37
37
|
"zod": "4.1.11",
|
|
38
|
-
"@vercel/backends": "
|
|
39
|
-
"@vercel/
|
|
40
|
-
"@vercel/cli-
|
|
41
|
-
"@vercel/
|
|
42
|
-
"@vercel/container": "22.0.1",
|
|
38
|
+
"@vercel/backends": "23.0.0",
|
|
39
|
+
"@vercel/cli-auth": "0.3.13",
|
|
40
|
+
"@vercel/cli-config": "0.3.4",
|
|
41
|
+
"@vercel/build-utils": "15.1.0",
|
|
43
42
|
"@vercel/detect-agent": "1.2.7",
|
|
44
|
-
"@vercel/elysia": "
|
|
45
|
-
"@vercel/
|
|
46
|
-
"@vercel/
|
|
47
|
-
"@vercel/
|
|
48
|
-
"@vercel/
|
|
49
|
-
"@vercel/hono": "
|
|
50
|
-
"@vercel/
|
|
51
|
-
"@vercel/
|
|
52
|
-
"@vercel/
|
|
53
|
-
"@vercel/next": "
|
|
54
|
-
"@vercel/
|
|
43
|
+
"@vercel/elysia": "23.0.0",
|
|
44
|
+
"@vercel/fastify": "23.0.0",
|
|
45
|
+
"@vercel/container": "23.0.0",
|
|
46
|
+
"@vercel/express": "23.0.0",
|
|
47
|
+
"@vercel/go": "26.0.0",
|
|
48
|
+
"@vercel/hono": "23.0.0",
|
|
49
|
+
"@vercel/h3": "23.0.0",
|
|
50
|
+
"@vercel/hydrogen": "24.0.0",
|
|
51
|
+
"@vercel/koa": "23.0.0",
|
|
52
|
+
"@vercel/next": "27.0.0",
|
|
53
|
+
"@vercel/nestjs": "23.0.0",
|
|
54
|
+
"@vercel/python": "29.0.0",
|
|
55
55
|
"@vercel/python-analysis": "0.15.2",
|
|
56
|
-
"@vercel/
|
|
57
|
-
"@vercel/remix-builder": "
|
|
58
|
-
"@vercel/
|
|
59
|
-
"@vercel/
|
|
60
|
-
"@vercel/static-build": "
|
|
61
|
-
"@vercel/
|
|
56
|
+
"@vercel/node": "28.0.0",
|
|
57
|
+
"@vercel/remix-builder": "28.0.0",
|
|
58
|
+
"@vercel/rust": "24.0.0",
|
|
59
|
+
"@vercel/redwood": "25.0.0",
|
|
60
|
+
"@vercel/static-build": "25.0.0",
|
|
61
|
+
"@vercel/ruby": "25.0.0"
|
|
62
62
|
},
|
|
63
63
|
"builders": {
|
|
64
|
-
"@vercel/backends": "
|
|
65
|
-
"@vercel/container": "
|
|
66
|
-
"@vercel/elysia": "
|
|
67
|
-
"@vercel/express": "
|
|
68
|
-
"@vercel/fastify": "
|
|
69
|
-
"@vercel/go": "
|
|
70
|
-
"@vercel/h3": "
|
|
71
|
-
"@vercel/hono": "
|
|
72
|
-
"@vercel/hydrogen": "
|
|
73
|
-
"@vercel/koa": "
|
|
74
|
-
"@vercel/nestjs": "
|
|
75
|
-
"@vercel/next": "
|
|
76
|
-
"@vercel/node": "
|
|
77
|
-
"@vercel/python": "
|
|
78
|
-
"@vercel/redwood": "
|
|
79
|
-
"@vercel/remix-builder": "
|
|
80
|
-
"@vercel/ruby": "
|
|
81
|
-
"@vercel/rust": "
|
|
82
|
-
"@vercel/static-build": "
|
|
64
|
+
"@vercel/backends": "23.0.0",
|
|
65
|
+
"@vercel/container": "23.0.0",
|
|
66
|
+
"@vercel/elysia": "23.0.0",
|
|
67
|
+
"@vercel/express": "23.0.0",
|
|
68
|
+
"@vercel/fastify": "23.0.0",
|
|
69
|
+
"@vercel/go": "26.0.0",
|
|
70
|
+
"@vercel/h3": "23.0.0",
|
|
71
|
+
"@vercel/hono": "23.0.0",
|
|
72
|
+
"@vercel/hydrogen": "24.0.0",
|
|
73
|
+
"@vercel/koa": "23.0.0",
|
|
74
|
+
"@vercel/nestjs": "23.0.0",
|
|
75
|
+
"@vercel/next": "27.0.0",
|
|
76
|
+
"@vercel/node": "28.0.0",
|
|
77
|
+
"@vercel/python": "29.0.0",
|
|
78
|
+
"@vercel/redwood": "25.0.0",
|
|
79
|
+
"@vercel/remix-builder": "28.0.0",
|
|
80
|
+
"@vercel/ruby": "25.0.0",
|
|
81
|
+
"@vercel/rust": "24.0.0",
|
|
82
|
+
"@vercel/static-build": "25.0.0"
|
|
83
83
|
},
|
|
84
84
|
"devDependencies": {
|
|
85
85
|
"@bufbuild/protobuf": "2.12.0",
|
|
@@ -195,6 +195,7 @@
|
|
|
195
195
|
"rimraf": "3.0.2",
|
|
196
196
|
"semver": "5.7.2",
|
|
197
197
|
"serve-handler": "6.1.1",
|
|
198
|
+
"signal-exit": "3.0.7",
|
|
198
199
|
"split2": "4.2.0",
|
|
199
200
|
"strip-ansi": "6.0.1",
|
|
200
201
|
"supports-hyperlinks": "3.0.0",
|
|
@@ -213,37 +214,36 @@
|
|
|
213
214
|
"ws": "8.18.0",
|
|
214
215
|
"xdg-app-paths": "5.1.0",
|
|
215
216
|
"yauzl-promise": "2.1.3",
|
|
216
|
-
"@vercel-internals/builder-orchestration": "1.0.
|
|
217
|
-
"@vercel-internals/constants": "1.0.4",
|
|
218
|
-
"@vercel-internals/cli-builder-integration": "1.0.31",
|
|
217
|
+
"@vercel-internals/builder-orchestration": "1.0.30",
|
|
219
218
|
"@vercel-internals/get-package-json": "1.0.0",
|
|
220
|
-
"@vercel-internals/
|
|
219
|
+
"@vercel-internals/cli-builder-integration": "1.0.33",
|
|
220
|
+
"@vercel-internals/constants": "1.0.4",
|
|
221
221
|
"@vercel-internals/local-schedules": "0.0.4",
|
|
222
|
-
"@vercel-internals/
|
|
223
|
-
"@vercel-internals/
|
|
224
|
-
"@vercel/
|
|
222
|
+
"@vercel-internals/runtimes": "1.2.4",
|
|
223
|
+
"@vercel-internals/service-topology": "1.0.28",
|
|
224
|
+
"@vercel-internals/types": "3.0.32",
|
|
225
|
+
"@vercel/client": "18.10.0",
|
|
225
226
|
"@vercel/error-utils": "2.2.1",
|
|
226
227
|
"@vercel/frameworks": "3.35.0",
|
|
227
|
-
"@vercel/fs-detectors": "7.10.2",
|
|
228
228
|
"@vercel/routing-utils": "6.6.0",
|
|
229
|
-
"@vercel/
|
|
229
|
+
"@vercel/fs-detectors": "7.11.1",
|
|
230
|
+
"@vercel/functions": "3.10.4"
|
|
230
231
|
},
|
|
231
232
|
"optionalDependencies": {
|
|
232
|
-
"@vercel/
|
|
233
|
-
"@vercel/vc-native-darwin-
|
|
234
|
-
"@vercel/vc-native-
|
|
235
|
-
"@vercel/vc-native-linux-arm64
|
|
236
|
-
"@vercel/vc-native-linux-
|
|
237
|
-
"@vercel/vc-native-linux-x64
|
|
238
|
-
"@vercel/vc-native-
|
|
239
|
-
"@vercel/vc-native-win32-x64": "65.2.0"
|
|
233
|
+
"@vercel/cli-support": "65.4.0",
|
|
234
|
+
"@vercel/vc-native-darwin-arm64": "65.4.0",
|
|
235
|
+
"@vercel/vc-native-darwin-x64": "65.4.0",
|
|
236
|
+
"@vercel/vc-native-linux-arm64": "65.4.0",
|
|
237
|
+
"@vercel/vc-native-linux-arm64-musl": "65.4.0",
|
|
238
|
+
"@vercel/vc-native-linux-x64": "65.4.0",
|
|
239
|
+
"@vercel/vc-native-linux-x64-musl": "65.4.0"
|
|
240
240
|
},
|
|
241
241
|
"scripts": {
|
|
242
242
|
"test": "node scripts/test.mjs --run",
|
|
243
243
|
"test-e2e": "node scripts/test.mjs --run test/e2e-",
|
|
244
244
|
"test-e2e-node-all-versions": "rimraf test/fixtures/integration && vitest run --config ./vitest.config.mts test/integration-1.test.ts test/integration-2.test.ts test/integration-3.test.ts test/integration-link-env-pull.test.ts",
|
|
245
245
|
"test-dev": "vitest run --config ./vitest.config.mts test/dev/",
|
|
246
|
-
"test-testserver": "node scripts/
|
|
246
|
+
"test-testserver": "node scripts/testserver/main.mjs -- vitest run --config ./vitest.testserver.config.mts",
|
|
247
247
|
"coverage": "codecov",
|
|
248
248
|
"build": "node scripts/build.mjs",
|
|
249
249
|
"build-binary": "node scripts/build-binary.mjs",
|
|
@@ -1,8 +0,0 @@
|
|
|
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{parseTeamRefs,teamRefBody}from"./chunk-LSF7FY6X.js";import{repositoryPermissionsPath}from"./chunk-DFVNL5ML.js";import{emitVcrArgParseError,resolveVcrScope,validateVcrJsonOutput}from"./chunk-4MTD47Y2.js";import{outputError}from"./chunk-RW3X523R.js";import{require_async_sema}from"./chunk-NZ2TFADV.js";import"./chunk-BUJITHGZ.js";import"./chunk-FBYA6LLM.js";import"./chunk-GD7AV7BO.js";import"./chunk-SCV7XEEO.js";import{permissionsAddSubcommand}from"./chunk-3AYYFYZG.js";import{printError}from"./chunk-G4T7VBGN.js";import"./chunk-F6FTWDLS.js";import"./chunk-MXTC4ZAQ.js";import"./chunk-FGFLTLEA.js";import{AGENT_REASON,buildCommandWithGlobalFlags,outputAgentError}from"./chunk-DGYHWXD2.js";import"./chunk-IUXSJWL3.js";import"./chunk-VBWQRK3O.js";import"./chunk-ADLBLGT3.js";import"./chunk-BBKEP7RO.js";import"./chunk-4NTBYNFR.js";import{parseArguments}from"./chunk-VOCZ34ON.js";import"./chunk-F53OKXYI.js";import{getFlagsSpecification}from"./chunk-AWMQGOS2.js";import"./chunk-FUX6LKNP.js";import"./chunk-OPORM35X.js";import"./chunk-4SAVH3H7.js";import{isAPIError}from"./chunk-6VH56CX2.js";import{packageName}from"./chunk-JESNVRVR.js";import{output_manager_default}from"./chunk-XP3FT56R.js";import"./chunk-BLUPZPAS.js";import"./chunk-RM3ZDRYE.js";import"./chunk-OO572JUC.js";import"./chunk-D3AHZ5LI.js";import"./chunk-2GHZGOWT.js";import"./chunk-YHPPP3SF.js";import"./chunk-NB2WLB3J.js";import"./chunk-ISWW3DKF.js";import"./chunk-BRQUZ5NC.js";import{__toESM}from"./chunk-BZENIQ7N.js";var import_async_sema=__toESM(require_async_sema(),1);var USAGE="vcr permissions <repository> add <team>[,<team>...]";async function add(client,argv,telemetry){let parsedArgs;try{parsedArgs=parseArguments(argv,getFlagsSpecification(permissionsAddSubcommand.options))}catch(err){return emitVcrArgParseError(client,err,USAGE),printError(err),2}let fr=validateVcrJsonOutput(client,parsedArgs.flags);if(typeof fr=="number")return fr;let repository=parsedArgs.args[0],teamRefs=parseTeamRefs(parsedArgs.args.slice(2)),project=parsedArgs.flags["--project"];if(telemetry.trackCliOptionProject(project),telemetry.trackCliOptionFormat(parsedArgs.flags["--format"]),teamRefs.length===0)return outputAgentError(client,{status:"error",reason:AGENT_REASON.MISSING_ARGUMENTS,message:`Missing team. Example: ${packageName} vcr permissions ${repository} add team_1a2b3c4d`,next:[{command:buildCommandWithGlobalFlags(client.argv,USAGE),when:"Replace <team> with a team id or slug (comma-separate multiple teams)"}]},2),outputError(client,fr.jsonOutput,"MISSING_ARGUMENTS",`Usage: \`vercel ${USAGE}\``);let scope=await resolveVcrScope(client,{project,jsonOutput:fr.jsonOutput});if(typeof scope=="number")return scope;let path=repositoryPermissionsPath(scope,repository),added=[],failed=[];output_manager_default.spinner(`Sharing ${repository} with ${teamRefs.length===1?teamRefs[0]:`${teamRefs.length} teams`}...`);let sema=new import_async_sema.default(10),results;try{results=await Promise.all(teamRefs.map(async team=>{await sema.acquire();try{let result=await client.fetch(path,{method:"POST",body:teamRefBody(team)});return{ok:!0,team,permission:result.permission}}catch(err){if(!isAPIError(err))throw err;let message=err.serverMessage||`API error (${err.status}).`;return{ok:!1,team,failure:{team,code:err.code||"API_ERROR",message}}}finally{sema.release()}}))}finally{output_manager_default.stopSpinner()}for(let result of results)result.ok?(added.push(result.permission),fr.jsonOutput||output_manager_default.success(`Shared ${repository} with ${result.permission?.teamSlug??result.team}`)):(failed.push(result.failure),fr.jsonOutput||output_manager_default.error(`Failed to share ${repository} with ${result.team}: ${result.failure.message}`));return failed.length>0&&outputAgentError(client,{status:"error",reason:AGENT_REASON.API_ERROR,message:`Failed to share ${repository} with ${failed.map(f=>`${f.team} (${f.message})`).join(", ")}`},1),fr.jsonOutput&&client.stdout.write(`${JSON.stringify({permissions:added,failed},null,2)}
|
|
8
|
-
`),failed.length>0?1:0}export{add as default};
|
|
@@ -1,8 +0,0 @@
|
|
|
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{emitVcrArgParseError,handleVcrApiError,resolveVcrScope,validateVcrJsonOutput}from"./chunk-4MTD47Y2.js";import{outputError}from"./chunk-RW3X523R.js";import"./chunk-BUJITHGZ.js";import"./chunk-FBYA6LLM.js";import"./chunk-GD7AV7BO.js";import"./chunk-SCV7XEEO.js";import{addSubcommand}from"./chunk-ABZEMNDR.js";import"./chunk-3AYYFYZG.js";import"./chunk-76KGQU2G.js";import"./chunk-UNEGQPD3.js";import{printError}from"./chunk-G4T7VBGN.js";import"./chunk-F6FTWDLS.js";import"./chunk-MXTC4ZAQ.js";import"./chunk-FGFLTLEA.js";import{AGENT_REASON,buildCommandWithGlobalFlags,outputAgentError}from"./chunk-DGYHWXD2.js";import"./chunk-IUXSJWL3.js";import"./chunk-VBWQRK3O.js";import"./chunk-ADLBLGT3.js";import"./chunk-BBKEP7RO.js";import"./chunk-4NTBYNFR.js";import{parseArguments}from"./chunk-VOCZ34ON.js";import"./chunk-F53OKXYI.js";import{getFlagsSpecification}from"./chunk-AWMQGOS2.js";import"./chunk-FUX6LKNP.js";import"./chunk-OPORM35X.js";import"./chunk-4SAVH3H7.js";import{isAPIError}from"./chunk-6VH56CX2.js";import{packageName}from"./chunk-JESNVRVR.js";import{output_manager_default}from"./chunk-XP3FT56R.js";import"./chunk-BLUPZPAS.js";import"./chunk-RM3ZDRYE.js";import"./chunk-OO572JUC.js";import"./chunk-D3AHZ5LI.js";import"./chunk-2GHZGOWT.js";import"./chunk-YHPPP3SF.js";import"./chunk-NB2WLB3J.js";import"./chunk-ISWW3DKF.js";import"./chunk-BRQUZ5NC.js";import"./chunk-BZENIQ7N.js";async function add(client,argv,telemetry){let parsedArgs;try{parsedArgs=parseArguments(argv,getFlagsSpecification(addSubcommand.options))}catch(err){return emitVcrArgParseError(client,err,"vcr create <name> --project <name-or-id>"),printError(err),2}let fr=validateVcrJsonOutput(client,parsedArgs.flags);if(typeof fr=="number")return fr;let name=parsedArgs.args[0],project=parsedArgs.flags["--project"];if(telemetry.trackCliOptionProject(project),telemetry.trackCliOptionFormat(parsedArgs.flags["--format"]),!name)return outputAgentError(client,{status:"error",reason:AGENT_REASON.MISSING_ARGUMENTS,message:`Missing repository name. Example: ${packageName} vcr create <name>`,next:[{command:buildCommandWithGlobalFlags(client.argv,"vcr create <name>"),when:"Replace <name> with the repository name to create"}]},2),outputError(client,fr.jsonOutput,"MISSING_ARGUMENTS","Usage: `vercel vcr create <name>`");let scope=await resolveVcrScope(client,{project,jsonOutput:fr.jsonOutput});if(typeof scope=="number")return scope;let path=`/v1/vcr/repository?teamId=${encodeURIComponent(scope.teamId)}`;output_manager_default.spinner("Creating repository...");try{let created=await client.fetch(path,{method:"POST",body:{projectId:scope.projectId,name}});return fr.jsonOutput?client.stdout.write(`${JSON.stringify(created,null,2)}
|
|
8
|
-
`):output_manager_default.success(`Created repository ${created.repository?.name??name}`),0}catch(err){if(isAPIError(err))return handleVcrApiError(client,err,fr.jsonOutput,{retry:{command:buildCommandWithGlobalFlags(client.argv,"vcr ls"),when:"List existing repositories (a name conflict means it already exists)"}});throw err}finally{output_manager_default.stopSpinner()}}export{add as default};
|
|
@@ -1,8 +0,0 @@
|
|
|
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{printRuleMutationReceipt}from"./chunk-SXOSF4O6.js";import"./chunk-3XW7N4W3.js";import{resolveRulesProject,resolveRulesTeam}from"./chunk-JVKIWEPJ.js";import"./chunk-LH7X2ZJQ.js";import{emitRulesArgParseError,getBodyType,handleRulesApiError,outputRulesError,readRuleBody,rulesCollectionPath}from"./chunk-EEEYN6B4.js";import"./chunk-GHAY4PSD.js";import"./chunk-RW3X523R.js";import"./chunk-ID663OJ7.js";import"./chunk-HRR57QNP.js";import"./chunk-GZNDA6SV.js";import"./chunk-PFD7LETF.js";import{monitorsAddSubcommand}from"./chunk-QZX7VG2V.js";import"./chunk-773GOZIR.js";import{printError}from"./chunk-G4T7VBGN.js";import"./chunk-67GZ5REA.js";import"./chunk-BS32OUOC.js";import"./chunk-F6FTWDLS.js";import"./chunk-MXTC4ZAQ.js";import"./chunk-FGFLTLEA.js";import"./chunk-DGYHWXD2.js";import"./chunk-IUXSJWL3.js";import"./chunk-VBWQRK3O.js";import"./chunk-ADLBLGT3.js";import"./chunk-BBKEP7RO.js";import"./chunk-4NTBYNFR.js";import{parseArguments}from"./chunk-VOCZ34ON.js";import"./chunk-F53OKXYI.js";import{getFlagsSpecification,validateJsonOutput}from"./chunk-AWMQGOS2.js";import"./chunk-FUX6LKNP.js";import"./chunk-OPORM35X.js";import"./chunk-4SAVH3H7.js";import{isAPIError}from"./chunk-6VH56CX2.js";import"./chunk-JESNVRVR.js";import{output_manager_default}from"./chunk-XP3FT56R.js";import"./chunk-BLUPZPAS.js";import"./chunk-RM3ZDRYE.js";import"./chunk-OO572JUC.js";import"./chunk-D3AHZ5LI.js";import"./chunk-2GHZGOWT.js";import"./chunk-YHPPP3SF.js";import"./chunk-NB2WLB3J.js";import"./chunk-ISWW3DKF.js";import"./chunk-BRQUZ5NC.js";import"./chunk-BZENIQ7N.js";function applyScopeFlag(client,body,type,scope,flags,jsonOutput){if(Object.hasOwn(body,"ruleScope"))return flags["--project"]||flags["--all"]?outputRulesError(client,jsonOutput,"SCOPE_CONFLICT","Specify monitor scope either in the body or with --project/--all, not both."):void 0;if(flags["--project"]){body.ruleScope=type==="custom"?{type:"project",projectId:scope.projectId}:{type:"include",projectIds:[scope.projectId]};return}if(flags["--all"]){if(type==="custom")return outputRulesError(client,jsonOutput,"INVALID_SCOPE","Custom monitors must target one project. Use --project <name-or-id>.");body.ruleScope={type:"all"};return}return outputRulesError(client,jsonOutput,"MISSING_SCOPE","Missing monitor scope. Add ruleScope to the body, or pass --project or --all.")}async function resolveCreateScope(client,flags,jsonOutput){return flags["--project"]&&flags["--all"]?outputRulesError(client,jsonOutput,"MUTUAL_EXCLUSIVITY","Cannot specify both --all and --project. Use one or the other."):flags["--project"]?resolveRulesProject(client,flags["--project"],jsonOutput,"monitors add"):resolveRulesTeam(client,jsonOutput)}async function add(client,argv,api){let parsedArgs;try{parsedArgs=parseArguments(argv,getFlagsSpecification(monitorsAddSubcommand.options))}catch(error){return emitRulesArgParseError(client,error,"monitors add --project <name-or-id> --body <path>"),printError(error),2}let flags=parsedArgs.flags,format=validateJsonOutput(flags);if(!format.valid)return outputRulesError(client,!1,"INVALID_ARGUMENTS",format.error);if(!flags["--body"])return outputRulesError(client,format.jsonOutput,"MISSING_ARGUMENTS","Missing required flag: --body <PATH>.");let body=readRuleBody(client,flags["--body"],format.jsonOutput);if(typeof body=="number")return body;let type=getBodyType(body);if(!type)return outputRulesError(client,format.jsonOutput,"INVALID_RULE_TYPE","Create body must set a supported monitor type.");if(Object.hasOwn(body,"ruleScope")&&(flags["--project"]||flags["--all"]))return outputRulesError(client,format.jsonOutput,"SCOPE_CONFLICT","Specify monitor scope either in the body or with --project/--all, not both.");if(type==="custom"&&flags["--all"])return outputRulesError(client,format.jsonOutput,"INVALID_SCOPE","Custom monitors must target one project. Use --project <name-or-id>.");let scope=await resolveCreateScope(client,flags,format.jsonOutput);if(typeof scope=="number")return scope;let scopeError=applyScopeFlag(client,body,type,scope,flags,format.jsonOutput);if(scopeError!==void 0)return scopeError;output_manager_default.spinner("Creating monitor\u2026");try{let response=await client.fetch(rulesCollectionPath(api,scope.teamId),{method:"POST",body});return format.jsonOutput?client.stdout.write(`${JSON.stringify(response,null,2)}
|
|
8
|
-
`):printRuleMutationReceipt("Created",response[api.itemKey],client.argv),0}catch(error){if(isAPIError(error))return handleRulesApiError(client,error,format.jsonOutput);throw error}finally{output_manager_default.stopSpinner()}}export{add as default};
|
|
@@ -1,7 +0,0 @@
|
|
|
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{DEFAULT_TAG,buildRepositoryReference,parseNameArg,validateImageParts}from"./chunk-HEGJZJO7.js";import{VCR_ENGINES,emitVcrArgParseError,isBuildxAvailable,isEngineInstalled,pushCompressionArgs,reportEngineCommandFailure,reportEnginePushFailure,resolveRegistry,resolveVcrScope,runEngine,splitPassthrough,validateVcrChoice}from"./chunk-4MTD47Y2.js";import{outputError}from"./chunk-RW3X523R.js";import"./chunk-BUJITHGZ.js";import"./chunk-FBYA6LLM.js";import"./chunk-GD7AV7BO.js";import"./chunk-SCV7XEEO.js";import{buildSubcommand}from"./chunk-ABZEMNDR.js";import"./chunk-3AYYFYZG.js";import"./chunk-76KGQU2G.js";import"./chunk-UNEGQPD3.js";import{printError}from"./chunk-G4T7VBGN.js";import"./chunk-F6FTWDLS.js";import"./chunk-MXTC4ZAQ.js";import"./chunk-FGFLTLEA.js";import{AGENT_REASON,buildCommandWithGlobalFlags,outputAgentError}from"./chunk-DGYHWXD2.js";import"./chunk-IUXSJWL3.js";import"./chunk-VBWQRK3O.js";import"./chunk-ADLBLGT3.js";import"./chunk-BBKEP7RO.js";import"./chunk-4NTBYNFR.js";import{parseArguments}from"./chunk-VOCZ34ON.js";import"./chunk-F53OKXYI.js";import{getFlagsSpecification}from"./chunk-AWMQGOS2.js";import"./chunk-FUX6LKNP.js";import"./chunk-OPORM35X.js";import"./chunk-4SAVH3H7.js";import"./chunk-6VH56CX2.js";import"./chunk-JESNVRVR.js";import{output_manager_default}from"./chunk-XP3FT56R.js";import"./chunk-BLUPZPAS.js";import"./chunk-RM3ZDRYE.js";import"./chunk-OO572JUC.js";import"./chunk-D3AHZ5LI.js";import"./chunk-2GHZGOWT.js";import"./chunk-YHPPP3SF.js";import"./chunk-NB2WLB3J.js";import"./chunk-ISWW3DKF.js";import"./chunk-BRQUZ5NC.js";import"./chunk-BZENIQ7N.js";var DEFAULT_PLATFORM="linux/amd64";async function build(client,telemetry){let{own,passthrough}=splitPassthrough(client.argv),parsedArgs;try{parsedArgs=parseArguments(own,getFlagsSpecification(buildSubcommand.options))}catch(err){return emitVcrArgParseError(client,err,"vcr build <engine> [path] [name[:tag]]"),printError(err),2}let[engineArg,pathArg,nameArg]=parsedArgs.args.slice(2),project=parsedArgs.flags["--project"],platform=parsedArgs.flags["--platform"],push=!!parsedArgs.flags["--push"];if(telemetry.trackCliArgumentEngine(engineArg),telemetry.trackCliArgumentPath(pathArg),telemetry.trackCliArgumentName(nameArg),telemetry.trackCliOptionProject(project),telemetry.trackCliOptionPlatform(platform),telemetry.trackCliFlagPush(push),!engineArg){let message=`Missing engine. Choose one of: ${VCR_ENGINES.join(", ")}.`;return outputAgentError(client,{status:"error",reason:AGENT_REASON.MISSING_ARGUMENTS,message,next:[{command:buildCommandWithGlobalFlags(client.argv,"vcr build docker"),when:"Replace docker with the container tool you use"}]},2),outputError(client,!1,"MISSING_ARGUMENTS",message)}let choiceError=validateVcrChoice(client,"engine",engineArg,VCR_ENGINES,!1);if(typeof choiceError=="number")return choiceError;let engine=engineArg;if(!isEngineInstalled(engine)){let message=`\`${engine}\` is not installed or not on your PATH. Install it and try again.`;return outputAgentError(client,{status:"error",reason:"engine_not_found",message},1),outputError(client,!1,"ENGINE_NOT_FOUND",message)}let scope=await resolveVcrScope(client,{project,jsonOutput:!1});if(typeof scope=="number")return scope;let parsed=parseNameArg(nameArg,scope.projectName);if("error"in parsed)return outputAgentError(client,{status:"error",reason:AGENT_REASON.INVALID_ARGUMENTS,message:parsed.error},2),outputError(client,!1,"INVALID_ARGUMENTS",parsed.error);let validationError=validateImageParts(parsed);if(validationError)return outputAgentError(client,{status:"error",reason:AGENT_REASON.INVALID_ARGUMENTS,message:validationError},2),outputError(client,!1,"INVALID_ARGUMENTS",validationError);let ref=`${buildRepositoryReference({registry:resolveRegistry(),teamSlug:scope.teamSlug,projectName:scope.projectName,repository:parsed.repository})}:${parsed.tag??DEFAULT_TAG}`,contextPath=pathArg??".",buildPlatform=platform??DEFAULT_PLATFORM;if(push&&engine==="docker"&&await isBuildxAvailable()){let outputSpec=`type=image,name=${ref},push=true,oci-mediatypes=true,compression=zstd,compression-level=3,force-compression=true`,engineArgs2=["buildx","build","--platform",buildPlatform,"--output",outputSpec,...passthrough,contextPath];output_manager_default.log(`Running: ${engine} ${engineArgs2.join(" ")}`);let result2=await runEngine(engine,engineArgs2,{cwd:client.cwd,captureStderr:!0});return result2.exitCode!==0?reportEnginePushFailure(client,engine,"buildx build",result2):(output_manager_default.success(`Built and pushed ${ref} (zstd compression)`),0)}push&&engine==="docker"&&output_manager_default.warn("Docker Buildx is not available; building and pushing without zstd compression. Install Buildx for smaller, faster image pushes.");let engineArgs=["build","--platform",buildPlatform,"--tag",ref,...passthrough,contextPath];output_manager_default.log(`Running: ${engine} ${engineArgs.join(" ")}`);let result=await runEngine(engine,engineArgs,{cwd:client.cwd});if(result.exitCode!==0)return reportEngineCommandFailure(client,engine,"build",result);if(!push)return output_manager_default.success(`Built ${ref}`),output_manager_default.log(`Push it with \`${buildCommandWithGlobalFlags(client.argv,`vcr push ${engine}${nameArg?` ${nameArg}`:""}`)}\`.`),0;let pushArgs=["push",...pushCompressionArgs(engine),ref];output_manager_default.log(`Running: ${engine} ${pushArgs.join(" ")}`);let pushResult=await runEngine(engine,pushArgs,{cwd:client.cwd,captureStderr:!0});if(pushResult.exitCode!==0)return reportEnginePushFailure(client,engine,"push",pushResult);let compressed=engine!=="docker";return output_manager_default.success(`Built and pushed ${ref}${compressed?" (zstd compression)":""}`),0}export{build as default};
|