@unbrained/pm-cli 2026.6.6 → 2026.6.7
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/CHANGELOG.md +37 -0
- package/README.md +5 -1
- package/dist/cli/commander-usage.js +74 -4
- package/dist/cli/commander-usage.js.map +1 -1
- package/dist/cli/commands/aggregate.d.ts +8 -0
- package/dist/cli/commands/aggregate.js +84 -7
- package/dist/cli/commands/aggregate.js.map +1 -1
- package/dist/cli/commands/calendar.js +10 -3
- package/dist/cli/commands/calendar.js.map +1 -1
- package/dist/cli/commands/close-many.js +13 -10
- package/dist/cli/commands/close-many.js.map +1 -1
- package/dist/cli/commands/close.d.ts +1 -1
- package/dist/cli/commands/close.js +20 -10
- package/dist/cli/commands/close.js.map +1 -1
- package/dist/cli/commands/completion.js +68 -13
- package/dist/cli/commands/completion.js.map +1 -1
- package/dist/cli/commands/config.d.ts +5 -4
- package/dist/cli/commands/config.js +50 -2
- package/dist/cli/commands/config.js.map +1 -1
- package/dist/cli/commands/contracts.js +4 -3
- package/dist/cli/commands/contracts.js.map +1 -1
- package/dist/cli/commands/copy.d.ts +14 -0
- package/dist/cli/commands/copy.js +153 -0
- package/dist/cli/commands/copy.js.map +1 -0
- package/dist/cli/commands/extension/doctor.js +62 -2
- package/dist/cli/commands/extension/doctor.js.map +1 -1
- package/dist/cli/commands/extension/install-sources.d.ts +8 -0
- package/dist/cli/commands/extension/install-sources.js +82 -2
- package/dist/cli/commands/extension/install-sources.js.map +1 -1
- package/dist/cli/commands/extension.d.ts +29 -0
- package/dist/cli/commands/extension.js +61 -2
- package/dist/cli/commands/extension.js.map +1 -1
- package/dist/cli/commands/get.d.ts +9 -0
- package/dist/cli/commands/get.js +23 -2
- package/dist/cli/commands/get.js.map +1 -1
- package/dist/cli/commands/history-compact.d.ts +39 -0
- package/dist/cli/commands/history-compact.js +262 -0
- package/dist/cli/commands/history-compact.js.map +1 -0
- package/dist/cli/commands/index.d.ts +2 -0
- package/dist/cli/commands/index.js +4 -2
- package/dist/cli/commands/index.js.map +1 -1
- package/dist/cli/commands/list.d.ts +2 -0
- package/dist/cli/commands/list.js +87 -9
- package/dist/cli/commands/list.js.map +1 -1
- package/dist/cli/commands/reindex.js +8 -4
- package/dist/cli/commands/reindex.js.map +1 -1
- package/dist/cli/commands/search.d.ts +1 -0
- package/dist/cli/commands/search.js +232 -35
- package/dist/cli/commands/search.js.map +1 -1
- package/dist/cli/error-guidance.js +26 -2
- package/dist/cli/error-guidance.js.map +1 -1
- package/dist/cli/extension-command-help.d.ts +1 -0
- package/dist/cli/extension-command-help.js +3 -2
- package/dist/cli/extension-command-help.js.map +1 -1
- package/dist/cli/help-content.js +10 -2
- package/dist/cli/help-content.js.map +1 -1
- package/dist/cli/main.d.ts +3 -0
- package/dist/cli/main.js +13 -21
- package/dist/cli/main.js.map +1 -1
- package/dist/cli/register-list-query.js +19 -4
- package/dist/cli/register-list-query.js.map +1 -1
- package/dist/cli/register-mutation.js +52 -17
- package/dist/cli/register-mutation.js.map +1 -1
- package/dist/cli/register-operations.js +31 -7
- package/dist/cli/register-operations.js.map +1 -1
- package/dist/cli/register-setup.js +5 -5
- package/dist/cli/register-setup.js.map +1 -1
- package/dist/cli/registration-helpers.js +21 -3
- package/dist/cli/registration-helpers.js.map +1 -1
- package/dist/cli-bundle/chunks/activity-5UROHJ3D.js +16 -0
- package/dist/cli-bundle/chunks/{activity-JM6DTDND.js → activity-YVB3QRTE.js} +11 -11
- package/dist/cli-bundle/chunks/{aggregate-VNAHUNNF.js → aggregate-LH66F75F.js} +87 -17
- package/dist/cli-bundle/chunks/aggregate-LH66F75F.js.map +7 -0
- package/dist/cli-bundle/chunks/{aggregate-GI7WSZPH.js → aggregate-OHSWFQJM.js} +88 -18
- package/dist/cli-bundle/chunks/aggregate-OHSWFQJM.js.map +1 -0
- package/dist/cli-bundle/chunks/{append-WMKRXKCE.js → append-2PPYFAG5.js} +8 -8
- package/dist/cli-bundle/chunks/{append-7H5N64R2.js → append-AUGT5W6J.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-6P6GGMOG.js → chunk-2IF7WLB7.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-T3LC5LKB.js → chunk-2IXCHCLM.js} +5 -6
- package/dist/cli-bundle/chunks/chunk-2IXCHCLM.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-KAG77BY3.js → chunk-2OJHLWBZ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-GXSUPCBV.js → chunk-3A2CMEM7.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-UM2GBHS4.js → chunk-3EOBJOF4.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-Q7SPNHLW.js → chunk-42LOFGJS.js} +91 -16
- package/dist/cli-bundle/chunks/chunk-42LOFGJS.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-PRJCELV4.js → chunk-4CHEG6UK.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-4LL6TK5B.js → chunk-4GHZR3BA.js} +56 -28
- package/dist/cli-bundle/chunks/chunk-4GHZR3BA.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-OZ7NSQHL.js → chunk-5AXMRKN5.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-GCOQW437.js → chunk-6J4K6JLA.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-2RSPZI5H.js → chunk-6RZXO5M2.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-KJ33AOCY.js → chunk-AVJD6VTA.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-TCD3R2PF.js → chunk-B2KZGPM2.js} +39 -8
- package/dist/cli-bundle/chunks/chunk-B2KZGPM2.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-I6BNFU5X.js → chunk-B5RF3IP7.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-RZN6VURO.js → chunk-C5W2UH56.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-3LB74A67.js → chunk-CKLBZHS7.js} +6 -6
- package/dist/cli-bundle/chunks/{chunk-KWU6HG75.js → chunk-CLD3XNCH.js} +91 -10
- package/dist/cli-bundle/chunks/chunk-CLD3XNCH.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-QO7EBBOM.js → chunk-FHHBD7PN.js} +38 -7
- package/dist/cli-bundle/chunks/chunk-FHHBD7PN.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-3VAM3NNM.js → chunk-FY6Z3FYY.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-RWPSOIEE.js → chunk-GNIUOLZ2.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-MITFDD35.js → chunk-GPXQBR3H.js} +12 -12
- package/dist/cli-bundle/chunks/{chunk-2VBQ6ZXS.js → chunk-GUZBNB3G.js} +27 -5
- package/dist/cli-bundle/chunks/chunk-GUZBNB3G.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-I2HSTRJF.js → chunk-H7EO3QA3.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-77GFDHGF.js → chunk-HLC3KTLP.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-OVQCEJPG.js → chunk-HMMMWBK2.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-KJE2FOS4.js → chunk-HRMHZ4RV.js} +26 -4
- package/dist/cli-bundle/chunks/chunk-HRMHZ4RV.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-XLTD2HN3.js → chunk-HV5SSZXF.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-GU2ZJ2VV.js → chunk-IMCJBN2Q.js} +23 -14
- package/dist/cli-bundle/chunks/chunk-IMCJBN2Q.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-2HVRUSQA.js → chunk-KNGVP5WJ.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-ECCMVXGM.js → chunk-KR6R465K.js} +304 -215
- package/dist/cli-bundle/chunks/chunk-KR6R465K.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-3BWOVLTH.js → chunk-LI65XLJR.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-NUZ5HKR4.js → chunk-LIN2BPJ7.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-LMTOY5HE.js +112 -0
- package/dist/cli-bundle/chunks/chunk-LMTOY5HE.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-N7ACFE26.js → chunk-LQHBENVW.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-23YFZ3IG.js → chunk-LXO6V66E.js} +14 -14
- package/dist/cli-bundle/chunks/{chunk-PDDFYW4X.js → chunk-M2PW7EZU.js} +26 -7
- package/dist/cli-bundle/chunks/chunk-M2PW7EZU.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-PIU6RSL3.js → chunk-MOYM2C3J.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-PROOHX4K.js → chunk-MWRS7Z4P.js} +94 -13
- package/dist/cli-bundle/chunks/chunk-MWRS7Z4P.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-FRAUKRU2.js → chunk-NHR2QXXZ.js} +24 -15
- package/dist/cli-bundle/chunks/chunk-NHR2QXXZ.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-IJGCZSIQ.js → chunk-NQL32HQ5.js} +12 -12
- package/dist/cli-bundle/chunks/{chunk-52MAOQ6J.js → chunk-O7HSSFCC.js} +65 -16
- package/dist/cli-bundle/chunks/chunk-O7HSSFCC.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-6ER6DXH5.js → chunk-OKSKJKHX.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-IOR7LGF4.js → chunk-QQL5QSTZ.js} +88 -7
- package/dist/cli-bundle/chunks/chunk-QQL5QSTZ.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-2VVCGBNV.js → chunk-R3V3YCMH.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-UBOPJT3S.js → chunk-RVPTZKBC.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-WKY2IBOQ.js → chunk-SFFVGNHC.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-WSMOSYRD.js → chunk-SQPKRA54.js} +14 -14
- package/dist/cli-bundle/chunks/chunk-THDEID2Z.js +115 -0
- package/dist/cli-bundle/chunks/chunk-THDEID2Z.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-W7XABV4H.js → chunk-TINUJMWN.js} +92 -17
- package/dist/cli-bundle/chunks/chunk-TINUJMWN.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-YL2DJGYS.js → chunk-TNPBPNII.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-XTGLRY2Y.js → chunk-TP4DDY27.js} +6 -6
- package/dist/cli-bundle/chunks/{chunk-AY43SBIN.js → chunk-TYJJOTUA.js} +6 -6
- package/dist/cli-bundle/chunks/{chunk-LCM63IXU.js → chunk-UAQOQ7IE.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-BQHUILZS.js → chunk-UEWA73ZZ.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-PO3GSVFV.js → chunk-UIIQC5YO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-U5SXYXSY.js → chunk-UJUT6AHZ.js} +241 -35
- package/dist/cli-bundle/chunks/chunk-UJUT6AHZ.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-HZGUAH22.js → chunk-UT6WFXW2.js} +6 -7
- package/dist/cli-bundle/chunks/chunk-UT6WFXW2.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-LB3RUL2N.js → chunk-UYQ7HXH4.js} +10 -6
- package/dist/cli-bundle/chunks/chunk-UYQ7HXH4.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-R6UFP2GE.js → chunk-V6EYFTRL.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-3FI4SEFT.js → chunk-WAA7UI6M.js} +58 -30
- package/dist/cli-bundle/chunks/chunk-WAA7UI6M.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-AO442XLN.js → chunk-WCQZBDDH.js} +10 -6
- package/dist/cli-bundle/chunks/{chunk-AO442XLN.js.map → chunk-WCQZBDDH.js.map} +2 -2
- package/dist/cli-bundle/chunks/{chunk-SKJWX3QB.js → chunk-WR5567FH.js} +87 -6
- package/dist/cli-bundle/chunks/chunk-WR5567FH.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-XSJCLN2R.js → chunk-WYEXLDDY.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-5SFCOO6B.js → chunk-X4IZKYHP.js} +234 -28
- package/dist/cli-bundle/chunks/chunk-X4IZKYHP.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-E5FJNAZA.js → chunk-X7UHMKPE.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-WOPXVEZP.js → chunk-XS3O2TFJ.js} +27 -8
- package/dist/cli-bundle/chunks/chunk-XS3O2TFJ.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-TPH5XEVD.js → chunk-XYNT7UFP.js} +303 -207
- package/dist/cli-bundle/chunks/chunk-XYNT7UFP.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-GGYWB3Y2.js → chunk-YBZW2QQ7.js} +6 -6
- package/dist/cli-bundle/chunks/{chunk-ME2YH6FN.js → chunk-YO3THIJF.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-5FDATVEZ.js → chunk-YPH4ESA2.js} +66 -17
- package/dist/cli-bundle/chunks/chunk-YPH4ESA2.js.map +1 -0
- package/dist/cli-bundle/chunks/{claim-X2P4IB7J.js → claim-BJ4QMPJC.js} +10 -10
- package/dist/cli-bundle/chunks/{claim-4DBF6RVG.js → claim-KW743OSW.js} +10 -10
- package/dist/cli-bundle/chunks/close-P4ZBKODL.js +13 -0
- package/dist/cli-bundle/chunks/{close-PTYFA45H.js → close-SYHSRZDC.js} +8 -8
- package/dist/cli-bundle/chunks/{close-many-7CGIDPTJ.js → close-many-DBLEYFOY.js} +29 -26
- package/dist/cli-bundle/chunks/close-many-DBLEYFOY.js.map +7 -0
- package/dist/cli-bundle/chunks/{close-many-ERFO6LHR.js → close-many-LAC5VR4G.js} +30 -27
- package/dist/cli-bundle/chunks/close-many-LAC5VR4G.js.map +1 -0
- package/dist/cli-bundle/chunks/{comments-QKBYCWKD.js → comments-JEO6HHVM.js} +10 -10
- package/dist/cli-bundle/chunks/{comments-OONGABK5.js → comments-YT2PQ5DD.js} +10 -10
- package/dist/cli-bundle/chunks/{config-6FXCQKIF.js → config-RZRVS3ZV.js} +127 -11
- package/dist/cli-bundle/chunks/config-RZRVS3ZV.js.map +1 -0
- package/dist/cli-bundle/chunks/{config-U4RZ4CQB.js → config-YJSAAADD.js} +128 -12
- package/dist/cli-bundle/chunks/config-YJSAAADD.js.map +7 -0
- package/dist/cli-bundle/chunks/{context-FYYJGFWS.js → context-LGYEEKAW.js} +14 -14
- package/dist/cli-bundle/chunks/{context-FYYJGFWS.js.map → context-LGYEEKAW.js.map} +2 -2
- package/dist/cli-bundle/chunks/{context-YMJ3Z2HQ.js → context-ZUH5IOOI.js} +15 -15
- package/dist/cli-bundle/chunks/context-ZUH5IOOI.js.map +1 -0
- package/dist/cli-bundle/chunks/{contracts-RFSPGVVJ.js → contracts-YXJ6NXKH.js} +7 -5
- package/dist/cli-bundle/chunks/contracts-YXJ6NXKH.js.map +7 -0
- package/dist/cli-bundle/chunks/{contracts-QDB6OMLQ.js → contracts-ZIBXROPE.js} +8 -6
- package/dist/cli-bundle/chunks/contracts-ZIBXROPE.js.map +1 -0
- package/dist/cli-bundle/chunks/copy-BZALX5MQ.js +182 -0
- package/dist/cli-bundle/chunks/copy-BZALX5MQ.js.map +1 -0
- package/dist/cli-bundle/chunks/copy-YPWEIAPD.js +185 -0
- package/dist/cli-bundle/chunks/copy-YPWEIAPD.js.map +7 -0
- package/dist/cli-bundle/chunks/create-4DS2QWQC.js +27 -0
- package/dist/cli-bundle/chunks/{create-I5L4EYYZ.js → create-CF7EVRX7.js} +13 -13
- package/dist/cli-bundle/chunks/{delete-7HPGI4GZ.js → delete-KR4VBWVE.js} +7 -7
- package/dist/cli-bundle/chunks/{delete-VXUPH5RS.js → delete-XLZRTRKR.js} +7 -7
- package/dist/cli-bundle/chunks/{deps-JSRRWC3Z.js → deps-2YTXD3VM.js} +7 -7
- package/dist/cli-bundle/chunks/{deps-SCZIFK2Z.js → deps-GZMFMTGS.js} +7 -7
- package/dist/cli-bundle/chunks/{docs-GJK6K4VP.js → docs-SLROFEQ4.js} +9 -9
- package/dist/cli-bundle/chunks/{docs-WW4N3MBM.js → docs-ZHISRR2D.js} +9 -9
- package/dist/cli-bundle/chunks/{extension-J7IBMFTD.js → extension-3C7OOI4F.js} +8 -6
- package/dist/cli-bundle/chunks/{extension-VDY2U33M.js → extension-XYCUXICD.js} +8 -6
- package/dist/cli-bundle/chunks/{files-ISZJGILQ.js → files-FUWF2FYJ.js} +9 -9
- package/dist/cli-bundle/chunks/{files-WKOD326U.js → files-J4I5IU4O.js} +9 -9
- package/dist/cli-bundle/chunks/{gc-JDVJ6OQ2.js → gc-34NXSNSN.js} +3 -3
- package/dist/cli-bundle/chunks/{gc-ULPVWMTN.js → gc-SPIIZX3A.js} +3 -3
- package/dist/cli-bundle/chunks/{get-RV37HT3G.js → get-SZKNRHMA.js} +34 -12
- package/dist/cli-bundle/chunks/get-SZKNRHMA.js.map +1 -0
- package/dist/cli-bundle/chunks/{get-WXU6WI5P.js → get-VITKYP6S.js} +33 -11
- package/dist/cli-bundle/chunks/get-VITKYP6S.js.map +7 -0
- package/dist/cli-bundle/chunks/{health-6L6EH4WR.js → health-4SNTA2TF.js} +12 -11
- package/dist/cli-bundle/chunks/{health-6L6EH4WR.js.map → health-4SNTA2TF.js.map} +1 -1
- package/dist/cli-bundle/chunks/{health-LOI2HHKB.js → health-7G3EPM57.js} +14 -13
- package/dist/cli-bundle/chunks/{health-LOI2HHKB.js.map → health-7G3EPM57.js.map} +1 -1
- package/dist/cli-bundle/chunks/{history-PKN67D5O.js → history-SDAWYZR3.js} +10 -10
- package/dist/cli-bundle/chunks/history-YDUEILKP.js +20 -0
- package/dist/cli-bundle/chunks/history-compact-DMW536VH.js +287 -0
- package/dist/cli-bundle/chunks/history-compact-DMW536VH.js.map +1 -0
- package/dist/cli-bundle/chunks/history-compact-POTZGG7K.js +290 -0
- package/dist/cli-bundle/chunks/history-compact-POTZGG7K.js.map +7 -0
- package/dist/cli-bundle/chunks/{history-redact-V4FOJGS7.js → history-redact-EPJ7GENL.js} +11 -11
- package/dist/cli-bundle/chunks/history-redact-KASLLPE7.js +19 -0
- package/dist/cli-bundle/chunks/{history-repair-SDMHR7JT.js → history-repair-IJ7LLBET.js} +11 -11
- package/dist/cli-bundle/chunks/{history-repair-HIBCBIKK.js → history-repair-YNESJRT6.js} +11 -11
- package/dist/cli-bundle/chunks/init-IGSS4GNH.js +17 -0
- package/dist/cli-bundle/chunks/{init-P56QYWJF.js → init-YHVBTEET.js} +9 -8
- package/dist/cli-bundle/chunks/{learnings-GDFRG5J7.js → learnings-4YBMIVCZ.js} +10 -10
- package/dist/cli-bundle/chunks/{learnings-MIXSESLK.js → learnings-T4PF24YN.js} +10 -10
- package/dist/cli-bundle/chunks/{list-FGOWQMSM.js → list-3KEVBOYW.js} +10 -10
- package/dist/cli-bundle/chunks/list-E44O2K64.js +20 -0
- package/dist/cli-bundle/chunks/{notes-4XVSH2AZ.js → notes-FLUCNJSH.js} +10 -10
- package/dist/cli-bundle/chunks/{notes-5UK3GEH2.js → notes-GJKALVZM.js} +10 -10
- package/dist/cli-bundle/chunks/{plan-SLMODHWX.js → plan-T5MMZLI3.js} +13 -13
- package/dist/cli-bundle/chunks/{plan-DUMBV3QB.js → plan-YYMIL3HV.js} +13 -13
- package/dist/cli-bundle/chunks/{register-list-query-POCFZ5JW.js → register-list-query-I65EZ3HB.js} +29 -25
- package/dist/cli-bundle/chunks/register-list-query-I65EZ3HB.js.map +1 -0
- package/dist/cli-bundle/chunks/{register-list-query-WST76HSQ.js → register-list-query-OECMHO4G.js} +28 -24
- package/dist/cli-bundle/chunks/register-list-query-OECMHO4G.js.map +7 -0
- package/dist/cli-bundle/chunks/{register-mutation-N5GSUZJV.js → register-mutation-2FLXORLR.js} +65 -47
- package/dist/cli-bundle/chunks/register-mutation-2FLXORLR.js.map +1 -0
- package/dist/cli-bundle/chunks/{register-mutation-OA675SOU.js → register-mutation-5GPDEKHR.js} +64 -46
- package/dist/cli-bundle/chunks/register-mutation-5GPDEKHR.js.map +7 -0
- package/dist/cli-bundle/chunks/{register-operations-GNHBE5I3.js → register-operations-BNGAUMGK.js} +58 -35
- package/dist/cli-bundle/chunks/register-operations-BNGAUMGK.js.map +1 -0
- package/dist/cli-bundle/chunks/{register-operations-N3PMHXH5.js → register-operations-GQKT35H5.js} +57 -34
- package/dist/cli-bundle/chunks/register-operations-GQKT35H5.js.map +7 -0
- package/dist/cli-bundle/chunks/{register-setup-JIMPKJKV.js → register-setup-DNDCGZ4O.js} +18 -18
- package/dist/cli-bundle/chunks/{register-setup-JIMPKJKV.js.map → register-setup-DNDCGZ4O.js.map} +1 -1
- package/dist/cli-bundle/chunks/{register-setup-ZHJI2DI3.js → register-setup-EJY44FPH.js} +17 -17
- package/dist/cli-bundle/chunks/{register-setup-ZHJI2DI3.js.map → register-setup-EJY44FPH.js.map} +2 -2
- package/dist/cli-bundle/chunks/{restore-PBL6T5TW.js → restore-DDJGVZIN.js} +11 -11
- package/dist/cli-bundle/chunks/restore-SJSASGZP.js +17 -0
- package/dist/cli-bundle/chunks/{schema-2NOO6NGB.js → schema-B7NQ6XVP.js} +8 -8
- package/dist/cli-bundle/chunks/{schema-EBI4NLUO.js → schema-HEGYH6CE.js} +8 -8
- package/dist/cli-bundle/chunks/{search-JPUQTVCY.js → search-DVVQ4UO2.js} +421 -42
- package/dist/cli-bundle/chunks/search-DVVQ4UO2.js.map +1 -0
- package/dist/cli-bundle/chunks/{search-OA6JX27A.js → search-JNEZJV7H.js} +427 -41
- package/dist/cli-bundle/chunks/search-JNEZJV7H.js.map +7 -0
- package/dist/cli-bundle/chunks/{stats-CV54BAWY.js → stats-7JDIJRDH.js} +7 -7
- package/dist/cli-bundle/chunks/{stats-XYB6KTFG.js → stats-SYTJRR4Z.js} +7 -7
- package/dist/cli-bundle/chunks/{telemetry-LMJ7PFUO.js → telemetry-4HHWD5Y7.js} +4 -4
- package/dist/cli-bundle/chunks/{telemetry-NCMEPJNR.js → telemetry-EGWP7ZUX.js} +4 -4
- package/dist/cli-bundle/chunks/{test-WBROAJIE.js → test-IIELLSZX.js} +14 -13
- package/dist/cli-bundle/chunks/test-ML5RLWXE.js +32 -0
- package/dist/cli-bundle/chunks/{test-all-NTOZ7C3M.js → test-all-7DNCMML7.js} +14 -13
- package/dist/cli-bundle/chunks/{test-all-NTOZ7C3M.js.map → test-all-7DNCMML7.js.map} +1 -1
- package/dist/cli-bundle/chunks/{test-all-N6NSRDTV.js → test-all-IHTUJRRC.js} +16 -15
- package/dist/cli-bundle/chunks/{test-all-N6NSRDTV.js.map → test-all-IHTUJRRC.js.map} +1 -1
- package/dist/cli-bundle/chunks/{test-runs-V6A7LPWZ.js → test-runs-5FEMBV3A.js} +5 -5
- package/dist/cli-bundle/chunks/{test-runs-WMVTQU3Y.js → test-runs-RNKZ37PS.js} +5 -5
- package/dist/cli-bundle/chunks/update-6C67X4KS.js +21 -0
- package/dist/cli-bundle/chunks/update-VF26YPT3.js +25 -0
- package/dist/cli-bundle/chunks/{update-many-KGGEYABR.js → update-many-BSZZZYXY.js} +22 -22
- package/dist/cli-bundle/chunks/{update-many-EM6OXYGO.js → update-many-BWKJJEBF.js} +22 -22
- package/dist/cli-bundle/chunks/{upgrade-LXPOQKFV.js → upgrade-RSE5PC44.js} +7 -6
- package/dist/cli-bundle/chunks/{upgrade-LXPOQKFV.js.map → upgrade-RSE5PC44.js.map} +1 -1
- package/dist/cli-bundle/chunks/{upgrade-BLI7XBAJ.js → upgrade-YWI5DJFA.js} +5 -4
- package/dist/cli-bundle/chunks/{upgrade-BLI7XBAJ.js.map → upgrade-YWI5DJFA.js.map} +1 -1
- package/dist/cli-bundle/chunks/{validate-AGOAUOVW.js → validate-NK3WKB7C.js} +18 -17
- package/dist/cli-bundle/chunks/{validate-AGOAUOVW.js.map → validate-NK3WKB7C.js.map} +1 -1
- package/dist/cli-bundle/chunks/{validate-L5J6A7YO.js → validate-UCEOB7S6.js} +20 -19
- package/dist/cli-bundle/chunks/{validate-L5J6A7YO.js.map → validate-UCEOB7S6.js.map} +1 -1
- package/dist/cli-bundle/main.js +127 -43
- package/dist/cli-bundle/main.js.map +3 -3
- package/dist/core/config/nested-settings.d.ts +8 -6
- package/dist/core/config/nested-settings.js +71 -5
- package/dist/core/config/nested-settings.js.map +1 -1
- package/dist/core/config/positional-value.js +4 -2
- package/dist/core/config/positional-value.js.map +1 -1
- package/dist/core/extensions/extension-types.d.ts +36 -0
- package/dist/core/extensions/extension-types.js +2 -2
- package/dist/core/extensions/extension-types.js.map +1 -1
- package/dist/core/extensions/loader.js +46 -5
- package/dist/core/extensions/loader.js.map +1 -1
- package/dist/core/history/drift-scan.d.ts +3 -4
- package/dist/core/history/drift-scan.js +71 -18
- package/dist/core/history/drift-scan.js.map +1 -1
- package/dist/core/item/id.js +4 -5
- package/dist/core/item/id.js.map +1 -1
- package/dist/core/item/item-format.js +7 -3
- package/dist/core/item/item-format.js.map +1 -1
- package/dist/core/item/toon-decode.d.ts +7 -0
- package/dist/core/item/toon-decode.js +11 -2
- package/dist/core/item/toon-decode.js.map +1 -1
- package/dist/core/item/type-registry.js +25 -7
- package/dist/core/item/type-registry.js.map +1 -1
- package/dist/core/search/cache.js +5 -3
- package/dist/core/search/cache.js.map +1 -1
- package/dist/core/search/corpus.d.ts +6 -0
- package/dist/core/search/corpus.js +22 -9
- package/dist/core/search/corpus.js.map +1 -1
- package/dist/core/search/embedding-batches.js +10 -7
- package/dist/core/search/embedding-batches.js.map +1 -1
- package/dist/core/search/relevance.d.ts +29 -0
- package/dist/core/search/relevance.js +226 -0
- package/dist/core/search/relevance.js.map +1 -0
- package/dist/core/search/vector-stores.d.ts +3 -0
- package/dist/core/search/vector-stores.js +23 -10
- package/dist/core/search/vector-stores.js.map +1 -1
- package/dist/core/shared/constants.js +15 -2
- package/dist/core/shared/constants.js.map +1 -1
- package/dist/core/shared/errors.d.ts +6 -0
- package/dist/core/shared/errors.js +2 -2
- package/dist/core/shared/errors.js.map +1 -1
- package/dist/core/shared/primitives.d.ts +8 -0
- package/dist/core/shared/primitives.js +29 -2
- package/dist/core/shared/primitives.js.map +1 -1
- package/dist/core/shared/time.js +42 -6
- package/dist/core/shared/time.js.map +1 -1
- package/dist/core/store/paths.js +25 -7
- package/dist/core/store/paths.js.map +1 -1
- package/dist/core/store/settings-validator.d.ts +11 -0
- package/dist/core/store/settings-validator.js +14 -2
- package/dist/core/store/settings-validator.js.map +1 -1
- package/dist/core/store/settings.js +109 -12
- package/dist/core/store/settings.js.map +1 -1
- package/dist/core/telemetry/runtime.js +85 -4
- package/dist/core/telemetry/runtime.js.map +1 -1
- package/dist/mcp/server.js +36 -9
- package/dist/mcp/server.js.map +1 -1
- package/dist/sdk/cli-contracts/commander-types.d.ts +1 -0
- package/dist/sdk/cli-contracts/commander-types.js +13 -2
- package/dist/sdk/cli-contracts/commander-types.js.map +1 -1
- package/dist/sdk/cli-contracts/enum-contracts.d.ts +2 -2
- package/dist/sdk/cli-contracts/enum-contracts.js +6 -2
- package/dist/sdk/cli-contracts/enum-contracts.js.map +1 -1
- package/dist/sdk/cli-contracts/tool-option-contracts.js +7 -2
- package/dist/sdk/cli-contracts/tool-option-contracts.js.map +1 -1
- package/dist/sdk/cli-contracts/tool-parameter-tables.js +31 -2
- package/dist/sdk/cli-contracts/tool-parameter-tables.js.map +1 -1
- package/dist/sdk/cli-contracts.d.ts +3 -1
- package/dist/sdk/cli-contracts.js +36 -6
- package/dist/sdk/cli-contracts.js.map +1 -1
- package/dist/sdk/index.d.ts +2 -2
- package/dist/sdk/index.js +3 -3
- package/dist/sdk/index.js.map +1 -1
- package/dist/sdk/testing.d.ts +51 -1
- package/dist/sdk/testing.js +93 -2
- package/dist/sdk/testing.js.map +1 -1
- package/dist/types.d.ts +14 -0
- package/dist/types.js +2 -2
- package/dist/types.js.map +1 -1
- package/docs/CLAUDE_CODE_PLUGIN.md +2 -2
- package/docs/CODEX_PLUGIN.md +1 -1
- package/docs/COMMANDS.md +9 -2
- package/docs/CONFIGURATION.md +22 -1
- package/docs/EXTENSIONS.md +22 -9
- package/docs/QUICKSTART.md +1 -1
- package/docs/SDK.md +66 -0
- package/docs/TESTING.md +14 -0
- package/package.json +2 -1
- package/packages/pm-governance-audit/README.md +14 -0
- package/packages/pm-governance-audit/extensions/governance-audit/index.js +39 -1
- package/packages/pm-governance-audit/extensions/governance-audit/index.ts +40 -2
- package/packages/pm-governance-audit/extensions/governance-audit/manifest.json +1 -1
- package/packages/pm-governance-audit/package.json +4 -2
- package/packages/pm-lifecycle-hooks/README.md +21 -0
- package/packages/pm-search-advanced/README.md +38 -0
- package/packages/pm-search-advanced/extensions/search-advanced/index.js +17 -0
- package/packages/pm-search-advanced/extensions/search-advanced/index.ts +17 -0
- package/packages/pm-search-advanced/extensions/search-advanced/runtime.js +216 -1
- package/packages/pm-search-advanced/extensions/search-advanced/runtime.ts +271 -2
- package/plugins/pm-claude/README.md +4 -4
- package/plugins/pm-codex/README.md +1 -1
- package/dist/cli-bundle/chunks/activity-CVXTCHYY.js +0 -16
- package/dist/cli-bundle/chunks/aggregate-GI7WSZPH.js.map +0 -1
- package/dist/cli-bundle/chunks/aggregate-VNAHUNNF.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-2VBQ6ZXS.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-3FI4SEFT.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-4LL6TK5B.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-52MAOQ6J.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-5FDATVEZ.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-5SFCOO6B.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-ECCMVXGM.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-FRAUKRU2.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-GU2ZJ2VV.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-HZGUAH22.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-IOR7LGF4.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-KJE2FOS4.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-KWU6HG75.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-LB3RUL2N.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-PDDFYW4X.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-PROOHX4K.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-Q7SPNHLW.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-QO7EBBOM.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-SKJWX3QB.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-T3LC5LKB.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-TCD3R2PF.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-TPH5XEVD.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-U5SXYXSY.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-W7XABV4H.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-WOPXVEZP.js.map +0 -1
- package/dist/cli-bundle/chunks/close-3HDWDA3L.js +0 -13
- package/dist/cli-bundle/chunks/close-many-7CGIDPTJ.js.map +0 -7
- package/dist/cli-bundle/chunks/close-many-ERFO6LHR.js.map +0 -1
- package/dist/cli-bundle/chunks/config-6FXCQKIF.js.map +0 -1
- package/dist/cli-bundle/chunks/config-U4RZ4CQB.js.map +0 -7
- package/dist/cli-bundle/chunks/context-YMJ3Z2HQ.js.map +0 -1
- package/dist/cli-bundle/chunks/contracts-QDB6OMLQ.js.map +0 -1
- package/dist/cli-bundle/chunks/contracts-RFSPGVVJ.js.map +0 -7
- package/dist/cli-bundle/chunks/create-JTZNCTQC.js +0 -27
- package/dist/cli-bundle/chunks/get-RV37HT3G.js.map +0 -1
- package/dist/cli-bundle/chunks/get-WXU6WI5P.js.map +0 -7
- package/dist/cli-bundle/chunks/history-2BA3T5AE.js +0 -20
- package/dist/cli-bundle/chunks/history-redact-JBZNXHGR.js +0 -19
- package/dist/cli-bundle/chunks/init-HIVSNX3O.js +0 -16
- package/dist/cli-bundle/chunks/list-MUSQNMTD.js +0 -20
- package/dist/cli-bundle/chunks/register-list-query-POCFZ5JW.js.map +0 -1
- package/dist/cli-bundle/chunks/register-list-query-WST76HSQ.js.map +0 -7
- package/dist/cli-bundle/chunks/register-mutation-N5GSUZJV.js.map +0 -1
- package/dist/cli-bundle/chunks/register-mutation-OA675SOU.js.map +0 -7
- package/dist/cli-bundle/chunks/register-operations-GNHBE5I3.js.map +0 -1
- package/dist/cli-bundle/chunks/register-operations-N3PMHXH5.js.map +0 -7
- package/dist/cli-bundle/chunks/restore-D4RGNX33.js +0 -17
- package/dist/cli-bundle/chunks/search-JPUQTVCY.js.map +0 -1
- package/dist/cli-bundle/chunks/search-OA6JX27A.js.map +0 -7
- package/dist/cli-bundle/chunks/test-MXX3E5JL.js +0 -31
- package/dist/cli-bundle/chunks/update-OSV3NAQB.js +0 -25
- package/dist/cli-bundle/chunks/update-YRXSUGYQ.js +0 -21
- /package/dist/cli-bundle/chunks/{activity-CVXTCHYY.js.map → activity-5UROHJ3D.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{activity-JM6DTDND.js.map → activity-YVB3QRTE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{append-WMKRXKCE.js.map → append-2PPYFAG5.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{append-7H5N64R2.js.map → append-AUGT5W6J.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-6P6GGMOG.js.map → chunk-2IF7WLB7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-KAG77BY3.js.map → chunk-2OJHLWBZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-GXSUPCBV.js.map → chunk-3A2CMEM7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-UM2GBHS4.js.map → chunk-3EOBJOF4.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-PRJCELV4.js.map → chunk-4CHEG6UK.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-OZ7NSQHL.js.map → chunk-5AXMRKN5.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-GCOQW437.js.map → chunk-6J4K6JLA.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-2RSPZI5H.js.map → chunk-6RZXO5M2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-KJ33AOCY.js.map → chunk-AVJD6VTA.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-I6BNFU5X.js.map → chunk-B5RF3IP7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-RZN6VURO.js.map → chunk-C5W2UH56.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-3LB74A67.js.map → chunk-CKLBZHS7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-3VAM3NNM.js.map → chunk-FY6Z3FYY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-RWPSOIEE.js.map → chunk-GNIUOLZ2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-MITFDD35.js.map → chunk-GPXQBR3H.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-I2HSTRJF.js.map → chunk-H7EO3QA3.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-77GFDHGF.js.map → chunk-HLC3KTLP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-OVQCEJPG.js.map → chunk-HMMMWBK2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-XLTD2HN3.js.map → chunk-HV5SSZXF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-2HVRUSQA.js.map → chunk-KNGVP5WJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-3BWOVLTH.js.map → chunk-LI65XLJR.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-NUZ5HKR4.js.map → chunk-LIN2BPJ7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-N7ACFE26.js.map → chunk-LQHBENVW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-23YFZ3IG.js.map → chunk-LXO6V66E.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-PIU6RSL3.js.map → chunk-MOYM2C3J.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-IJGCZSIQ.js.map → chunk-NQL32HQ5.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-6ER6DXH5.js.map → chunk-OKSKJKHX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-2VVCGBNV.js.map → chunk-R3V3YCMH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-UBOPJT3S.js.map → chunk-RVPTZKBC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-WKY2IBOQ.js.map → chunk-SFFVGNHC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-WSMOSYRD.js.map → chunk-SQPKRA54.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-YL2DJGYS.js.map → chunk-TNPBPNII.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-XTGLRY2Y.js.map → chunk-TP4DDY27.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-AY43SBIN.js.map → chunk-TYJJOTUA.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-LCM63IXU.js.map → chunk-UAQOQ7IE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-BQHUILZS.js.map → chunk-UEWA73ZZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-PO3GSVFV.js.map → chunk-UIIQC5YO.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-R6UFP2GE.js.map → chunk-V6EYFTRL.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-XSJCLN2R.js.map → chunk-WYEXLDDY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-E5FJNAZA.js.map → chunk-X7UHMKPE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-GGYWB3Y2.js.map → chunk-YBZW2QQ7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ME2YH6FN.js.map → chunk-YO3THIJF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{claim-X2P4IB7J.js.map → claim-BJ4QMPJC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{claim-4DBF6RVG.js.map → claim-KW743OSW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-3HDWDA3L.js.map → close-P4ZBKODL.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-PTYFA45H.js.map → close-SYHSRZDC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{comments-QKBYCWKD.js.map → comments-JEO6HHVM.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{comments-OONGABK5.js.map → comments-YT2PQ5DD.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{create-JTZNCTQC.js.map → create-4DS2QWQC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{create-I5L4EYYZ.js.map → create-CF7EVRX7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{delete-7HPGI4GZ.js.map → delete-KR4VBWVE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{delete-VXUPH5RS.js.map → delete-XLZRTRKR.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{deps-JSRRWC3Z.js.map → deps-2YTXD3VM.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{deps-SCZIFK2Z.js.map → deps-GZMFMTGS.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{docs-GJK6K4VP.js.map → docs-SLROFEQ4.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{docs-WW4N3MBM.js.map → docs-ZHISRR2D.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{extension-J7IBMFTD.js.map → extension-3C7OOI4F.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{extension-VDY2U33M.js.map → extension-XYCUXICD.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{files-ISZJGILQ.js.map → files-FUWF2FYJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{files-WKOD326U.js.map → files-J4I5IU4O.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{gc-JDVJ6OQ2.js.map → gc-34NXSNSN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{gc-ULPVWMTN.js.map → gc-SPIIZX3A.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-PKN67D5O.js.map → history-SDAWYZR3.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-2BA3T5AE.js.map → history-YDUEILKP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-redact-V4FOJGS7.js.map → history-redact-EPJ7GENL.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-redact-JBZNXHGR.js.map → history-redact-KASLLPE7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-repair-SDMHR7JT.js.map → history-repair-IJ7LLBET.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-repair-HIBCBIKK.js.map → history-repair-YNESJRT6.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{init-HIVSNX3O.js.map → init-IGSS4GNH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{init-P56QYWJF.js.map → init-YHVBTEET.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{learnings-GDFRG5J7.js.map → learnings-4YBMIVCZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{learnings-MIXSESLK.js.map → learnings-T4PF24YN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{list-FGOWQMSM.js.map → list-3KEVBOYW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{list-MUSQNMTD.js.map → list-E44O2K64.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{notes-4XVSH2AZ.js.map → notes-FLUCNJSH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{notes-5UK3GEH2.js.map → notes-GJKALVZM.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{plan-SLMODHWX.js.map → plan-T5MMZLI3.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{plan-DUMBV3QB.js.map → plan-YYMIL3HV.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{restore-PBL6T5TW.js.map → restore-DDJGVZIN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{restore-D4RGNX33.js.map → restore-SJSASGZP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{schema-2NOO6NGB.js.map → schema-B7NQ6XVP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{schema-EBI4NLUO.js.map → schema-HEGYH6CE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{stats-CV54BAWY.js.map → stats-7JDIJRDH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{stats-XYB6KTFG.js.map → stats-SYTJRR4Z.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{telemetry-LMJ7PFUO.js.map → telemetry-4HHWD5Y7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{telemetry-NCMEPJNR.js.map → telemetry-EGWP7ZUX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-WBROAJIE.js.map → test-IIELLSZX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-MXX3E5JL.js.map → test-ML5RLWXE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-runs-V6A7LPWZ.js.map → test-runs-5FEMBV3A.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-runs-WMVTQU3Y.js.map → test-runs-RNKZ37PS.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-YRXSUGYQ.js.map → update-6C67X4KS.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-OSV3NAQB.js.map → update-VF26YPT3.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-many-KGGEYABR.js.map → update-many-BSZZZYXY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-many-EM6OXYGO.js.map → update-many-BWKJJEBF.js.map} +0 -0
|
@@ -1,36 +1,37 @@
|
|
|
1
1
|
|
|
2
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="9ba14ee1-bbd6-53c6-9244-a7d28f05733d")}catch(e){}}();
|
|
3
3
|
import {
|
|
4
4
|
appendTrackedTestRunSummary,
|
|
5
5
|
countFailureCategories,
|
|
6
6
|
runLinkedTests,
|
|
7
7
|
runTest,
|
|
8
8
|
summarizeContextPreflight
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-LI65XLJR.js";
|
|
10
10
|
import {
|
|
11
11
|
resolveAuthor
|
|
12
12
|
} from "./chunk-J27KIHTG.js";
|
|
13
|
-
import "./chunk-
|
|
13
|
+
import "./chunk-X7UHMKPE.js";
|
|
14
14
|
import {
|
|
15
15
|
parseOptionalNumber
|
|
16
|
-
} from "./chunk-
|
|
17
|
-
import "./chunk-
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
16
|
+
} from "./chunk-UIIQC5YO.js";
|
|
17
|
+
import "./chunk-TYJJOTUA.js";
|
|
18
|
+
import "./chunk-2IF7WLB7.js";
|
|
19
|
+
import "./chunk-XYNT7UFP.js";
|
|
20
|
+
import "./chunk-LMTOY5HE.js";
|
|
20
21
|
import "./chunk-LXYVKYMQ.js";
|
|
21
22
|
import {
|
|
22
23
|
listAllFrontMatterLight
|
|
23
|
-
} from "./chunk-
|
|
24
|
-
import "./chunk-
|
|
24
|
+
} from "./chunk-YBZW2QQ7.js";
|
|
25
|
+
import "./chunk-UT6WFXW2.js";
|
|
25
26
|
import {
|
|
26
27
|
normalizeStatusInput
|
|
27
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-UYQ7HXH4.js";
|
|
28
29
|
import {
|
|
29
30
|
resolveItemTypeRegistry
|
|
30
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-GUZBNB3G.js";
|
|
31
32
|
import {
|
|
32
33
|
nowIso
|
|
33
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-B2KZGPM2.js";
|
|
34
35
|
import {
|
|
35
36
|
EXIT_CODE,
|
|
36
37
|
PmCliError,
|
|
@@ -41,7 +42,7 @@ import {
|
|
|
41
42
|
resolveGlobalPmRoot,
|
|
42
43
|
resolvePmRoot,
|
|
43
44
|
resolveRuntimeStatusRegistry
|
|
44
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-X4IZKYHP.js";
|
|
45
46
|
|
|
46
47
|
// dist/cli/commands/test-all.js
|
|
47
48
|
function parseStatus(raw, statusRegistry) {
|
|
@@ -323,6 +324,6 @@ async function runTestAll(options, global) {
|
|
|
323
324
|
export {
|
|
324
325
|
runTestAll
|
|
325
326
|
};
|
|
326
|
-
//# sourceMappingURL=test-all-
|
|
327
|
+
//# sourceMappingURL=test-all-IHTUJRRC.js.map
|
|
327
328
|
|
|
328
|
-
//# debugId=
|
|
329
|
+
//# debugId=9ba14ee1-bbd6-53c6-9244-a7d28f05733d
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../../cli/commands/test-all.ts"],"sourcesContent":["import { pathExists } from \"../../core/fs/fs-utils.js\";\nimport { getActiveExtensionRegistrations } from \"../../core/extensions/index.js\";\nimport { resolveItemTypeRegistry } from \"../../core/item/type-registry.js\";\nimport { parseOptionalNumber } from \"../../core/item/parse.js\";\nimport { normalizeStatusInput } from \"../../core/item/status.js\";\nimport { resolveRuntimeStatusRegistry, type RuntimeStatusRegistry } from \"../../core/schema/runtime-schema.js\";\nimport { EXIT_CODE } from \"../../core/shared/constants.js\";\nimport type { GlobalOptions } from \"../../core/shared/command-types.js\";\nimport { PmCliError } from \"../../core/shared/errors.js\";\nimport { nowIso } from \"../../core/shared/time.js\";\nimport { listAllFrontMatterLight } from \"../../core/store/item-store.js\";\nimport { getSettingsPath, resolveGlobalPmRoot, resolvePmRoot } from \"../../core/store/paths.js\";\nimport { readSettings } from \"../../core/store/settings.js\";\nimport { appendTrackedTestRunSummary } from \"../../core/test/item-test-run-tracking.js\";\nimport { resolveAuthor } from \"../../core/shared/author.js\";\nimport type { ItemStatus, LinkedTest } from \"../../types/index.js\";\nimport {\n countFailureCategories,\n runLinkedTests,\n runTest,\n summarizeContextPreflight,\n type LinkedTestFailureCategory,\n type TestRunResult,\n} from \"./test.js\";\n\nexport interface TestAllCommandOptions {\n status?: string;\n limit?: string;\n offset?: string;\n timeout?: string;\n progress?: boolean;\n envSet?: string[];\n envClear?: string[];\n sharedHostSafe?: boolean;\n pmContext?: string;\n overrideLinkedPmContext?: boolean;\n failOnContextMismatch?: boolean;\n failOnSkipped?: boolean;\n failOnEmptyTestRun?: boolean;\n requireAssertionsForPm?: boolean;\n checkContext?: boolean;\n autoPmContext?: boolean;\n}\n\nexport interface TestAllItemResult {\n ok: boolean;\n id: string;\n status: ItemStatus;\n test_count: number;\n passed: number;\n failed: number;\n skipped: number;\n run_results: TestRunResult[];\n failure_categories: Record<LinkedTestFailureCategory, number>;\n}\n\nexport interface TestAllResult {\n ok: boolean;\n totals: {\n items: number;\n linked_tests: number;\n passed: number;\n failed: number;\n skipped: number;\n failure_categories: Record<LinkedTestFailureCategory, number>;\n };\n failed: number;\n passed: number;\n skipped: number;\n fail_on_skipped_triggered?: boolean;\n warnings?: string[];\n results: TestAllItemResult[];\n}\n\nfunction parseStatus(raw: string | undefined, statusRegistry: RuntimeStatusRegistry): ItemStatus | undefined {\n if (raw === undefined) {\n return undefined;\n }\n const normalized = normalizeStatusInput(raw, statusRegistry);\n if (!normalized) {\n const allowedStatuses = statusRegistry.definitions.map((definition) => definition.id);\n throw new PmCliError(`Invalid --status value \"${raw}\". Allowed: ${allowedStatuses.join(\", \")}`, EXIT_CODE.USAGE);\n }\n return normalized;\n}\n\nfunction parseTimeout(raw: string | undefined): number | undefined {\n if (raw === undefined) {\n return undefined;\n }\n return parseOptionalNumber(raw, \"timeout\");\n}\n\nfunction parseNonNegativeInteger(raw: string | undefined, flag: string): number | undefined {\n if (raw === undefined) {\n return undefined;\n }\n const parsed = Number(raw);\n if (!Number.isInteger(parsed) || parsed < 0) {\n throw new PmCliError(`${flag} must be a non-negative integer`, EXIT_CODE.USAGE);\n }\n return parsed;\n}\n\nfunction resolveTrackedRunId(): string {\n const fromEnv = process.env.PM_BACKGROUND_TEST_RUN_ID?.trim();\n if (fromEnv && fromEnv.length > 0) {\n return fromEnv;\n }\n return `test-all-local-${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 8)}`;\n}\n\nfunction normalizeCommand(command: string): string {\n return command.trim().replaceAll(/\\s+/g, \" \");\n}\n\nfunction normalizeEnvSetSignature(value: LinkedTest[\"env_set\"]): string {\n if (!value || Object.keys(value).length === 0) {\n return \"{}\";\n }\n return JSON.stringify(\n Object.fromEntries(Object.entries(value).sort(([left], [right]) => left.localeCompare(right))),\n );\n}\n\nfunction normalizeEnvClearSignature(value: LinkedTest[\"env_clear\"]): string {\n if (!value || value.length === 0) {\n return \"[]\";\n }\n return JSON.stringify([...value].sort((left, right) => left.localeCompare(right)));\n}\n\nfunction normalizePmContextModeSignature(value: LinkedTest[\"pm_context_mode\"]): string {\n const normalized = value?.trim().toLowerCase();\n return normalized && normalized.length > 0 ? normalized : \"none\";\n}\n\nfunction normalizeAssertionSignature(test: LinkedTest): string {\n const normalized = {\n assert_stdout_contains: [...new Set(test.assert_stdout_contains ?? [])].sort((left, right) => left.localeCompare(right)),\n assert_stdout_regex: [...new Set(test.assert_stdout_regex ?? [])].sort((left, right) => left.localeCompare(right)),\n assert_stderr_contains: [...new Set(test.assert_stderr_contains ?? [])].sort((left, right) => left.localeCompare(right)),\n assert_stderr_regex: [...new Set(test.assert_stderr_regex ?? [])].sort((left, right) => left.localeCompare(right)),\n assert_stdout_min_lines: typeof test.assert_stdout_min_lines === \"number\" ? test.assert_stdout_min_lines : undefined,\n assert_json_field_equals: Object.fromEntries(\n Object.entries(test.assert_json_field_equals ?? {}).sort(([left], [right]) => left.localeCompare(right)),\n ),\n assert_json_field_gte: Object.fromEntries(\n Object.entries(test.assert_json_field_gte ?? {}).sort(([left], [right]) => left.localeCompare(right)),\n ),\n };\n return JSON.stringify(normalized);\n}\n\nfunction buildLinkedTestKey(test: LinkedTest): string {\n const command = test.command?.trim();\n if (command && command.length > 0) {\n const envSet = normalizeEnvSetSignature(test.env_set);\n const envClear = normalizeEnvClearSignature(test.env_clear);\n const pmContextMode = normalizePmContextModeSignature(test.pm_context_mode);\n const sharedHostSafe = test.shared_host_safe === true ? \"true\" : \"false\";\n const assertions = normalizeAssertionSignature(test);\n return `command:${test.scope}:${normalizeCommand(command)}:${envSet}:${envClear}:${pmContextMode}:${sharedHostSafe}:${assertions}`;\n }\n const linkedPath = test.path?.trim() ?? \"\";\n return `path:${test.scope}:${linkedPath}`;\n}\n\nfunction maxTimeoutSeconds(current: number | undefined, candidate: number | undefined): number | undefined {\n if (candidate === undefined) {\n /* c8 ignore next - exercised implicitly by duplicate timeout normalization */\n return current;\n }\n if (current === undefined || candidate > current) {\n return candidate;\n }\n return current;\n}\n\nfunction countStatuses(runResults: TestRunResult[]): { passed: number; failed: number; skipped: number } {\n let passed = 0;\n let failed = 0;\n let skipped = 0;\n for (const result of runResults) {\n if (result.status === \"passed\") {\n passed += 1;\n continue;\n }\n if (result.status === \"failed\") {\n failed += 1;\n continue;\n }\n skipped += 1;\n }\n return { passed, failed, skipped };\n}\n\nfunction mergeFailureCategoryCounts(\n target: Record<LinkedTestFailureCategory, number>,\n source: Record<LinkedTestFailureCategory, number>,\n): void {\n for (const [key, value] of Object.entries(source)) {\n target[key as LinkedTestFailureCategory] += value;\n }\n}\n\nexport async function runTestAll(options: TestAllCommandOptions, global: GlobalOptions): Promise<TestAllResult> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n if (!(await pathExists(getSettingsPath(pmRoot)))) {\n throw new PmCliError(`Tracker is not initialized at ${pmRoot}. Run pm init first.`, EXIT_CODE.NOT_FOUND);\n }\n\n const settings = await readSettings(pmRoot);\n const statusRegistry = resolveRuntimeStatusRegistry(settings.schema);\n const typeRegistry = resolveItemTypeRegistry(settings, getActiveExtensionRegistrations());\n const statusFilter = parseStatus(options.status, statusRegistry);\n const limitFilter = parseNonNegativeInteger(options.limit, \"--limit\");\n const offsetFilter = parseNonNegativeInteger(options.offset, \"--offset\") ?? 0;\n const allItems = await listAllFrontMatterLight(pmRoot, settings.item_format, typeRegistry.type_to_folder, undefined, settings.schema);\n const statusFilteredItems = allItems\n .filter((item) => (statusFilter ? item.status === statusFilter : true))\n .sort((a, b) => a.id.localeCompare(b.id));\n const filteredItems =\n limitFilter === undefined\n ? statusFilteredItems.slice(offsetFilter)\n : statusFilteredItems.slice(offsetFilter, offsetFilter + limitFilter);\n const defaultTimeoutSeconds = parseTimeout(options.timeout);\n const sourceRoots = {\n projectPmRoot: pmRoot,\n globalPmRoot: resolveGlobalPmRoot(process.cwd()),\n };\n const runStartedAt = nowIso();\n const trackingEnabled = settings.testing.record_results_to_items === true;\n const trackingRunId = resolveTrackedRunId();\n const trackingAuthor = resolveAuthor(undefined, settings.author_default);\n const trackingAttemptRaw = process.env.PM_BACKGROUND_TEST_RUN_ATTEMPT?.trim();\n const trackingParsedAttempt = trackingAttemptRaw ? Number.parseInt(trackingAttemptRaw, 10) : Number.NaN;\n const trackingResumedFrom = process.env.PM_BACKGROUND_TEST_RUN_RESUMED_FROM?.trim();\n const trackingWarnings: string[] = [];\n\n const results: TestAllItemResult[] = [];\n const seenTestKeys = new Set<string>();\n let passed = 0;\n let failed = 0;\n let skipped = 0;\n let linkedTests = 0;\n const failureCategories = countFailureCategories([]);\n const itemTests: Array<{ item: (typeof filteredItems)[number]; tests: LinkedTest[] }> = [];\n\n for (const item of filteredItems) {\n const readResult = await runTest(\n item.id,\n {\n run: false,\n },\n {\n ...global,\n path: pmRoot,\n },\n );\n\n linkedTests += readResult.tests.length;\n itemTests.push({ item, tests: readResult.tests });\n }\n\n const effectiveTimeoutByKey = new Map<string, number | undefined>();\n for (const { tests } of itemTests) {\n for (const test of tests) {\n const key = buildLinkedTestKey(test);\n if (!effectiveTimeoutByKey.has(key)) {\n effectiveTimeoutByKey.set(key, test.timeout_seconds);\n continue;\n }\n effectiveTimeoutByKey.set(key, maxTimeoutSeconds(effectiveTimeoutByKey.get(key), test.timeout_seconds));\n }\n }\n\n for (const { item, tests } of itemTests) {\n const testsToRun: LinkedTest[] = [];\n const keyedTests = tests.map((test) => {\n const key = buildLinkedTestKey(test);\n const duplicate = seenTestKeys.has(key);\n if (!duplicate) {\n seenTestKeys.add(key);\n const effectiveTimeoutSeconds = effectiveTimeoutByKey.get(key);\n testsToRun.push(\n effectiveTimeoutSeconds === undefined ? test : { ...test, timeout_seconds: effectiveTimeoutSeconds },\n );\n }\n return { test, key, duplicate };\n });\n\n const executedResults =\n testsToRun.length > 0\n ? await runLinkedTests(testsToRun, defaultTimeoutSeconds, {\n progress: options.progress,\n sourceRoots,\n envSet: options.envSet,\n envClear: options.envClear,\n sharedHostSafe: options.sharedHostSafe,\n pmContext: options.pmContext,\n overrideLinkedPmContext: options.overrideLinkedPmContext,\n failOnContextMismatch: options.failOnContextMismatch,\n failOnEmptyTestRun: options.failOnEmptyTestRun,\n requireAssertionsForPm: options.requireAssertionsForPm,\n checkContext: options.checkContext,\n autoPmContext: options.autoPmContext,\n })\n : [];\n let executedIndex = 0;\n const runResults = keyedTests.map(({ test, key, duplicate }) => {\n if (!duplicate) {\n const executed = executedResults[executedIndex];\n executedIndex += 1;\n return executed;\n }\n return {\n command: test.command,\n path: test.path,\n status: \"skipped\" as const,\n error: `Duplicate linked test skipped (key=${key}).`,\n };\n });\n\n const summary = countStatuses(runResults);\n const itemFailureCategories = countFailureCategories(runResults);\n mergeFailureCategoryCounts(failureCategories, itemFailureCategories);\n passed += summary.passed;\n failed += summary.failed;\n skipped += summary.skipped;\n if (trackingEnabled) {\n try {\n await appendTrackedTestRunSummary({\n pmRoot,\n settings,\n itemId: item.id,\n author: trackingAuthor,\n message: `Track test-all run summary (${trackingRunId})`,\n entry: {\n run_id: trackingRunId,\n kind: \"test-all\",\n status: summary.failed > 0 || (options.failOnSkipped === true && summary.skipped > 0) ? \"failed\" : \"passed\",\n started_at: runStartedAt,\n finished_at: nowIso(),\n recorded_at: nowIso(),\n attempt: Number.isFinite(trackingParsedAttempt) && trackingParsedAttempt >= 1 ? trackingParsedAttempt : undefined,\n resumed_from: trackingResumedFrom && trackingResumedFrom.length > 0 ? trackingResumedFrom : undefined,\n passed: summary.passed,\n failed: summary.failed,\n skipped: summary.skipped,\n items: 1,\n linked_tests: tests.length,\n fail_on_skipped_triggered: options.failOnSkipped === true && summary.skipped > 0 ? true : undefined,\n },\n });\n } catch (error: unknown) {\n trackingWarnings.push(`test_result_tracking_failed:${item.id}:${error instanceof Error ? error.message : String(error)}`);\n }\n }\n results.push({\n ok: summary.failed === 0 && !(options.failOnSkipped === true && summary.skipped > 0),\n id: item.id,\n status: item.status,\n test_count: tests.length,\n passed: summary.passed,\n failed: summary.failed,\n skipped: summary.skipped,\n run_results: runResults,\n failure_categories: itemFailureCategories,\n });\n }\n\n const failOnSkippedTriggered = options.failOnSkipped === true && skipped > 0;\n if (options.checkContext === true) {\n const allRunResults = results.flatMap((entry) => entry.run_results);\n const preflight = summarizeContextPreflight(allRunResults);\n trackingWarnings.push(\n `context_preflight:checked_pm_commands=${preflight.checked_pm_commands};` +\n `tracker_read_commands=${preflight.tracker_read_commands};` +\n `mismatches=${preflight.mismatches};` +\n `auto_remediated=${preflight.auto_remediated}`,\n );\n }\n\n return {\n ok: failed === 0 && failOnSkippedTriggered !== true,\n totals: {\n items: filteredItems.length,\n linked_tests: linkedTests,\n passed,\n failed,\n skipped,\n failure_categories: failureCategories,\n },\n failed,\n passed,\n skipped,\n fail_on_skipped_triggered: failOnSkippedTriggered ? true : undefined,\n warnings: trackingWarnings.length > 0 ? trackingWarnings : undefined,\n results,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0EA,SAAS,YAAY,KAAyB,gBAAqC;AACjF,MAAI,QAAQ,QAAW;AACrB,WAAO;EACT;AACA,QAAM,aAAa,qBAAqB,KAAK,cAAc;AAC3D,MAAI,CAAC,YAAY;AACf,UAAM,kBAAkB,eAAe,YAAY,IAAI,CAAC,eAAe,WAAW,EAAE;AACpF,UAAM,IAAI,WAAW,2BAA2B,GAAG,eAAe,gBAAgB,KAAK,IAAI,CAAC,IAAI,UAAU,KAAK;EACjH;AACA,SAAO;AACT;AAEA,SAAS,aAAa,KAAuB;AAC3C,MAAI,QAAQ,QAAW;AACrB,WAAO;EACT;AACA,SAAO,oBAAoB,KAAK,SAAS;AAC3C;AAEA,SAAS,wBAAwB,KAAyB,MAAY;AACpE,MAAI,QAAQ,QAAW;AACrB,WAAO;EACT;AACA,QAAM,SAAS,OAAO,GAAG;AACzB,MAAI,CAAC,OAAO,UAAU,MAAM,KAAK,SAAS,GAAG;AAC3C,UAAM,IAAI,WAAW,GAAG,IAAI,mCAAmC,UAAU,KAAK;EAChF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U,iBAAiB,SAAS,IAAI,mBAAmB;IAC3D;;AAEJ","debugId":"90863736-fa1a-5f49-a791-20a703715c5b"}
|
|
1
|
+
{"version":3,"sources":["../../../../../../../../cli/commands/test-all.ts"],"sourcesContent":["import { pathExists } from \"../../core/fs/fs-utils.js\";\nimport { getActiveExtensionRegistrations } from \"../../core/extensions/index.js\";\nimport { resolveItemTypeRegistry } from \"../../core/item/type-registry.js\";\nimport { parseOptionalNumber } from \"../../core/item/parse.js\";\nimport { normalizeStatusInput } from \"../../core/item/status.js\";\nimport { resolveRuntimeStatusRegistry, type RuntimeStatusRegistry } from \"../../core/schema/runtime-schema.js\";\nimport { EXIT_CODE } from \"../../core/shared/constants.js\";\nimport type { GlobalOptions } from \"../../core/shared/command-types.js\";\nimport { PmCliError } from \"../../core/shared/errors.js\";\nimport { nowIso } from \"../../core/shared/time.js\";\nimport { listAllFrontMatterLight } from \"../../core/store/item-store.js\";\nimport { getSettingsPath, resolveGlobalPmRoot, resolvePmRoot } from \"../../core/store/paths.js\";\nimport { readSettings } from \"../../core/store/settings.js\";\nimport { appendTrackedTestRunSummary } from \"../../core/test/item-test-run-tracking.js\";\nimport { resolveAuthor } from \"../../core/shared/author.js\";\nimport type { ItemStatus, LinkedTest } from \"../../types/index.js\";\nimport {\n countFailureCategories,\n runLinkedTests,\n runTest,\n summarizeContextPreflight,\n type LinkedTestFailureCategory,\n type TestRunResult,\n} from \"./test.js\";\n\nexport interface TestAllCommandOptions {\n status?: string;\n limit?: string;\n offset?: string;\n timeout?: string;\n progress?: boolean;\n envSet?: string[];\n envClear?: string[];\n sharedHostSafe?: boolean;\n pmContext?: string;\n overrideLinkedPmContext?: boolean;\n failOnContextMismatch?: boolean;\n failOnSkipped?: boolean;\n failOnEmptyTestRun?: boolean;\n requireAssertionsForPm?: boolean;\n checkContext?: boolean;\n autoPmContext?: boolean;\n}\n\nexport interface TestAllItemResult {\n ok: boolean;\n id: string;\n status: ItemStatus;\n test_count: number;\n passed: number;\n failed: number;\n skipped: number;\n run_results: TestRunResult[];\n failure_categories: Record<LinkedTestFailureCategory, number>;\n}\n\nexport interface TestAllResult {\n ok: boolean;\n totals: {\n items: number;\n linked_tests: number;\n passed: number;\n failed: number;\n skipped: number;\n failure_categories: Record<LinkedTestFailureCategory, number>;\n };\n failed: number;\n passed: number;\n skipped: number;\n fail_on_skipped_triggered?: boolean;\n warnings?: string[];\n results: TestAllItemResult[];\n}\n\nfunction parseStatus(raw: string | undefined, statusRegistry: RuntimeStatusRegistry): ItemStatus | undefined {\n if (raw === undefined) {\n return undefined;\n }\n const normalized = normalizeStatusInput(raw, statusRegistry);\n if (!normalized) {\n const allowedStatuses = statusRegistry.definitions.map((definition) => definition.id);\n throw new PmCliError(`Invalid --status value \"${raw}\". Allowed: ${allowedStatuses.join(\", \")}`, EXIT_CODE.USAGE);\n }\n return normalized;\n}\n\nfunction parseTimeout(raw: string | undefined): number | undefined {\n if (raw === undefined) {\n return undefined;\n }\n return parseOptionalNumber(raw, \"timeout\");\n}\n\nfunction parseNonNegativeInteger(raw: string | undefined, flag: string): number | undefined {\n if (raw === undefined) {\n return undefined;\n }\n const parsed = Number(raw);\n if (!Number.isInteger(parsed) || parsed < 0) {\n throw new PmCliError(`${flag} must be a non-negative integer`, EXIT_CODE.USAGE);\n }\n return parsed;\n}\n\nfunction resolveTrackedRunId(): string {\n const fromEnv = process.env.PM_BACKGROUND_TEST_RUN_ID?.trim();\n if (fromEnv && fromEnv.length > 0) {\n return fromEnv;\n }\n return `test-all-local-${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 8)}`;\n}\n\nfunction normalizeCommand(command: string): string {\n return command.trim().replaceAll(/\\s+/g, \" \");\n}\n\nfunction normalizeEnvSetSignature(value: LinkedTest[\"env_set\"]): string {\n if (!value || Object.keys(value).length === 0) {\n return \"{}\";\n }\n return JSON.stringify(\n Object.fromEntries(Object.entries(value).sort(([left], [right]) => left.localeCompare(right))),\n );\n}\n\nfunction normalizeEnvClearSignature(value: LinkedTest[\"env_clear\"]): string {\n if (!value || value.length === 0) {\n return \"[]\";\n }\n return JSON.stringify([...value].sort((left, right) => left.localeCompare(right)));\n}\n\nfunction normalizePmContextModeSignature(value: LinkedTest[\"pm_context_mode\"]): string {\n const normalized = value?.trim().toLowerCase();\n return normalized && normalized.length > 0 ? normalized : \"none\";\n}\n\nfunction normalizeAssertionSignature(test: LinkedTest): string {\n const normalized = {\n assert_stdout_contains: [...new Set(test.assert_stdout_contains ?? [])].sort((left, right) => left.localeCompare(right)),\n assert_stdout_regex: [...new Set(test.assert_stdout_regex ?? [])].sort((left, right) => left.localeCompare(right)),\n assert_stderr_contains: [...new Set(test.assert_stderr_contains ?? [])].sort((left, right) => left.localeCompare(right)),\n assert_stderr_regex: [...new Set(test.assert_stderr_regex ?? [])].sort((left, right) => left.localeCompare(right)),\n assert_stdout_min_lines: typeof test.assert_stdout_min_lines === \"number\" ? test.assert_stdout_min_lines : undefined,\n assert_json_field_equals: Object.fromEntries(\n Object.entries(test.assert_json_field_equals ?? {}).sort(([left], [right]) => left.localeCompare(right)),\n ),\n assert_json_field_gte: Object.fromEntries(\n Object.entries(test.assert_json_field_gte ?? {}).sort(([left], [right]) => left.localeCompare(right)),\n ),\n };\n return JSON.stringify(normalized);\n}\n\nfunction buildLinkedTestKey(test: LinkedTest): string {\n const command = test.command?.trim();\n if (command && command.length > 0) {\n const envSet = normalizeEnvSetSignature(test.env_set);\n const envClear = normalizeEnvClearSignature(test.env_clear);\n const pmContextMode = normalizePmContextModeSignature(test.pm_context_mode);\n const sharedHostSafe = test.shared_host_safe === true ? \"true\" : \"false\";\n const assertions = normalizeAssertionSignature(test);\n return `command:${test.scope}:${normalizeCommand(command)}:${envSet}:${envClear}:${pmContextMode}:${sharedHostSafe}:${assertions}`;\n }\n const linkedPath = test.path?.trim() ?? \"\";\n return `path:${test.scope}:${linkedPath}`;\n}\n\nfunction maxTimeoutSeconds(current: number | undefined, candidate: number | undefined): number | undefined {\n if (candidate === undefined) {\n /* c8 ignore next - exercised implicitly by duplicate timeout normalization */\n return current;\n }\n if (current === undefined || candidate > current) {\n return candidate;\n }\n return current;\n}\n\nfunction countStatuses(runResults: TestRunResult[]): { passed: number; failed: number; skipped: number } {\n let passed = 0;\n let failed = 0;\n let skipped = 0;\n for (const result of runResults) {\n if (result.status === \"passed\") {\n passed += 1;\n continue;\n }\n if (result.status === \"failed\") {\n failed += 1;\n continue;\n }\n skipped += 1;\n }\n return { passed, failed, skipped };\n}\n\nfunction mergeFailureCategoryCounts(\n target: Record<LinkedTestFailureCategory, number>,\n source: Record<LinkedTestFailureCategory, number>,\n): void {\n for (const [key, value] of Object.entries(source)) {\n target[key as LinkedTestFailureCategory] += value;\n }\n}\n\nexport async function runTestAll(options: TestAllCommandOptions, global: GlobalOptions): Promise<TestAllResult> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n if (!(await pathExists(getSettingsPath(pmRoot)))) {\n throw new PmCliError(`Tracker is not initialized at ${pmRoot}. Run pm init first.`, EXIT_CODE.NOT_FOUND);\n }\n\n const settings = await readSettings(pmRoot);\n const statusRegistry = resolveRuntimeStatusRegistry(settings.schema);\n const typeRegistry = resolveItemTypeRegistry(settings, getActiveExtensionRegistrations());\n const statusFilter = parseStatus(options.status, statusRegistry);\n const limitFilter = parseNonNegativeInteger(options.limit, \"--limit\");\n const offsetFilter = parseNonNegativeInteger(options.offset, \"--offset\") ?? 0;\n const allItems = await listAllFrontMatterLight(pmRoot, settings.item_format, typeRegistry.type_to_folder, undefined, settings.schema);\n const statusFilteredItems = allItems\n .filter((item) => (statusFilter ? item.status === statusFilter : true))\n .sort((a, b) => a.id.localeCompare(b.id));\n const filteredItems =\n limitFilter === undefined\n ? statusFilteredItems.slice(offsetFilter)\n : statusFilteredItems.slice(offsetFilter, offsetFilter + limitFilter);\n const defaultTimeoutSeconds = parseTimeout(options.timeout);\n const sourceRoots = {\n projectPmRoot: pmRoot,\n globalPmRoot: resolveGlobalPmRoot(process.cwd()),\n };\n const runStartedAt = nowIso();\n const trackingEnabled = settings.testing.record_results_to_items === true;\n const trackingRunId = resolveTrackedRunId();\n const trackingAuthor = resolveAuthor(undefined, settings.author_default);\n const trackingAttemptRaw = process.env.PM_BACKGROUND_TEST_RUN_ATTEMPT?.trim();\n const trackingParsedAttempt = trackingAttemptRaw ? Number.parseInt(trackingAttemptRaw, 10) : Number.NaN;\n const trackingResumedFrom = process.env.PM_BACKGROUND_TEST_RUN_RESUMED_FROM?.trim();\n const trackingWarnings: string[] = [];\n\n const results: TestAllItemResult[] = [];\n const seenTestKeys = new Set<string>();\n let passed = 0;\n let failed = 0;\n let skipped = 0;\n let linkedTests = 0;\n const failureCategories = countFailureCategories([]);\n const itemTests: Array<{ item: (typeof filteredItems)[number]; tests: LinkedTest[] }> = [];\n\n for (const item of filteredItems) {\n const readResult = await runTest(\n item.id,\n {\n run: false,\n },\n {\n ...global,\n path: pmRoot,\n },\n );\n\n linkedTests += readResult.tests.length;\n itemTests.push({ item, tests: readResult.tests });\n }\n\n const effectiveTimeoutByKey = new Map<string, number | undefined>();\n for (const { tests } of itemTests) {\n for (const test of tests) {\n const key = buildLinkedTestKey(test);\n if (!effectiveTimeoutByKey.has(key)) {\n effectiveTimeoutByKey.set(key, test.timeout_seconds);\n continue;\n }\n effectiveTimeoutByKey.set(key, maxTimeoutSeconds(effectiveTimeoutByKey.get(key), test.timeout_seconds));\n }\n }\n\n for (const { item, tests } of itemTests) {\n const testsToRun: LinkedTest[] = [];\n const keyedTests = tests.map((test) => {\n const key = buildLinkedTestKey(test);\n const duplicate = seenTestKeys.has(key);\n if (!duplicate) {\n seenTestKeys.add(key);\n const effectiveTimeoutSeconds = effectiveTimeoutByKey.get(key);\n testsToRun.push(\n effectiveTimeoutSeconds === undefined ? test : { ...test, timeout_seconds: effectiveTimeoutSeconds },\n );\n }\n return { test, key, duplicate };\n });\n\n const executedResults =\n testsToRun.length > 0\n ? await runLinkedTests(testsToRun, defaultTimeoutSeconds, {\n progress: options.progress,\n sourceRoots,\n envSet: options.envSet,\n envClear: options.envClear,\n sharedHostSafe: options.sharedHostSafe,\n pmContext: options.pmContext,\n overrideLinkedPmContext: options.overrideLinkedPmContext,\n failOnContextMismatch: options.failOnContextMismatch,\n failOnEmptyTestRun: options.failOnEmptyTestRun,\n requireAssertionsForPm: options.requireAssertionsForPm,\n checkContext: options.checkContext,\n autoPmContext: options.autoPmContext,\n })\n : [];\n let executedIndex = 0;\n const runResults = keyedTests.map(({ test, key, duplicate }) => {\n if (!duplicate) {\n const executed = executedResults[executedIndex];\n executedIndex += 1;\n return executed;\n }\n return {\n command: test.command,\n path: test.path,\n status: \"skipped\" as const,\n error: `Duplicate linked test skipped (key=${key}).`,\n };\n });\n\n const summary = countStatuses(runResults);\n const itemFailureCategories = countFailureCategories(runResults);\n mergeFailureCategoryCounts(failureCategories, itemFailureCategories);\n passed += summary.passed;\n failed += summary.failed;\n skipped += summary.skipped;\n if (trackingEnabled) {\n try {\n await appendTrackedTestRunSummary({\n pmRoot,\n settings,\n itemId: item.id,\n author: trackingAuthor,\n message: `Track test-all run summary (${trackingRunId})`,\n entry: {\n run_id: trackingRunId,\n kind: \"test-all\",\n status: summary.failed > 0 || (options.failOnSkipped === true && summary.skipped > 0) ? \"failed\" : \"passed\",\n started_at: runStartedAt,\n finished_at: nowIso(),\n recorded_at: nowIso(),\n attempt: Number.isFinite(trackingParsedAttempt) && trackingParsedAttempt >= 1 ? trackingParsedAttempt : undefined,\n resumed_from: trackingResumedFrom && trackingResumedFrom.length > 0 ? trackingResumedFrom : undefined,\n passed: summary.passed,\n failed: summary.failed,\n skipped: summary.skipped,\n items: 1,\n linked_tests: tests.length,\n fail_on_skipped_triggered: options.failOnSkipped === true && summary.skipped > 0 ? true : undefined,\n },\n });\n } catch (error: unknown) {\n trackingWarnings.push(`test_result_tracking_failed:${item.id}:${error instanceof Error ? error.message : String(error)}`);\n }\n }\n results.push({\n ok: summary.failed === 0 && !(options.failOnSkipped === true && summary.skipped > 0),\n id: item.id,\n status: item.status,\n test_count: tests.length,\n passed: summary.passed,\n failed: summary.failed,\n skipped: summary.skipped,\n run_results: runResults,\n failure_categories: itemFailureCategories,\n });\n }\n\n const failOnSkippedTriggered = options.failOnSkipped === true && skipped > 0;\n if (options.checkContext === true) {\n const allRunResults = results.flatMap((entry) => entry.run_results);\n const preflight = summarizeContextPreflight(allRunResults);\n trackingWarnings.push(\n `context_preflight:checked_pm_commands=${preflight.checked_pm_commands};` +\n `tracker_read_commands=${preflight.tracker_read_commands};` +\n `mismatches=${preflight.mismatches};` +\n `auto_remediated=${preflight.auto_remediated}`,\n );\n }\n\n return {\n ok: failed === 0 && failOnSkippedTriggered !== true,\n totals: {\n items: filteredItems.length,\n linked_tests: linkedTests,\n passed,\n failed,\n skipped,\n failure_categories: failureCategories,\n },\n failed,\n passed,\n skipped,\n fail_on_skipped_triggered: failOnSkippedTriggered ? true : undefined,\n warnings: trackingWarnings.length > 0 ? trackingWarnings : undefined,\n results,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0EA,SAAS,YAAY,KAAyB,gBAAqC;AACjF,MAAI,QAAQ,QAAW;AACrB,WAAO;EACT;AACA,QAAM,aAAa,qBAAqB,KAAK,cAAc;AAC3D,MAAI,CAAC,YAAY;AACf,UAAM,kBAAkB,eAAe,YAAY,IAAI,CAAC,eAAe,WAAW,EAAE;AACpF,UAAM,IAAI,WAAW,2BAA2B,GAAG,eAAe,gBAAgB,KAAK,IAAI,CAAC,IAAI,UAAU,KAAK;EACjH;AACA,SAAO;AACT;AAEA,SAAS,aAAa,KAAuB;AAC3C,MAAI,QAAQ,QAAW;AACrB,WAAO;EACT;AACA,SAAO,oBAAoB,KAAK,SAAS;AAC3C;AAEA,SAAS,wBAAwB,KAAyB,MAAY;AACpE,MAAI,QAAQ,QAAW;AACrB,WAAO;EACT;AACA,QAAM,SAAS,OAAO,GAAG;AACzB,MAAI,CAAC,OAAO,UAAU,MA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MACd;MACA;MACA;MACA,oBAAoB;;IAEtB;IACA;IACA;IACA,2BAA2B,yBAAyB,OAAO;IAC3D,UAAU,iBAAiB,SAAS,IAAI,mBAAmB;IAC3D;;AAEJ","debugId":"9ba14ee1-bbd6-53c6-9244-a7d28f05733d"}
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="79a77c59-b70b-550b-bca7-9bb8a403d7eb")}catch(e){}}();
|
|
3
3
|
import {
|
|
4
4
|
parseLimit
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-FY6Z3FYY.js";
|
|
6
|
+
import "./chunk-GUZBNB3G.js";
|
|
7
7
|
import {
|
|
8
8
|
nowIso
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-B2KZGPM2.js";
|
|
10
10
|
import {
|
|
11
11
|
EXIT_CODE,
|
|
12
12
|
PmCliError,
|
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
resolveGlobalPmRoot,
|
|
28
28
|
resolvePmRoot,
|
|
29
29
|
writeFileAtomic
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-X4IZKYHP.js";
|
|
31
31
|
|
|
32
32
|
// dist/cli/commands/test-runs.js
|
|
33
33
|
import os from "node:os";
|
|
@@ -924,6 +924,6 @@ export {
|
|
|
924
924
|
runTestRunsStop,
|
|
925
925
|
runTestRunsWorker
|
|
926
926
|
};
|
|
927
|
-
//# sourceMappingURL=test-runs-
|
|
927
|
+
//# sourceMappingURL=test-runs-5FEMBV3A.js.map
|
|
928
928
|
|
|
929
929
|
//# debugId=79a77c59-b70b-550b-bca7-9bb8a403d7eb
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
parseLimit
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-SFFVGNHC.js";
|
|
4
|
+
import "./chunk-HRMHZ4RV.js";
|
|
5
5
|
import {
|
|
6
6
|
nowIso
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-FHHBD7PN.js";
|
|
8
8
|
import {
|
|
9
9
|
EXIT_CODE,
|
|
10
10
|
PmCliError,
|
|
@@ -25,7 +25,7 @@ import {
|
|
|
25
25
|
resolveGlobalPmRoot,
|
|
26
26
|
resolvePmRoot,
|
|
27
27
|
writeFileAtomic
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-UJUT6AHZ.js";
|
|
29
29
|
|
|
30
30
|
// dist/cli/commands/test-runs.js
|
|
31
31
|
import os from "node:os";
|
|
@@ -936,4 +936,4 @@ export {
|
|
|
936
936
|
runTestRunsStop,
|
|
937
937
|
runTestRunsWorker
|
|
938
938
|
};
|
|
939
|
-
//# sourceMappingURL=test-runs-
|
|
939
|
+
//# sourceMappingURL=test-runs-RNKZ37PS.js.map
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import {
|
|
2
|
+
runUpdate
|
|
3
|
+
} from "./chunk-LXO6V66E.js";
|
|
4
|
+
import "./chunk-IMCJBN2Q.js";
|
|
5
|
+
import "./chunk-NQL32HQ5.js";
|
|
6
|
+
import "./chunk-LQHBENVW.js";
|
|
7
|
+
import "./chunk-HV5SSZXF.js";
|
|
8
|
+
import "./chunk-2OJHLWBZ.js";
|
|
9
|
+
import "./chunk-HMMMWBK2.js";
|
|
10
|
+
import "./chunk-UAQOQ7IE.js";
|
|
11
|
+
import "./chunk-3HUE7XOF.js";
|
|
12
|
+
import "./chunk-TP4DDY27.js";
|
|
13
|
+
import "./chunk-2IXCHCLM.js";
|
|
14
|
+
import "./chunk-WCQZBDDH.js";
|
|
15
|
+
import "./chunk-HRMHZ4RV.js";
|
|
16
|
+
import "./chunk-FHHBD7PN.js";
|
|
17
|
+
import "./chunk-UJUT6AHZ.js";
|
|
18
|
+
export {
|
|
19
|
+
runUpdate
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=update-6C67X4KS.js.map
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="45eac7fa-f181-5cca-93b7-cfb58909dbb3")}catch(e){}}();
|
|
3
|
+
import {
|
|
4
|
+
runUpdate
|
|
5
|
+
} from "./chunk-SQPKRA54.js";
|
|
6
|
+
import "./chunk-NHR2QXXZ.js";
|
|
7
|
+
import "./chunk-GPXQBR3H.js";
|
|
8
|
+
import "./chunk-X7UHMKPE.js";
|
|
9
|
+
import "./chunk-UIIQC5YO.js";
|
|
10
|
+
import "./chunk-HLC3KTLP.js";
|
|
11
|
+
import "./chunk-2IF7WLB7.js";
|
|
12
|
+
import "./chunk-LIN2BPJ7.js";
|
|
13
|
+
import "./chunk-LXYVKYMQ.js";
|
|
14
|
+
import "./chunk-YBZW2QQ7.js";
|
|
15
|
+
import "./chunk-UT6WFXW2.js";
|
|
16
|
+
import "./chunk-UYQ7HXH4.js";
|
|
17
|
+
import "./chunk-GUZBNB3G.js";
|
|
18
|
+
import "./chunk-B2KZGPM2.js";
|
|
19
|
+
import "./chunk-X4IZKYHP.js";
|
|
20
|
+
export {
|
|
21
|
+
runUpdate
|
|
22
|
+
};
|
|
23
|
+
//# sourceMappingURL=update-VF26YPT3.js.map
|
|
24
|
+
|
|
25
|
+
//# debugId=45eac7fa-f181-5cca-93b7-cfb58909dbb3
|
|
@@ -1,50 +1,50 @@
|
|
|
1
1
|
import {
|
|
2
2
|
runUpdate
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-LXO6V66E.js";
|
|
4
4
|
import {
|
|
5
5
|
createCheckpointId,
|
|
6
6
|
loadMutationCheckpoint,
|
|
7
7
|
restoreCheckpointItems,
|
|
8
8
|
writeMutationCheckpoint
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-WYEXLDDY.js";
|
|
10
|
+
import "./chunk-IMCJBN2Q.js";
|
|
10
11
|
import {
|
|
11
12
|
runRestore
|
|
12
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-OKSKJKHX.js";
|
|
13
14
|
import {
|
|
14
15
|
resolveAuthor
|
|
15
16
|
} from "./chunk-O7IWB35H.js";
|
|
16
|
-
import "./chunk-
|
|
17
|
-
import "./chunk-
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
17
|
+
import "./chunk-4CHEG6UK.js";
|
|
18
|
+
import "./chunk-3EOBJOF4.js";
|
|
19
|
+
import "./chunk-NQL32HQ5.js";
|
|
20
|
+
import "./chunk-LQHBENVW.js";
|
|
20
21
|
import {
|
|
21
22
|
applyTagRemovals,
|
|
22
23
|
mergeAdditiveTags,
|
|
23
24
|
parseTags
|
|
24
|
-
} from "./chunk-
|
|
25
|
-
import "./chunk-
|
|
26
|
-
import "./chunk-
|
|
27
|
-
import "./chunk-
|
|
28
|
-
import "./chunk-LCM63IXU.js";
|
|
25
|
+
} from "./chunk-HV5SSZXF.js";
|
|
26
|
+
import "./chunk-2OJHLWBZ.js";
|
|
27
|
+
import "./chunk-HMMMWBK2.js";
|
|
28
|
+
import "./chunk-UAQOQ7IE.js";
|
|
29
29
|
import "./chunk-3HUE7XOF.js";
|
|
30
30
|
import {
|
|
31
31
|
runList
|
|
32
|
-
} from "./chunk-
|
|
33
|
-
import "./chunk-
|
|
34
|
-
import "./chunk-
|
|
32
|
+
} from "./chunk-42LOFGJS.js";
|
|
33
|
+
import "./chunk-B5RF3IP7.js";
|
|
34
|
+
import "./chunk-SFFVGNHC.js";
|
|
35
35
|
import "./chunk-EAOG77HM.js";
|
|
36
36
|
import {
|
|
37
37
|
toItemRecord
|
|
38
|
-
} from "./chunk-
|
|
39
|
-
import "./chunk-
|
|
38
|
+
} from "./chunk-TP4DDY27.js";
|
|
39
|
+
import "./chunk-2IXCHCLM.js";
|
|
40
40
|
import {
|
|
41
41
|
collectRuntimeUpdateFieldValues,
|
|
42
42
|
normalizeStatusInput
|
|
43
|
-
} from "./chunk-
|
|
44
|
-
import "./chunk-
|
|
43
|
+
} from "./chunk-WCQZBDDH.js";
|
|
44
|
+
import "./chunk-HRMHZ4RV.js";
|
|
45
45
|
import {
|
|
46
46
|
nowIso
|
|
47
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-FHHBD7PN.js";
|
|
48
48
|
import {
|
|
49
49
|
EXIT_CODE,
|
|
50
50
|
PmCliError,
|
|
@@ -56,7 +56,7 @@ import {
|
|
|
56
56
|
resolveRuntimeStatusRegistry,
|
|
57
57
|
stableValueEquals,
|
|
58
58
|
toErrorMessage
|
|
59
|
-
} from "./chunk-
|
|
59
|
+
} from "./chunk-UJUT6AHZ.js";
|
|
60
60
|
|
|
61
61
|
// dist/cli/commands/update-many.js
|
|
62
62
|
!(function() {
|
|
@@ -605,4 +605,4 @@ async function runUpdateMany(options, global2) {
|
|
|
605
605
|
export {
|
|
606
606
|
runUpdateMany
|
|
607
607
|
};
|
|
608
|
-
//# sourceMappingURL=update-many-
|
|
608
|
+
//# sourceMappingURL=update-many-BSZZZYXY.js.map
|
|
@@ -2,51 +2,51 @@
|
|
|
2
2
|
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="e97bb9e9-e002-52f4-a462-659ac8f030d9")}catch(e){}}();
|
|
3
3
|
import {
|
|
4
4
|
runUpdate
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-SQPKRA54.js";
|
|
6
6
|
import {
|
|
7
7
|
createCheckpointId,
|
|
8
8
|
loadMutationCheckpoint,
|
|
9
9
|
restoreCheckpointItems,
|
|
10
10
|
writeMutationCheckpoint
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-KNGVP5WJ.js";
|
|
12
|
+
import "./chunk-NHR2QXXZ.js";
|
|
12
13
|
import {
|
|
13
14
|
runRestore
|
|
14
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-R3V3YCMH.js";
|
|
15
16
|
import {
|
|
16
17
|
resolveAuthor
|
|
17
18
|
} from "./chunk-J27KIHTG.js";
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-
|
|
21
|
-
import "./chunk-
|
|
19
|
+
import "./chunk-6RZXO5M2.js";
|
|
20
|
+
import "./chunk-3A2CMEM7.js";
|
|
21
|
+
import "./chunk-GPXQBR3H.js";
|
|
22
|
+
import "./chunk-X7UHMKPE.js";
|
|
22
23
|
import {
|
|
23
24
|
applyTagRemovals,
|
|
24
25
|
mergeAdditiveTags,
|
|
25
26
|
parseTags
|
|
26
|
-
} from "./chunk-
|
|
27
|
-
import "./chunk-
|
|
28
|
-
import "./chunk-
|
|
29
|
-
import "./chunk-
|
|
30
|
-
import "./chunk-NUZ5HKR4.js";
|
|
27
|
+
} from "./chunk-UIIQC5YO.js";
|
|
28
|
+
import "./chunk-HLC3KTLP.js";
|
|
29
|
+
import "./chunk-2IF7WLB7.js";
|
|
30
|
+
import "./chunk-LIN2BPJ7.js";
|
|
31
31
|
import "./chunk-LXYVKYMQ.js";
|
|
32
32
|
import {
|
|
33
33
|
runList
|
|
34
|
-
} from "./chunk-
|
|
35
|
-
import "./chunk-
|
|
36
|
-
import "./chunk-
|
|
34
|
+
} from "./chunk-TINUJMWN.js";
|
|
35
|
+
import "./chunk-6J4K6JLA.js";
|
|
36
|
+
import "./chunk-FY6Z3FYY.js";
|
|
37
37
|
import "./chunk-XSLQSXAH.js";
|
|
38
38
|
import {
|
|
39
39
|
toItemRecord
|
|
40
|
-
} from "./chunk-
|
|
41
|
-
import "./chunk-
|
|
40
|
+
} from "./chunk-YBZW2QQ7.js";
|
|
41
|
+
import "./chunk-UT6WFXW2.js";
|
|
42
42
|
import {
|
|
43
43
|
collectRuntimeUpdateFieldValues,
|
|
44
44
|
normalizeStatusInput
|
|
45
|
-
} from "./chunk-
|
|
46
|
-
import "./chunk-
|
|
45
|
+
} from "./chunk-UYQ7HXH4.js";
|
|
46
|
+
import "./chunk-GUZBNB3G.js";
|
|
47
47
|
import {
|
|
48
48
|
nowIso
|
|
49
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-B2KZGPM2.js";
|
|
50
50
|
import {
|
|
51
51
|
EXIT_CODE,
|
|
52
52
|
PmCliError,
|
|
@@ -58,7 +58,7 @@ import {
|
|
|
58
58
|
resolveRuntimeStatusRegistry,
|
|
59
59
|
stableValueEquals,
|
|
60
60
|
toErrorMessage
|
|
61
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-X4IZKYHP.js";
|
|
62
62
|
|
|
63
63
|
// dist/cli/commands/update-many.js
|
|
64
64
|
var UPDATE_MANY_CHECKPOINT_SCHEMA_VERSION = 1;
|
|
@@ -600,6 +600,6 @@ async function runUpdateMany(options, global) {
|
|
|
600
600
|
export {
|
|
601
601
|
runUpdateMany
|
|
602
602
|
};
|
|
603
|
-
//# sourceMappingURL=update-many-
|
|
603
|
+
//# sourceMappingURL=update-many-BWKJJEBF.js.map
|
|
604
604
|
|
|
605
605
|
//# debugId=e97bb9e9-e002-52f4-a462-659ac8f030d9
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
|
|
2
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="734ae313-5aff-5b24-a782-7b005770ea2d")}catch(e){}}();
|
|
3
3
|
import {
|
|
4
4
|
readManagedExtensionState,
|
|
5
5
|
runExtension
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-XYNT7UFP.js";
|
|
7
|
+
import "./chunk-LMTOY5HE.js";
|
|
7
8
|
import "./chunk-LXYVKYMQ.js";
|
|
8
|
-
import "./chunk-
|
|
9
|
+
import "./chunk-B2KZGPM2.js";
|
|
9
10
|
import {
|
|
10
11
|
EXIT_CODE,
|
|
11
12
|
PmCliError,
|
|
@@ -13,7 +14,7 @@ import {
|
|
|
13
14
|
resolveExtensionRoots,
|
|
14
15
|
resolvePmPackageRootFromModule,
|
|
15
16
|
resolvePmRoot
|
|
16
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-X4IZKYHP.js";
|
|
17
18
|
|
|
18
19
|
// dist/cli/commands/upgrade.js
|
|
19
20
|
import { execFile } from "node:child_process";
|
|
@@ -261,6 +262,6 @@ async function runUpgrade(target, options, global) {
|
|
|
261
262
|
export {
|
|
262
263
|
runUpgrade
|
|
263
264
|
};
|
|
264
|
-
//# sourceMappingURL=upgrade-
|
|
265
|
+
//# sourceMappingURL=upgrade-RSE5PC44.js.map
|
|
265
266
|
|
|
266
|
-
//# debugId=
|
|
267
|
+
//# debugId=734ae313-5aff-5b24-a782-7b005770ea2d
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../../cli/commands/upgrade.ts"],"sourcesContent":["import { execFile } from \"node:child_process\";\nimport fs from \"node:fs/promises\";\nimport path from \"node:path\";\nimport { promisify } from \"node:util\";\nimport {\n readManagedExtensionState,\n runExtension,\n type ExtensionScope,\n type ManagedExtensionRecord,\n type ManagedExtensionSource,\n} from \"./extension.js\";\nimport { resolveExtensionRoots } from \"../../core/extensions/loader.js\";\nimport { pathExists } from \"../../core/fs/fs-utils.js\";\nimport type { GlobalOptions } from \"../../core/shared/command-types.js\";\nimport { EXIT_CODE } from \"../../core/shared/constants.js\";\nimport { PmCliError } from \"../../core/shared/errors.js\";\nimport { resolvePmRoot } from \"../../core/store/paths.js\";\nimport { resolvePmPackageRootFromModule } from \"../../core/packages/root.js\";\n\nconst execFileAsync = promisify(execFile);\nconst DEFAULT_CLI_PACKAGE = \"@unbrained/pm-cli\";\nconst DEFAULT_TAG = \"latest\";\n\nexport interface UpgradeCommandOptions {\n dryRun?: boolean;\n cliOnly?: boolean;\n packagesOnly?: boolean;\n project?: boolean;\n local?: boolean;\n global?: boolean;\n repair?: boolean;\n tag?: string;\n packageName?: string;\n commandRunner?: UpgradeCommandRunner;\n}\n\nexport interface UpgradeCommandRunnerResult {\n stdout: string;\n stderr: string;\n}\n\nexport type UpgradeCommandRunner = (\n command: string,\n args: string[],\n options?: { cwd?: string },\n) => Promise<UpgradeCommandRunnerResult>;\n\nexport interface UpgradeCliResult {\n requested: boolean;\n status: \"planned\" | \"updated\" | \"failed\" | \"skipped\";\n package: string;\n target: string;\n command: string[];\n before_version?: string;\n after_version?: string;\n repair: boolean;\n reason?: string;\n error?: string;\n}\n\nexport interface UpgradePackageResult {\n name: string;\n directory: string;\n scope: ExtensionScope;\n source: ManagedExtensionSource;\n status: \"planned\" | \"updated\" | \"failed\" | \"skipped\";\n command: string[];\n previous_version: string;\n installed_version?: string;\n reason?: string;\n error?: string;\n}\n\nexport interface UpgradeResult {\n ok: boolean;\n action: \"upgrade\";\n dry_run: boolean;\n scope: ExtensionScope;\n target?: string;\n cli: UpgradeCliResult;\n packages: UpgradePackageResult[];\n summary: {\n requested_cli: boolean;\n requested_packages: boolean;\n planned: number;\n updated: number;\n skipped: number;\n failed: number;\n };\n}\n\nfunction resolveScope(options: UpgradeCommandOptions): ExtensionScope {\n const projectLike = options.project === true || options.local === true;\n const global = options.global === true;\n if (projectLike && global) {\n throw new PmCliError('Options \"--project/--local\" and \"--global\" are mutually exclusive.', EXIT_CODE.USAGE);\n }\n return global ? \"global\" : \"project\";\n}\n\nfunction normalizeTarget(value: string): string {\n return value.trim().toLowerCase();\n}\n\nfunction packageRecordMatchesTarget(record: ManagedExtensionRecord, target: string): boolean {\n const normalizedTarget = normalizeTarget(target);\n const values = [\n record.name,\n record.directory,\n record.source.input,\n record.source.location,\n record.source.package,\n record.source.repository,\n record.source.owner && record.source.repo ? `${record.source.owner}/${record.source.repo}` : undefined,\n ];\n return values.some((value) => typeof value === \"string\" && normalizeTarget(value) === normalizedTarget);\n}\n\nfunction resolveRoots(scope: ExtensionScope, global: GlobalOptions): {\n selected_root: string;\n} {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n const roots = resolveExtensionRoots(pmRoot, process.cwd());\n return {\n selected_root: scope === \"global\" ? roots.global : roots.project,\n };\n}\n\nasync function defaultCommandRunner(\n command: string,\n args: string[],\n options?: { cwd?: string },\n): Promise<UpgradeCommandRunnerResult> {\n try {\n const result = await execFileAsync(command, args, {\n cwd: options?.cwd,\n encoding: \"utf8\",\n });\n return {\n stdout: result.stdout ?? \"\",\n stderr: result.stderr ?? \"\",\n };\n } catch (error: unknown) {\n const stderr = typeof error === \"object\" && error !== null && \"stderr\" in error\n ? String((error as { stderr?: unknown }).stderr ?? \"\")\n : \"\";\n const message = stderr.trim().length > 0 ? stderr.trim() : error instanceof Error ? error.message : String(error);\n throw new PmCliError(`Command failed: ${command} ${args.join(\" \")}\\n${message}`, EXIT_CODE.GENERIC_FAILURE);\n }\n}\n\nasync function readCurrentVersion(): Promise<string | undefined> {\n const packageJsonPath = path.join(resolvePmPackageRootFromModule(import.meta.url, [\"../../..\"]), \"package.json\");\n try {\n const parsed = JSON.parse(await fs.readFile(packageJsonPath, \"utf8\")) as { version?: unknown };\n return typeof parsed.version === \"string\" ? parsed.version : undefined;\n } catch {\n return undefined;\n }\n}\n\nfunction resolveTag(options: UpgradeCommandOptions): string {\n return typeof options.tag === \"string\" && options.tag.trim().length > 0 ? options.tag.trim() : DEFAULT_TAG;\n}\n\nfunction resolveCliPackage(options: UpgradeCommandOptions): string {\n return typeof options.packageName === \"string\" && options.packageName.trim().length > 0\n ? options.packageName.trim()\n : DEFAULT_CLI_PACKAGE;\n}\n\nasync function upgradeCli(options: UpgradeCommandOptions, dryRun: boolean): Promise<UpgradeCliResult> {\n const runner = options.commandRunner ?? defaultCommandRunner;\n const packageName = resolveCliPackage(options);\n const tag = resolveTag(options);\n const target = `${packageName}@${tag}`;\n const command = [\"npm\", \"install\", \"-g\", target];\n if (options.repair === true) {\n command.push(\"--force\");\n }\n const beforeVersion = await readCurrentVersion();\n const planned: UpgradeCliResult = {\n requested: true,\n status: \"planned\",\n package: packageName,\n target,\n command,\n before_version: beforeVersion,\n repair: options.repair === true,\n };\n if (dryRun) {\n return planned;\n }\n try {\n await runner(command[0]!, command.slice(1));\n const verified = await runner(\"pm\", [\"--version\"]);\n return {\n ...planned,\n status: \"updated\",\n after_version: verified.stdout.trim() || undefined,\n };\n } catch (error: unknown) {\n return {\n ...planned,\n status: \"failed\",\n error: error instanceof Error ? error.message : String(error),\n };\n }\n}\n\nfunction isLocalNpmSpec(spec: string): boolean {\n return path.isAbsolute(spec) || spec.startsWith(\".\") || spec.startsWith(\"..\") || spec.startsWith(\"file:\");\n}\n\nfunction resolvePackageInstallSource(source: ManagedExtensionSource, tag: string): string {\n if (source.kind === \"npm\") {\n const rawSpec = source.input.startsWith(\"npm:\") ? source.input.slice(\"npm:\".length).trim() : source.input.trim();\n if (!isLocalNpmSpec(rawSpec) && source.package && source.package.trim().length > 0) {\n return `npm:${source.package.trim()}@${tag}`;\n }\n return source.input.startsWith(\"npm:\") ? source.input : `npm:${source.input}`;\n }\n return source.input;\n}\n\nasync function resolveRunnablePackageSource(source: ManagedExtensionSource, tag: string): Promise<string> {\n const installSource = resolvePackageInstallSource(source, tag);\n if (source.kind !== \"local\") {\n return installSource;\n }\n if (await pathExists(installSource)) {\n return installSource;\n }\n if (await pathExists(source.location)) {\n return source.location;\n }\n return installSource;\n}\n\nfunction packageCommandFor(source: ManagedExtensionSource, installSource: string, scope: ExtensionScope, ref?: string): string[] {\n const command = [\"pm\", \"install\", installSource, scope === \"global\" ? \"--global\" : \"--project\"];\n if (source.kind === \"github\" && ref && ref.trim().length > 0) {\n command.push(\"--ref\", ref.trim());\n }\n return command;\n}\n\nasync function readManagedRecords(scope: ExtensionScope, global: GlobalOptions): Promise<ManagedExtensionRecord[]> {\n const roots = resolveRoots(scope, global);\n const managedState = await readManagedExtensionState(roots.selected_root);\n return managedState.state.entries.filter((entry) => entry.scope === scope);\n}\n\nasync function refreshManagedRecord(\n scope: ExtensionScope,\n global: GlobalOptions,\n record: ManagedExtensionRecord,\n): Promise<ManagedExtensionRecord | undefined> {\n const records = await readManagedRecords(scope, global);\n return records.find((candidate) => packageRecordMatchesTarget(candidate, record.name)) ??\n records.find((candidate) => normalizeTarget(candidate.directory) === normalizeTarget(record.directory));\n}\n\nasync function upgradePackageRecord(\n record: ManagedExtensionRecord,\n options: UpgradeCommandOptions,\n global: GlobalOptions,\n scope: ExtensionScope,\n dryRun: boolean,\n): Promise<UpgradePackageResult> {\n const tag = resolveTag(options);\n const installSource = await resolveRunnablePackageSource(record.source, tag);\n const command = packageCommandFor(record.source, installSource, scope, record.source.ref);\n const planned: UpgradePackageResult = {\n name: record.name,\n directory: record.directory,\n scope,\n source: record.source,\n status: \"planned\",\n command,\n previous_version: record.manifest_version,\n };\n if (dryRun) {\n return planned;\n }\n try {\n await runExtension(\n installSource,\n {\n install: true,\n project: scope === \"project\",\n global: scope === \"global\",\n ref: record.source.kind === \"github\" ? record.source.ref : undefined,\n },\n global,\n );\n const refreshed = await refreshManagedRecord(scope, global, record);\n return {\n ...planned,\n status: \"updated\",\n installed_version: refreshed?.manifest_version,\n };\n } catch (error: unknown) {\n return {\n ...planned,\n status: \"failed\",\n error: error instanceof Error ? error.message : String(error),\n };\n }\n}\n\nfunction summarize(\n cli: UpgradeCliResult,\n packages: UpgradePackageResult[],\n includeCli: boolean,\n includePackages: boolean,\n): UpgradeResult[\"summary\"] {\n const statuses = [includeCli ? cli.status : undefined, ...packages.map((entry) => entry.status)].filter(\n (value): value is UpgradeCliResult[\"status\"] => typeof value === \"string\",\n );\n return {\n requested_cli: includeCli,\n requested_packages: includePackages,\n planned: statuses.filter((status) => status === \"planned\").length,\n updated: statuses.filter((status) => status === \"updated\").length,\n skipped: statuses.filter((status) => status === \"skipped\").length,\n failed: statuses.filter((status) => status === \"failed\").length,\n };\n}\n\nexport async function runUpgrade(\n target: string | undefined,\n options: UpgradeCommandOptions,\n global: GlobalOptions,\n): Promise<UpgradeResult> {\n if (options.cliOnly === true && options.packagesOnly === true) {\n throw new PmCliError('Options \"--cli-only\" and \"--packages-only\" are mutually exclusive.', EXIT_CODE.USAGE);\n }\n\n const scope = resolveScope(options);\n const dryRun = options.dryRun === true;\n const normalizedTarget = typeof target === \"string\" && target.trim().length > 0 ? target.trim() : undefined;\n if (options.cliOnly === true && normalizedTarget) {\n throw new PmCliError('A package target cannot be used with \"--cli-only\".', EXIT_CODE.USAGE);\n }\n const includeCli = options.packagesOnly === true || normalizedTarget ? false : true;\n const includePackages = options.cliOnly === true ? false : true;\n const cli = includeCli\n ? await upgradeCli(options, dryRun)\n : {\n requested: false,\n status: \"skipped\",\n package: resolveCliPackage(options),\n target: `${resolveCliPackage(options)}@${resolveTag(options)}`,\n command: [\"npm\", \"install\", \"-g\", `${resolveCliPackage(options)}@${resolveTag(options)}`],\n repair: options.repair === true,\n reason: \"not_requested\",\n } as UpgradeCliResult;\n\n let packageRecords = includePackages ? await readManagedRecords(scope, global) : [];\n if (normalizedTarget) {\n packageRecords = packageRecords.filter((entry) => packageRecordMatchesTarget(entry, normalizedTarget));\n if (packageRecords.length === 0) {\n throw new PmCliError(`Managed package \"${normalizedTarget}\" was not found in ${scope} scope.`, EXIT_CODE.NOT_FOUND);\n }\n }\n\n const packages: UpgradePackageResult[] = [];\n for (const record of packageRecords) {\n packages.push(await upgradePackageRecord(record, options, global, scope, dryRun));\n }\n\n const summary = summarize(cli, packages, includeCli, includePackages);\n return {\n ok: summary.failed === 0,\n action: \"upgrade\",\n dry_run: dryRun,\n scope,\n target: normalizedTarget,\n cli,\n packages,\n summary,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,SAAS,gBAAgB;AACzB,OAAO,QAAQ;AACf,OAAO,UAAU;AACjB,SAAS,iBAAiB;AAgB1B,IAAM,gBAAgB,UAAU,QAAQ;AACxC,IAAM,sBAAsB;AAC5B,IAAM,cAAc;AAsEpB,SAAS,aAAa,SAA8B;AAClD,QAAM,cAAc,QAAQ,YAAY,QAAQ,QAAQ,UAAU;AAClE,QAAM,SAAS,QAAQ,WAAW;AAClC,MAAI,eAAe,QAAQ;AACzB,UAAM,IAAI,WAAW,sEAAsE,UAAU,KAAK;EAC5G;AACA,SAAO,SAAS,WAAW;AAC7B;AAEA,SAAS,gBAAgB,OAAa;AACpC,SAAO,MAAM,KAAI,EAAG,YAAW;AACjC;AAEA,SAAS,2BAA2B,QAAgC,QAAc;AAChF,QAAM,mBAAmB,gBAAgB,MAAM;AAC/C,QAAM,SAAS;IACb,OAAO;IACP,OAAO;IACP,OAAO,OAAO;IACd,OAAO,OAAO;IACd,OAAO,OAAO;IACd,OAAO,OAAO;IACd,OAAO,OAAO,SAAS,OAAO,OAAO,OAAO,GAAG,OAAO,OAAO,KAAK,IAAI,OAAO,OAAO,IAAI,KAAK;;AAE/F,SAAO,OAAO,KAAK,CAAC,UAAU,OAAO,UAAU,YAAY,gBAAgB,KAAK,MAAM,gBAAgB;AACxG;AAEA,SAAS,aAAa,OAAuB,QAAqB;AAGhE,QAAM,SAAS,cAAc,QAAQ,IAAG,GAAI,OAAO,IAAI;AACvD,QAAM,QAAQ,sBAAsB,QAAQ,QAAQ,IAAG,CAAE;AACzD,SAAO;IACL,eAAe,UAAU,WAAW,MAAM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,QAAQ,iBAAiB,QAAQ,mBAAmB,QAAQ;AAC/E,QAAM,kBAAkB,QAAQ,YAAY,OAAO,QAAQ;AAC3D,QAAM,MAAM,aACR,MAAM,WAAW,SAAS,MAAM,IAChC;IACE,WAAW;IACX,QAAQ;IACR,SAAS,kBAAkB,OAAO;IAClC,QAAQ,GAAG,kBAAkB,OAAO,CAAC,IAAI,WAAW,OAAO,CAAC;IAC5D,SAAS,CAAC,OAAO,WAAW,MAAM,GAAG,kBAAkB,OAAO,CAAC,IAAI,WAAW,OAAO,CAAC,EAAE;IACxF,QAAQ,QAAQ,WAAW;IAC3B,QAAQ;;AAGd,MAAI,iBAAiB,kBAAkB,MAAM,mBAAmB,OAAO,MAAM,IAAI,CAAA;AACjF,MAAI,kBAAkB;AACpB,qBAAiB,eAAe,OAAO,CAAC,UAAU,2BAA2B,OAAO,gBAAgB,CAAC;AACrG,QAAI,eAAe,WAAW,GAAG;AAC/B,YAAM,IAAI,WAAW,oBAAoB,gBAAgB,sBAAsB,KAAK,WAAW,UAAU,SAAS;IACpH;EACF;AAEA,QAAM,WAAmC,CAAA;AACzC,aAAW,UAAU,gBAAgB;AACnC,aAAS,KAAK,MAAM,qBAAqB,QAAQ,SAAS,QAAQ,OAAO,MAAM,CAAC;EAClF;AAEA,QAAM,UAAU,UAAU,KAAK,UAAU,YAAY,eAAe;AACpE,SAAO;IACL,IAAI,QAAQ,WAAW;IACvB,QAAQ;IACR,SAAS;IACT;IACA,QAAQ;IACR;IACA;IACA;;AAEJ","debugId":"3018215e-a9aa-5978-8f18-8beac74746e8"}
|
|
1
|
+
{"version":3,"sources":["../../../../../../../../cli/commands/upgrade.ts"],"sourcesContent":["import { execFile } from \"node:child_process\";\nimport fs from \"node:fs/promises\";\nimport path from \"node:path\";\nimport { promisify } from \"node:util\";\nimport {\n readManagedExtensionState,\n runExtension,\n type ExtensionScope,\n type ManagedExtensionRecord,\n type ManagedExtensionSource,\n} from \"./extension.js\";\nimport { resolveExtensionRoots } from \"../../core/extensions/loader.js\";\nimport { pathExists } from \"../../core/fs/fs-utils.js\";\nimport type { GlobalOptions } from \"../../core/shared/command-types.js\";\nimport { EXIT_CODE } from \"../../core/shared/constants.js\";\nimport { PmCliError } from \"../../core/shared/errors.js\";\nimport { resolvePmRoot } from \"../../core/store/paths.js\";\nimport { resolvePmPackageRootFromModule } from \"../../core/packages/root.js\";\n\nconst execFileAsync = promisify(execFile);\nconst DEFAULT_CLI_PACKAGE = \"@unbrained/pm-cli\";\nconst DEFAULT_TAG = \"latest\";\n\nexport interface UpgradeCommandOptions {\n dryRun?: boolean;\n cliOnly?: boolean;\n packagesOnly?: boolean;\n project?: boolean;\n local?: boolean;\n global?: boolean;\n repair?: boolean;\n tag?: string;\n packageName?: string;\n commandRunner?: UpgradeCommandRunner;\n}\n\nexport interface UpgradeCommandRunnerResult {\n stdout: string;\n stderr: string;\n}\n\nexport type UpgradeCommandRunner = (\n command: string,\n args: string[],\n options?: { cwd?: string },\n) => Promise<UpgradeCommandRunnerResult>;\n\nexport interface UpgradeCliResult {\n requested: boolean;\n status: \"planned\" | \"updated\" | \"failed\" | \"skipped\";\n package: string;\n target: string;\n command: string[];\n before_version?: string;\n after_version?: string;\n repair: boolean;\n reason?: string;\n error?: string;\n}\n\nexport interface UpgradePackageResult {\n name: string;\n directory: string;\n scope: ExtensionScope;\n source: ManagedExtensionSource;\n status: \"planned\" | \"updated\" | \"failed\" | \"skipped\";\n command: string[];\n previous_version: string;\n installed_version?: string;\n reason?: string;\n error?: string;\n}\n\nexport interface UpgradeResult {\n ok: boolean;\n action: \"upgrade\";\n dry_run: boolean;\n scope: ExtensionScope;\n target?: string;\n cli: UpgradeCliResult;\n packages: UpgradePackageResult[];\n summary: {\n requested_cli: boolean;\n requested_packages: boolean;\n planned: number;\n updated: number;\n skipped: number;\n failed: number;\n };\n}\n\nfunction resolveScope(options: UpgradeCommandOptions): ExtensionScope {\n const projectLike = options.project === true || options.local === true;\n const global = options.global === true;\n if (projectLike && global) {\n throw new PmCliError('Options \"--project/--local\" and \"--global\" are mutually exclusive.', EXIT_CODE.USAGE);\n }\n return global ? \"global\" : \"project\";\n}\n\nfunction normalizeTarget(value: string): string {\n return value.trim().toLowerCase();\n}\n\nfunction packageRecordMatchesTarget(record: ManagedExtensionRecord, target: string): boolean {\n const normalizedTarget = normalizeTarget(target);\n const values = [\n record.name,\n record.directory,\n record.source.input,\n record.source.location,\n record.source.package,\n record.source.repository,\n record.source.owner && record.source.repo ? `${record.source.owner}/${record.source.repo}` : undefined,\n ];\n return values.some((value) => typeof value === \"string\" && normalizeTarget(value) === normalizedTarget);\n}\n\nfunction resolveRoots(scope: ExtensionScope, global: GlobalOptions): {\n selected_root: string;\n} {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n const roots = resolveExtensionRoots(pmRoot, process.cwd());\n return {\n selected_root: scope === \"global\" ? roots.global : roots.project,\n };\n}\n\nasync function defaultCommandRunner(\n command: string,\n args: string[],\n options?: { cwd?: string },\n): Promise<UpgradeCommandRunnerResult> {\n try {\n const result = await execFileAsync(command, args, {\n cwd: options?.cwd,\n encoding: \"utf8\",\n });\n return {\n stdout: result.stdout ?? \"\",\n stderr: result.stderr ?? \"\",\n };\n } catch (error: unknown) {\n const stderr = typeof error === \"object\" && error !== null && \"stderr\" in error\n ? String((error as { stderr?: unknown }).stderr ?? \"\")\n : \"\";\n const message = stderr.trim().length > 0 ? stderr.trim() : error instanceof Error ? error.message : String(error);\n throw new PmCliError(`Command failed: ${command} ${args.join(\" \")}\\n${message}`, EXIT_CODE.GENERIC_FAILURE);\n }\n}\n\nasync function readCurrentVersion(): Promise<string | undefined> {\n const packageJsonPath = path.join(resolvePmPackageRootFromModule(import.meta.url, [\"../../..\"]), \"package.json\");\n try {\n const parsed = JSON.parse(await fs.readFile(packageJsonPath, \"utf8\")) as { version?: unknown };\n return typeof parsed.version === \"string\" ? parsed.version : undefined;\n } catch {\n return undefined;\n }\n}\n\nfunction resolveTag(options: UpgradeCommandOptions): string {\n return typeof options.tag === \"string\" && options.tag.trim().length > 0 ? options.tag.trim() : DEFAULT_TAG;\n}\n\nfunction resolveCliPackage(options: UpgradeCommandOptions): string {\n return typeof options.packageName === \"string\" && options.packageName.trim().length > 0\n ? options.packageName.trim()\n : DEFAULT_CLI_PACKAGE;\n}\n\nasync function upgradeCli(options: UpgradeCommandOptions, dryRun: boolean): Promise<UpgradeCliResult> {\n const runner = options.commandRunner ?? defaultCommandRunner;\n const packageName = resolveCliPackage(options);\n const tag = resolveTag(options);\n const target = `${packageName}@${tag}`;\n const command = [\"npm\", \"install\", \"-g\", target];\n if (options.repair === true) {\n command.push(\"--force\");\n }\n const beforeVersion = await readCurrentVersion();\n const planned: UpgradeCliResult = {\n requested: true,\n status: \"planned\",\n package: packageName,\n target,\n command,\n before_version: beforeVersion,\n repair: options.repair === true,\n };\n if (dryRun) {\n return planned;\n }\n try {\n await runner(command[0]!, command.slice(1));\n const verified = await runner(\"pm\", [\"--version\"]);\n return {\n ...planned,\n status: \"updated\",\n after_version: verified.stdout.trim() || undefined,\n };\n } catch (error: unknown) {\n return {\n ...planned,\n status: \"failed\",\n error: error instanceof Error ? error.message : String(error),\n };\n }\n}\n\nfunction isLocalNpmSpec(spec: string): boolean {\n return path.isAbsolute(spec) || spec.startsWith(\".\") || spec.startsWith(\"..\") || spec.startsWith(\"file:\");\n}\n\nfunction resolvePackageInstallSource(source: ManagedExtensionSource, tag: string): string {\n if (source.kind === \"npm\") {\n const rawSpec = source.input.startsWith(\"npm:\") ? source.input.slice(\"npm:\".length).trim() : source.input.trim();\n if (!isLocalNpmSpec(rawSpec) && source.package && source.package.trim().length > 0) {\n return `npm:${source.package.trim()}@${tag}`;\n }\n return source.input.startsWith(\"npm:\") ? source.input : `npm:${source.input}`;\n }\n return source.input;\n}\n\nasync function resolveRunnablePackageSource(source: ManagedExtensionSource, tag: string): Promise<string> {\n const installSource = resolvePackageInstallSource(source, tag);\n if (source.kind !== \"local\") {\n return installSource;\n }\n if (await pathExists(installSource)) {\n return installSource;\n }\n if (await pathExists(source.location)) {\n return source.location;\n }\n return installSource;\n}\n\nfunction packageCommandFor(source: ManagedExtensionSource, installSource: string, scope: ExtensionScope, ref?: string): string[] {\n const command = [\"pm\", \"install\", installSource, scope === \"global\" ? \"--global\" : \"--project\"];\n if (source.kind === \"github\" && ref && ref.trim().length > 0) {\n command.push(\"--ref\", ref.trim());\n }\n return command;\n}\n\nasync function readManagedRecords(scope: ExtensionScope, global: GlobalOptions): Promise<ManagedExtensionRecord[]> {\n const roots = resolveRoots(scope, global);\n const managedState = await readManagedExtensionState(roots.selected_root);\n return managedState.state.entries.filter((entry) => entry.scope === scope);\n}\n\nasync function refreshManagedRecord(\n scope: ExtensionScope,\n global: GlobalOptions,\n record: ManagedExtensionRecord,\n): Promise<ManagedExtensionRecord | undefined> {\n const records = await readManagedRecords(scope, global);\n return records.find((candidate) => packageRecordMatchesTarget(candidate, record.name)) ??\n records.find((candidate) => normalizeTarget(candidate.directory) === normalizeTarget(record.directory));\n}\n\nasync function upgradePackageRecord(\n record: ManagedExtensionRecord,\n options: UpgradeCommandOptions,\n global: GlobalOptions,\n scope: ExtensionScope,\n dryRun: boolean,\n): Promise<UpgradePackageResult> {\n const tag = resolveTag(options);\n const installSource = await resolveRunnablePackageSource(record.source, tag);\n const command = packageCommandFor(record.source, installSource, scope, record.source.ref);\n const planned: UpgradePackageResult = {\n name: record.name,\n directory: record.directory,\n scope,\n source: record.source,\n status: \"planned\",\n command,\n previous_version: record.manifest_version,\n };\n if (dryRun) {\n return planned;\n }\n try {\n await runExtension(\n installSource,\n {\n install: true,\n project: scope === \"project\",\n global: scope === \"global\",\n ref: record.source.kind === \"github\" ? record.source.ref : undefined,\n },\n global,\n );\n const refreshed = await refreshManagedRecord(scope, global, record);\n return {\n ...planned,\n status: \"updated\",\n installed_version: refreshed?.manifest_version,\n };\n } catch (error: unknown) {\n return {\n ...planned,\n status: \"failed\",\n error: error instanceof Error ? error.message : String(error),\n };\n }\n}\n\nfunction summarize(\n cli: UpgradeCliResult,\n packages: UpgradePackageResult[],\n includeCli: boolean,\n includePackages: boolean,\n): UpgradeResult[\"summary\"] {\n const statuses = [includeCli ? cli.status : undefined, ...packages.map((entry) => entry.status)].filter(\n (value): value is UpgradeCliResult[\"status\"] => typeof value === \"string\",\n );\n return {\n requested_cli: includeCli,\n requested_packages: includePackages,\n planned: statuses.filter((status) => status === \"planned\").length,\n updated: statuses.filter((status) => status === \"updated\").length,\n skipped: statuses.filter((status) => status === \"skipped\").length,\n failed: statuses.filter((status) => status === \"failed\").length,\n };\n}\n\nexport async function runUpgrade(\n target: string | undefined,\n options: UpgradeCommandOptions,\n global: GlobalOptions,\n): Promise<UpgradeResult> {\n if (options.cliOnly === true && options.packagesOnly === true) {\n throw new PmCliError('Options \"--cli-only\" and \"--packages-only\" are mutually exclusive.', EXIT_CODE.USAGE);\n }\n\n const scope = resolveScope(options);\n const dryRun = options.dryRun === true;\n const normalizedTarget = typeof target === \"string\" && target.trim().length > 0 ? target.trim() : undefined;\n if (options.cliOnly === true && normalizedTarget) {\n throw new PmCliError('A package target cannot be used with \"--cli-only\".', EXIT_CODE.USAGE);\n }\n const includeCli = options.packagesOnly === true || normalizedTarget ? false : true;\n const includePackages = options.cliOnly === true ? false : true;\n const cli = includeCli\n ? await upgradeCli(options, dryRun)\n : {\n requested: false,\n status: \"skipped\",\n package: resolveCliPackage(options),\n target: `${resolveCliPackage(options)}@${resolveTag(options)}`,\n command: [\"npm\", \"install\", \"-g\", `${resolveCliPackage(options)}@${resolveTag(options)}`],\n repair: options.repair === true,\n reason: \"not_requested\",\n } as UpgradeCliResult;\n\n let packageRecords = includePackages ? await readManagedRecords(scope, global) : [];\n if (normalizedTarget) {\n packageRecords = packageRecords.filter((entry) => packageRecordMatchesTarget(entry, normalizedTarget));\n if (packageRecords.length === 0) {\n throw new PmCliError(`Managed package \"${normalizedTarget}\" was not found in ${scope} scope.`, EXIT_CODE.NOT_FOUND);\n }\n }\n\n const packages: UpgradePackageResult[] = [];\n for (const record of packageRecords) {\n packages.push(await upgradePackageRecord(record, options, global, scope, dryRun));\n }\n\n const summary = summarize(cli, packages, includeCli, includePackages);\n return {\n ok: summary.failed === 0,\n action: \"upgrade\",\n dry_run: dryRun,\n scope,\n target: normalizedTarget,\n cli,\n packages,\n summary,\n };\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,SAAS,gBAAgB;AACzB,OAAO,QAAQ;AACf,OAAO,UAAU;AACjB,SAAS,iBAAiB;AAgB1B,IAAM,gBAAgB,UAAU,QAAQ;AACxC,IAAM,sBAAsB;AAC5B,IAAM,cAAc;AAsEpB,SAAS,aAAa,SAA8B;AAClD,QAAM,cAAc,QAAQ,YAAY,QAAQ,QAAQ,UAAU;AAClE,QAAM,SAAS,QAAQ,WAAW;AAClC,MAAI,eAAe,QAAQ;AACzB,UAAM,IAAI,WAAW,sEAAsE,UAAU,KAAK;EAC5G;AACA,SAAO,SAAS,WAAW;AAC7B;AAEA,SAAS,gBAAgB,OAAa;AACpC,SAAO,MAAM,KAAI,EAAG,YAAW;AACjC;AAEA,SAAS,2BAA2B,QAAgC,QAAc;AAChF,QAAM,mBAAmB,gBAAgB,MAAM;AAC/C,QAAM,SAAS;IACb,OAAO;IACP,OAAO;IACP,OAAO,OAAO;IACd,OAAO,OAAO;IACd,OAAO,OAAO;IACd,OAAO,OAAO;IACd,OAAO,OAAO,SAAS,OAAO,OAAO,OAAO,GAAG,OAAO,OAAO,KAAK,IAAI,OAAO,OAAO,IAAI,KAAK;;AAE/F,SAAO,OAAO,KAAK,CAAC,UAAU,OAAO,UAAU,YAAY,gBAAgB,KAAK,MAAM,gBAAgB;AACxG;AAEA,SAAS,aAAa,OAAuB,QAAqB;AAGhE,QAAM,SAAS,cAAc,QAAQ,IAAG,GAAI,OAAO,IAAI;AACvD,QAAM,QAAQ,sBAAsB,QAAQ,QAAQ,IAAG,CAAE;AACzD,SAAO;IACL,eAAe,UAAU,WAAW,MAAM,SA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AQ,iBAAiB,QAAQ,mBAAmB,QAAQ;AAC/E,QAAM,kBAAkB,QAAQ,YAAY,OAAO,QAAQ;AAC3D,QAAM,MAAM,aACR,MAAM,WAAW,SAAS,MAAM,IAChC;IACE,WAAW;IACX,QAAQ;IACR,SAAS,kBAAkB,OAAO;IAClC,QAAQ,GAAG,kBAAkB,OAAO,CAAC,IAAI,WAAW,OAAO,CAAC;IAC5D,SAAS,CAAC,OAAO,WAAW,MAAM,GAAG,kBAAkB,OAAO,CAAC,IAAI,WAAW,OAAO,CAAC,EAAE;IACxF,QAAQ,QAAQ,WAAW;IAC3B,QAAQ;;AAGd,MAAI,iBAAiB,kBAAkB,MAAM,mBAAmB,OAAO,MAAM,IAAI,CAAA;AACjF,MAAI,kBAAkB;AACpB,qBAAiB,eAAe,OAAO,CAAC,UAAU,2BAA2B,OAAO,gBAAgB,CAAC;AACrG,QAAI,eAAe,WAAW,GAAG;AAC/B,YAAM,IAAI,WAAW,oBAAoB,gBAAgB,sBAAsB,KAAK,WAAW,UAAU,SAAS;IACpH;EACF;AAEA,QAAM,WAAmC,CAAA;AACzC,aAAW,UAAU,gBAAgB;AACnC,aAAS,KAAK,MAAM,qBAAqB,QAAQ,SAAS,QAAQ,OAAO,MAAM,CAAC;EAClF;AAEA,QAAM,UAAU,UAAU,KAAK,UAAU,YAAY,eAAe;AACpE,SAAO;IACL,IAAI,QAAQ,WAAW;IACvB,QAAQ;IACR,SAAS;IACT;IACA,QAAQ;IACR;IACA;IACA;;AAEJ","debugId":"734ae313-5aff-5b24-a782-7b005770ea2d"}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
readManagedExtensionState,
|
|
3
3
|
runExtension
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-KR6R465K.js";
|
|
5
|
+
import "./chunk-THDEID2Z.js";
|
|
5
6
|
import "./chunk-3HUE7XOF.js";
|
|
6
|
-
import "./chunk-
|
|
7
|
+
import "./chunk-FHHBD7PN.js";
|
|
7
8
|
import {
|
|
8
9
|
EXIT_CODE,
|
|
9
10
|
PmCliError,
|
|
@@ -11,7 +12,7 @@ import {
|
|
|
11
12
|
resolveExtensionRoots,
|
|
12
13
|
resolvePmPackageRootFromModule,
|
|
13
14
|
resolvePmRoot
|
|
14
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-UJUT6AHZ.js";
|
|
15
16
|
|
|
16
17
|
// dist/cli/commands/upgrade.js
|
|
17
18
|
import { execFile } from "node:child_process";
|
|
@@ -266,4 +267,4 @@ async function runUpgrade(target, options, global2) {
|
|
|
266
267
|
export {
|
|
267
268
|
runUpgrade
|
|
268
269
|
};
|
|
269
|
-
//# sourceMappingURL=upgrade-
|
|
270
|
+
//# sourceMappingURL=upgrade-YWI5DJFA.js.map
|