@unbrained/pm-cli 2026.5.30 → 2026.6.5
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 +152 -0
- package/dist/cli/argv-utils.js +7 -3
- package/dist/cli/argv-utils.js.map +1 -1
- package/dist/cli/bootstrap-args.d.ts +1 -0
- package/dist/cli/bootstrap-args.js +23 -3
- package/dist/cli/bootstrap-args.js.map +1 -1
- package/dist/cli/commands/calendar.js +96 -10
- package/dist/cli/commands/calendar.js.map +1 -1
- package/dist/cli/commands/close-many.d.ts +63 -0
- package/dist/cli/commands/close-many.js +302 -0
- package/dist/cli/commands/close-many.js.map +1 -0
- package/dist/cli/commands/completion.d.ts +1 -0
- package/dist/cli/commands/completion.js +241 -27
- package/dist/cli/commands/completion.js.map +1 -1
- package/dist/cli/commands/config.d.ts +4 -4
- package/dist/cli/commands/config.js +115 -3
- package/dist/cli/commands/config.js.map +1 -1
- package/dist/cli/commands/contracts.js +191 -162
- package/dist/cli/commands/contracts.js.map +1 -1
- package/dist/cli/commands/create.d.ts +1 -0
- package/dist/cli/commands/create.js +109 -116
- package/dist/cli/commands/create.js.map +1 -1
- package/dist/cli/commands/extension/doctor.d.ts +12 -0
- package/dist/cli/commands/extension/doctor.js +97 -2
- package/dist/cli/commands/extension/doctor.js.map +1 -1
- package/dist/cli/commands/extension/install-sources.d.ts +2 -0
- package/dist/cli/commands/extension/install-sources.js +11 -4
- package/dist/cli/commands/extension/install-sources.js.map +1 -1
- package/dist/cli/commands/extension/scaffold.js +49 -48
- package/dist/cli/commands/extension/scaffold.js.map +1 -1
- package/dist/cli/commands/extension.js +51 -23
- package/dist/cli/commands/extension.js.map +1 -1
- package/dist/cli/commands/get.js +7 -7
- package/dist/cli/commands/get.js.map +1 -1
- package/dist/cli/commands/health.js +38 -3
- package/dist/cli/commands/health.js.map +1 -1
- package/dist/cli/commands/index.d.ts +2 -1
- package/dist/cli/commands/index.js +4 -3
- package/dist/cli/commands/index.js.map +1 -1
- package/dist/cli/commands/init.d.ts +10 -0
- package/dist/cli/commands/init.js +107 -4
- package/dist/cli/commands/init.js.map +1 -1
- package/dist/cli/commands/list.d.ts +5 -0
- package/dist/cli/commands/list.js +58 -26
- package/dist/cli/commands/list.js.map +1 -1
- package/dist/cli/commands/reindex.js +164 -48
- package/dist/cli/commands/reindex.js.map +1 -1
- package/dist/cli/commands/repeatable-metadata-parsers.d.ts +15 -0
- package/dist/cli/commands/repeatable-metadata-parsers.js +120 -0
- package/dist/cli/commands/repeatable-metadata-parsers.js.map +1 -0
- package/dist/cli/commands/restore.js +25 -4
- package/dist/cli/commands/restore.js.map +1 -1
- package/dist/cli/commands/schema.d.ts +122 -1
- package/dist/cli/commands/schema.js +536 -6
- package/dist/cli/commands/schema.js.map +1 -1
- package/dist/cli/commands/search.d.ts +18 -0
- package/dist/cli/commands/search.js +56 -12
- package/dist/cli/commands/search.js.map +1 -1
- package/dist/cli/commands/test.js +4 -3
- package/dist/cli/commands/test.js.map +1 -1
- package/dist/cli/commands/update-many.js +69 -140
- package/dist/cli/commands/update-many.js.map +1 -1
- package/dist/cli/commands/update.d.ts +2 -0
- package/dist/cli/commands/update.js +138 -119
- package/dist/cli/commands/update.js.map +1 -1
- package/dist/cli/commands/validate.d.ts +1 -0
- package/dist/cli/commands/validate.js +63 -33
- package/dist/cli/commands/validate.js.map +1 -1
- package/dist/cli/error-guidance.js +26 -3
- package/dist/cli/error-guidance.js.map +1 -1
- package/dist/cli/help-content.js +82 -3
- package/dist/cli/help-content.js.map +1 -1
- package/dist/cli/main.js +377 -23
- package/dist/cli/main.js.map +1 -1
- package/dist/cli/register-list-query.js +16 -12
- package/dist/cli/register-list-query.js.map +1 -1
- package/dist/cli/register-mutation.js +217 -47
- package/dist/cli/register-mutation.js.map +1 -1
- package/dist/cli/register-operations.js +34 -25
- package/dist/cli/register-operations.js.map +1 -1
- package/dist/cli/register-setup.js +8 -8
- package/dist/cli/register-setup.js.map +1 -1
- package/dist/cli/registration-helpers.js +35 -5
- package/dist/cli/registration-helpers.js.map +1 -1
- package/dist/cli/search-refresh.d.ts +2 -0
- package/dist/cli/search-refresh.js +13 -0
- package/dist/cli/search-refresh.js.map +1 -0
- package/dist/cli-bundle/chunks/activity-3RWRRNOW.js +20 -0
- package/dist/cli-bundle/chunks/activity-3RWRRNOW.js.map +1 -0
- package/dist/cli-bundle/chunks/activity-P5BUMWP3.js +16 -0
- package/dist/cli-bundle/chunks/activity-P5BUMWP3.js.map +7 -0
- package/dist/cli-bundle/chunks/aggregate-J35K7WZB.js +206 -0
- package/dist/cli-bundle/chunks/aggregate-J35K7WZB.js.map +1 -0
- package/dist/cli-bundle/chunks/aggregate-OOAGKWRG.js +209 -0
- package/dist/cli-bundle/chunks/aggregate-OOAGKWRG.js.map +7 -0
- package/dist/cli-bundle/chunks/append-5JE3YGXU.js +72 -0
- package/dist/cli-bundle/chunks/append-5JE3YGXU.js.map +7 -0
- package/dist/cli-bundle/chunks/append-PNN6UIBZ.js +69 -0
- package/dist/cli-bundle/chunks/append-PNN6UIBZ.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-26KTVXJW.js +218 -0
- package/dist/cli-bundle/chunks/chunk-26KTVXJW.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-3HUE7XOF.js +27 -0
- package/dist/cli-bundle/chunks/chunk-3HUE7XOF.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-3OH4DAEB.js +761 -0
- package/dist/cli-bundle/chunks/chunk-3OH4DAEB.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-4LTBNUYT.js +5553 -0
- package/dist/cli-bundle/chunks/chunk-4LTBNUYT.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-4PJQSECJ.js +634 -0
- package/dist/cli-bundle/chunks/chunk-4PJQSECJ.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-4QCR4QW3.js +1832 -0
- package/dist/cli-bundle/chunks/chunk-4QCR4QW3.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-5IRA6IYD.js +1891 -0
- package/dist/cli-bundle/chunks/chunk-5IRA6IYD.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-5KB4X7YY.js +412 -0
- package/dist/cli-bundle/chunks/chunk-5KB4X7YY.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-5PAOPUZX.js +182 -0
- package/dist/cli-bundle/chunks/chunk-5PAOPUZX.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-7K24QB23.js +698 -0
- package/dist/cli-bundle/chunks/chunk-7K24QB23.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-A6PEXMYN.js +380 -0
- package/dist/cli-bundle/chunks/chunk-A6PEXMYN.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-ASQM3IF5.js +230 -0
- package/dist/cli-bundle/chunks/chunk-ASQM3IF5.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-ATBVS6WW.js +185 -0
- package/dist/cli-bundle/chunks/chunk-ATBVS6WW.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-AXXKLVTW.js +332 -0
- package/dist/cli-bundle/chunks/chunk-AXXKLVTW.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-B3N4TKNL.js +1681 -0
- package/dist/cli-bundle/chunks/chunk-B3N4TKNL.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-PB2YU2E3.js → chunk-BNL6S7QH.js} +28 -70
- package/dist/cli-bundle/chunks/chunk-BNL6S7QH.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-CCUFLH4J.js +154 -0
- package/dist/cli-bundle/chunks/chunk-CCUFLH4J.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-CJDQB2ED.js +341 -0
- package/dist/cli-bundle/chunks/chunk-CJDQB2ED.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-CWT53EYT.js +1340 -0
- package/dist/cli-bundle/chunks/chunk-CWT53EYT.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-D3WUNETC.js +349 -0
- package/dist/cli-bundle/chunks/chunk-D3WUNETC.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-D5X7N6FI.js +1714 -0
- package/dist/cli-bundle/chunks/chunk-D5X7N6FI.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-DFIZGAI5.js +550 -0
- package/dist/cli-bundle/chunks/chunk-DFIZGAI5.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-DFUSXJDE.js +1704 -0
- package/dist/cli-bundle/chunks/chunk-DFUSXJDE.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-EAOG77HM.js +56 -0
- package/dist/cli-bundle/chunks/chunk-EAOG77HM.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-EHXPIKKP.js +2988 -0
- package/dist/cli-bundle/chunks/chunk-EHXPIKKP.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-FVXM3GKS.js +128 -0
- package/dist/cli-bundle/chunks/chunk-FVXM3GKS.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-G5BACLYH.js +454 -0
- package/dist/cli-bundle/chunks/chunk-G5BACLYH.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-GCAVRLGE.js +383 -0
- package/dist/cli-bundle/chunks/chunk-GCAVRLGE.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-GFWHHMVV.js +57 -0
- package/dist/cli-bundle/chunks/chunk-GFWHHMVV.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-GNHVV4SY.js +3860 -0
- package/dist/cli-bundle/chunks/chunk-GNHVV4SY.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-GPGAYASV.js +346 -0
- package/dist/cli-bundle/chunks/chunk-GPGAYASV.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-HPH6X4ZZ.js +1356 -0
- package/dist/cli-bundle/chunks/chunk-HPH6X4ZZ.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-HZOS2UG5.js +342 -0
- package/dist/cli-bundle/chunks/chunk-HZOS2UG5.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-IUV734HF.js +17 -0
- package/dist/cli-bundle/chunks/chunk-IUV734HF.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-J27KIHTG.js +15 -0
- package/dist/cli-bundle/chunks/chunk-J27KIHTG.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-JB4RGL4V.js +185 -0
- package/dist/cli-bundle/chunks/chunk-JB4RGL4V.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-JQI2HE55.js +130 -0
- package/dist/cli-bundle/chunks/chunk-JQI2HE55.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-K47WAYQV.js +60 -0
- package/dist/cli-bundle/chunks/chunk-K47WAYQV.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-KA24HME7.js +79 -0
- package/dist/cli-bundle/chunks/chunk-KA24HME7.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-KBG47ZOY.js +1325 -0
- package/dist/cli-bundle/chunks/chunk-KBG47ZOY.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-KCMIYKTA.js +242 -0
- package/dist/cli-bundle/chunks/chunk-KCMIYKTA.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-KK6YPGH3.js +221 -0
- package/dist/cli-bundle/chunks/chunk-KK6YPGH3.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-LDJK7SHN.js +157 -0
- package/dist/cli-bundle/chunks/chunk-LDJK7SHN.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-LXYVKYMQ.js +24 -0
- package/dist/cli-bundle/chunks/chunk-LXYVKYMQ.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-MISYRLEP.js +80 -0
- package/dist/cli-bundle/chunks/chunk-MISYRLEP.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-N5YF3VFN.js +457 -0
- package/dist/cli-bundle/chunks/chunk-N5YF3VFN.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-NQP3ECKF.js +173 -0
- package/dist/cli-bundle/chunks/chunk-NQP3ECKF.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-O5IBJE6S.js +338 -0
- package/dist/cli-bundle/chunks/chunk-O5IBJE6S.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-O7IWB35H.js +18 -0
- package/dist/cli-bundle/chunks/chunk-O7IWB35H.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-OIQIXTNB.js +3040 -0
- package/dist/cli-bundle/chunks/chunk-OIQIXTNB.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-ORTLYVA4.js +751 -0
- package/dist/cli-bundle/chunks/chunk-ORTLYVA4.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-OUF3ARDX.js +1861 -0
- package/dist/cli-bundle/chunks/chunk-OUF3ARDX.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-QAJBIGRA.js +20 -0
- package/dist/cli-bundle/chunks/chunk-QAJBIGRA.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-RANZIID5.js +176 -0
- package/dist/cli-bundle/chunks/chunk-RANZIID5.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-RQAWLSUU.js +140 -0
- package/dist/cli-bundle/chunks/chunk-RQAWLSUU.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-S3CV7JGJ.js +233 -0
- package/dist/cli-bundle/chunks/chunk-S3CV7JGJ.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-SRVKTWPR.js +5705 -0
- package/dist/cli-bundle/chunks/chunk-SRVKTWPR.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-SSFMJCPF.js +76 -0
- package/dist/cli-bundle/chunks/chunk-SSFMJCPF.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-SZQCER6S.js +631 -0
- package/dist/cli-bundle/chunks/chunk-SZQCER6S.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-T2ORWB6D.js +540 -0
- package/dist/cli-bundle/chunks/chunk-T2ORWB6D.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-TBQVUNVH.js +422 -0
- package/dist/cli-bundle/chunks/chunk-TBQVUNVH.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-RJONRNXN.js → chunk-TK633IVD.js} +51 -32
- package/dist/cli-bundle/chunks/chunk-TK633IVD.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-TQ3ZK6VD.js +131 -0
- package/dist/cli-bundle/chunks/chunk-TQ3ZK6VD.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-UFCG3SWR.js +119 -0
- package/dist/cli-bundle/chunks/chunk-UFCG3SWR.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-UOVLWB47.js +1664 -0
- package/dist/cli-bundle/chunks/chunk-UOVLWB47.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-V3JQ4IPL.js +186 -0
- package/dist/cli-bundle/chunks/chunk-V3JQ4IPL.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-VGO2T3TY.js +182 -0
- package/dist/cli-bundle/chunks/chunk-VGO2T3TY.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-WIKR7KFL.js +189 -0
- package/dist/cli-bundle/chunks/chunk-WIKR7KFL.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-XG7RJYHV.js +1385 -0
- package/dist/cli-bundle/chunks/chunk-XG7RJYHV.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-XSLQSXAH.js +53 -0
- package/dist/cli-bundle/chunks/chunk-XSLQSXAH.js.map +1 -0
- package/dist/cli-bundle/chunks/chunk-XX5LRINW.js +90 -0
- package/dist/cli-bundle/chunks/chunk-XX5LRINW.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-Y2AKE2HS.js +252 -0
- package/dist/cli-bundle/chunks/chunk-Y2AKE2HS.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-ZQ4F6EC4.js +3898 -0
- package/dist/cli-bundle/chunks/chunk-ZQ4F6EC4.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-ZRVSMOMR.js +1809 -0
- package/dist/cli-bundle/chunks/chunk-ZRVSMOMR.js.map +1 -0
- package/dist/cli-bundle/chunks/claim-AZLP7YFO.js +132 -0
- package/dist/cli-bundle/chunks/claim-AZLP7YFO.js.map +7 -0
- package/dist/cli-bundle/chunks/claim-ZFA7HKU4.js +129 -0
- package/dist/cli-bundle/chunks/claim-ZFA7HKU4.js.map +1 -0
- package/dist/cli-bundle/chunks/close-65DFYAVS.js +17 -0
- package/dist/cli-bundle/chunks/close-65DFYAVS.js.map +1 -0
- package/dist/cli-bundle/chunks/close-RMHQ3KWH.js +13 -0
- package/dist/cli-bundle/chunks/close-RMHQ3KWH.js.map +7 -0
- package/dist/cli-bundle/chunks/close-many-AKPZNSGI.js +311 -0
- package/dist/cli-bundle/chunks/close-many-AKPZNSGI.js.map +1 -0
- package/dist/cli-bundle/chunks/close-many-UKZSQGM7.js +314 -0
- package/dist/cli-bundle/chunks/close-many-UKZSQGM7.js.map +7 -0
- package/dist/cli-bundle/chunks/comments-AGBNSJJH.js +103 -0
- package/dist/cli-bundle/chunks/comments-AGBNSJJH.js.map +7 -0
- package/dist/cli-bundle/chunks/comments-CJWXQI7X.js +100 -0
- package/dist/cli-bundle/chunks/comments-CJWXQI7X.js.map +1 -0
- package/dist/cli-bundle/chunks/config-5ON3ADRH.js +1688 -0
- package/dist/cli-bundle/chunks/config-5ON3ADRH.js.map +7 -0
- package/dist/cli-bundle/chunks/config-DDPYIA6J.js +1671 -0
- package/dist/cli-bundle/chunks/config-DDPYIA6J.js.map +1 -0
- package/dist/cli-bundle/chunks/context-E6U3DWVM.js +1471 -0
- package/dist/cli-bundle/chunks/context-E6U3DWVM.js.map +7 -0
- package/dist/cli-bundle/chunks/context-ZOJEN5VT.js +1461 -0
- package/dist/cli-bundle/chunks/context-ZOJEN5VT.js.map +1 -0
- package/dist/cli-bundle/chunks/contracts-CXSFM45B.js +1277 -0
- package/dist/cli-bundle/chunks/contracts-CXSFM45B.js.map +7 -0
- package/dist/cli-bundle/chunks/contracts-LCSX5R53.js +1274 -0
- package/dist/cli-bundle/chunks/contracts-LCSX5R53.js.map +1 -0
- package/dist/cli-bundle/chunks/create-ATONSAZW.js +27 -0
- package/dist/cli-bundle/chunks/create-ATONSAZW.js.map +7 -0
- package/dist/cli-bundle/chunks/create-WYFKN2U4.js +31 -0
- package/dist/cli-bundle/chunks/create-WYFKN2U4.js.map +1 -0
- package/dist/cli-bundle/chunks/delete-RONNH4F4.js +58 -0
- package/dist/cli-bundle/chunks/delete-RONNH4F4.js.map +7 -0
- package/dist/cli-bundle/chunks/delete-ZXWC56WO.js +55 -0
- package/dist/cli-bundle/chunks/delete-ZXWC56WO.js.map +1 -0
- package/dist/cli-bundle/chunks/deps-EHXIFOZR.js +225 -0
- package/dist/cli-bundle/chunks/deps-EHXIFOZR.js.map +1 -0
- package/dist/cli-bundle/chunks/deps-WII3O4HB.js +228 -0
- package/dist/cli-bundle/chunks/deps-WII3O4HB.js.map +7 -0
- package/dist/cli-bundle/chunks/docs-JMVCFNHH.js +34 -0
- package/dist/cli-bundle/chunks/docs-JMVCFNHH.js.map +7 -0
- package/dist/cli-bundle/chunks/docs-PDREIMLS.js +31 -0
- package/dist/cli-bundle/chunks/docs-PDREIMLS.js.map +1 -0
- package/dist/cli-bundle/chunks/extension-B4ROVWJD.js +28 -0
- package/dist/cli-bundle/chunks/extension-B4ROVWJD.js.map +1 -0
- package/dist/cli-bundle/chunks/extension-G6UXSM5S.js +24 -0
- package/dist/cli-bundle/chunks/extension-G6UXSM5S.js.map +7 -0
- package/dist/cli-bundle/chunks/files-2PN7UM2D.js +282 -0
- package/dist/cli-bundle/chunks/files-2PN7UM2D.js.map +1 -0
- package/dist/cli-bundle/chunks/files-MXYS5W4M.js +285 -0
- package/dist/cli-bundle/chunks/files-MXYS5W4M.js.map +7 -0
- package/dist/cli-bundle/chunks/gc-GT552UJH.js +178 -0
- package/dist/cli-bundle/chunks/gc-GT552UJH.js.map +1 -0
- package/dist/cli-bundle/chunks/gc-QNBRJG6H.js +181 -0
- package/dist/cli-bundle/chunks/gc-QNBRJG6H.js.map +7 -0
- package/dist/cli-bundle/chunks/get-CINFEUIY.js +197 -0
- package/dist/cli-bundle/chunks/get-CINFEUIY.js.map +7 -0
- package/dist/cli-bundle/chunks/get-WXMLRG7M.js +194 -0
- package/dist/cli-bundle/chunks/get-WXMLRG7M.js.map +1 -0
- package/dist/cli-bundle/chunks/health-5VPOJQ53.js +1258 -0
- package/dist/cli-bundle/chunks/health-5VPOJQ53.js.map +1 -0
- package/dist/cli-bundle/chunks/health-IT5DBPRJ.js +1261 -0
- package/dist/cli-bundle/chunks/health-IT5DBPRJ.js.map +7 -0
- package/dist/cli-bundle/chunks/history-6FC4H6HI.js +20 -0
- package/dist/cli-bundle/chunks/history-6FC4H6HI.js.map +7 -0
- package/dist/cli-bundle/chunks/history-FLZIP7PM.js +24 -0
- package/dist/cli-bundle/chunks/history-FLZIP7PM.js.map +1 -0
- package/dist/cli-bundle/chunks/history-redact-SSZBAD76.js +23 -0
- package/dist/cli-bundle/chunks/history-redact-SSZBAD76.js.map +1 -0
- package/dist/cli-bundle/chunks/history-redact-XKYEZDBL.js +19 -0
- package/dist/cli-bundle/chunks/history-redact-XKYEZDBL.js.map +7 -0
- package/dist/cli-bundle/chunks/history-repair-KC5ZOJRZ.js +196 -0
- package/dist/cli-bundle/chunks/history-repair-KC5ZOJRZ.js.map +7 -0
- package/dist/cli-bundle/chunks/history-repair-X7CO5JJZ.js +193 -0
- package/dist/cli-bundle/chunks/history-repair-X7CO5JJZ.js.map +1 -0
- package/dist/cli-bundle/chunks/init-6MRFVOLH.js +20 -0
- package/dist/cli-bundle/chunks/init-6MRFVOLH.js.map +1 -0
- package/dist/cli-bundle/chunks/init-KHX3FEEM.js +16 -0
- package/dist/cli-bundle/chunks/init-KHX3FEEM.js.map +7 -0
- package/dist/cli-bundle/chunks/learnings-A3CLB5CO.js +47 -0
- package/dist/cli-bundle/chunks/learnings-A3CLB5CO.js.map +7 -0
- package/dist/cli-bundle/chunks/learnings-DCX55BNX.js +44 -0
- package/dist/cli-bundle/chunks/learnings-DCX55BNX.js.map +1 -0
- package/dist/cli-bundle/chunks/list-53LZ2AEO.js +20 -0
- package/dist/cli-bundle/chunks/list-53LZ2AEO.js.map +7 -0
- package/dist/cli-bundle/chunks/list-DBRECOG4.js +24 -0
- package/dist/cli-bundle/chunks/list-DBRECOG4.js.map +1 -0
- package/dist/cli-bundle/chunks/notes-42LIC3UE.js +47 -0
- package/dist/cli-bundle/chunks/notes-42LIC3UE.js.map +7 -0
- package/dist/cli-bundle/chunks/notes-P5O3VMQ3.js +44 -0
- package/dist/cli-bundle/chunks/notes-P5O3VMQ3.js.map +1 -0
- package/dist/cli-bundle/chunks/plan-HDQXEUKD.js +1174 -0
- package/dist/cli-bundle/chunks/plan-HDQXEUKD.js.map +7 -0
- package/dist/cli-bundle/chunks/plan-IGTE3WOJ.js +1171 -0
- package/dist/cli-bundle/chunks/plan-IGTE3WOJ.js.map +1 -0
- package/dist/cli-bundle/chunks/{register-list-query-EIVQ5FMR.js → register-list-query-AG3XKXWL.js} +25 -18
- package/dist/cli-bundle/chunks/register-list-query-AG3XKXWL.js.map +7 -0
- package/dist/cli-bundle/chunks/register-list-query-EMNSIUO4.js +227 -0
- package/dist/cli-bundle/chunks/register-list-query-EMNSIUO4.js.map +1 -0
- package/dist/cli-bundle/chunks/register-mutation-M3YS6XDO.js +813 -0
- package/dist/cli-bundle/chunks/register-mutation-M3YS6XDO.js.map +1 -0
- package/dist/cli-bundle/chunks/{register-mutation-RSZNPSGI.js → register-mutation-RSMT6DPK.js} +160 -39
- package/dist/cli-bundle/chunks/register-mutation-RSMT6DPK.js.map +7 -0
- package/dist/cli-bundle/chunks/register-operations-KYUOOOOD.js +370 -0
- package/dist/cli-bundle/chunks/register-operations-KYUOOOOD.js.map +1 -0
- package/dist/cli-bundle/chunks/{register-operations-APUSYDMR.js → register-operations-Q54JQZUN.js} +50 -32
- package/dist/cli-bundle/chunks/register-operations-Q54JQZUN.js.map +7 -0
- package/dist/cli-bundle/chunks/register-setup-DI6P7X75.js +242 -0
- package/dist/cli-bundle/chunks/register-setup-DI6P7X75.js.map +1 -0
- package/dist/cli-bundle/chunks/{register-setup-OZOKSMPJ.js → register-setup-YJKIQRKA.js} +21 -13
- package/dist/cli-bundle/chunks/register-setup-YJKIQRKA.js.map +7 -0
- package/dist/cli-bundle/chunks/restore-2XVTBLKQ.js +21 -0
- package/dist/cli-bundle/chunks/restore-2XVTBLKQ.js.map +1 -0
- package/dist/cli-bundle/chunks/restore-JL5QIH7H.js +17 -0
- package/dist/cli-bundle/chunks/restore-JL5QIH7H.js.map +7 -0
- package/dist/cli-bundle/chunks/schema-LVXZWFGY.js +770 -0
- package/dist/cli-bundle/chunks/schema-LVXZWFGY.js.map +1 -0
- package/dist/cli-bundle/chunks/schema-V6BX65Q2.js +780 -0
- package/dist/cli-bundle/chunks/schema-V6BX65Q2.js.map +7 -0
- package/dist/cli-bundle/chunks/search-5A3BMFA7.js +1144 -0
- package/dist/cli-bundle/chunks/search-5A3BMFA7.js.map +7 -0
- package/dist/cli-bundle/chunks/search-C7NPB7G7.js +1127 -0
- package/dist/cli-bundle/chunks/search-C7NPB7G7.js.map +1 -0
- package/dist/cli-bundle/chunks/stats-FNLYVXTB.js +120 -0
- package/dist/cli-bundle/chunks/stats-FNLYVXTB.js.map +1 -0
- package/dist/cli-bundle/chunks/stats-Y2CBTZSL.js +123 -0
- package/dist/cli-bundle/chunks/stats-Y2CBTZSL.js.map +7 -0
- package/dist/cli-bundle/chunks/test-OFYONO3C.js +35 -0
- package/dist/cli-bundle/chunks/test-OFYONO3C.js.map +1 -0
- package/dist/cli-bundle/chunks/test-RJ4ZF35X.js +31 -0
- package/dist/cli-bundle/chunks/test-RJ4ZF35X.js.map +7 -0
- package/dist/cli-bundle/chunks/test-all-EEMKNTGU.js +331 -0
- package/dist/cli-bundle/chunks/test-all-EEMKNTGU.js.map +7 -0
- package/dist/cli-bundle/chunks/test-all-OJE6CIO7.js +328 -0
- package/dist/cli-bundle/chunks/test-all-OJE6CIO7.js.map +1 -0
- package/dist/cli-bundle/chunks/test-runs-IPOPFOAF.js +929 -0
- package/dist/cli-bundle/chunks/test-runs-IPOPFOAF.js.map +1 -0
- package/dist/cli-bundle/chunks/test-runs-L2M7WKH7.js +939 -0
- package/dist/cli-bundle/chunks/test-runs-L2M7WKH7.js.map +7 -0
- package/dist/cli-bundle/chunks/update-6YEHPVXH.js +25 -0
- package/dist/cli-bundle/chunks/update-6YEHPVXH.js.map +1 -0
- package/dist/cli-bundle/chunks/update-PYLVHMRD.js +21 -0
- package/dist/cli-bundle/chunks/update-PYLVHMRD.js.map +7 -0
- package/dist/cli-bundle/chunks/update-many-322CCH2L.js +608 -0
- package/dist/cli-bundle/chunks/update-many-322CCH2L.js.map +7 -0
- package/dist/cli-bundle/chunks/update-many-DYWGW57M.js +605 -0
- package/dist/cli-bundle/chunks/update-many-DYWGW57M.js.map +1 -0
- package/dist/cli-bundle/chunks/upgrade-2U727SAM.js +269 -0
- package/dist/cli-bundle/chunks/upgrade-2U727SAM.js.map +7 -0
- package/dist/cli-bundle/chunks/upgrade-3W3RVSNM.js +266 -0
- package/dist/cli-bundle/chunks/upgrade-3W3RVSNM.js.map +1 -0
- package/dist/cli-bundle/chunks/validate-GZ24NYHO.js +1120 -0
- package/dist/cli-bundle/chunks/validate-GZ24NYHO.js.map +1 -0
- package/dist/cli-bundle/chunks/validate-ZFVWPEEN.js +1123 -0
- package/dist/cli-bundle/chunks/validate-ZFVWPEEN.js.map +7 -0
- package/dist/cli-bundle/main.js +615 -121
- package/dist/cli-bundle/main.js.map +4 -4
- package/dist/core/checkpoint/mutation-checkpoint.d.ts +44 -0
- package/dist/core/checkpoint/mutation-checkpoint.js +119 -0
- package/dist/core/checkpoint/mutation-checkpoint.js.map +1 -0
- package/dist/core/config/positional-value.js +4 -2
- package/dist/core/config/positional-value.js.map +1 -1
- package/dist/core/diagnostics/remediation.d.ts +73 -0
- package/dist/core/diagnostics/remediation.js +328 -0
- package/dist/core/diagnostics/remediation.js.map +1 -0
- package/dist/core/extensions/extension-hook-runtime.js +9 -2
- package/dist/core/extensions/extension-hook-runtime.js.map +1 -1
- package/dist/core/extensions/extension-types.d.ts +60 -4
- package/dist/core/extensions/extension-types.js +2 -2
- package/dist/core/extensions/extension-types.js.map +1 -1
- package/dist/core/extensions/index.d.ts +5 -1
- package/dist/core/extensions/index.js +61 -2
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/item-fields.d.ts +5 -1
- package/dist/core/extensions/item-fields.js +126 -4
- package/dist/core/extensions/item-fields.js.map +1 -1
- package/dist/core/extensions/loader.js +283 -8
- package/dist/core/extensions/loader.js.map +1 -1
- package/dist/core/item/item-format.d.ts +3 -2
- package/dist/core/item/item-format.js +15 -10
- package/dist/core/item/item-format.js.map +1 -1
- package/dist/core/item/item-type-definition.js +6 -2
- package/dist/core/item/item-type-definition.js.map +1 -1
- package/dist/core/item/status-filter.d.ts +29 -0
- package/dist/core/item/status-filter.js +97 -0
- package/dist/core/item/status-filter.js.map +1 -0
- package/dist/core/item/type-registry.d.ts +4 -0
- package/dist/core/item/type-registry.js +12 -2
- package/dist/core/item/type-registry.js.map +1 -1
- package/dist/core/output/output.js +17 -5
- package/dist/core/output/output.js.map +1 -1
- package/dist/core/schema/item-types-file.d.ts +15 -0
- package/dist/core/schema/item-types-file.js +27 -2
- package/dist/core/schema/item-types-file.js.map +1 -1
- package/dist/core/schema/runtime-field-filters.js +4 -3
- package/dist/core/schema/runtime-field-filters.js.map +1 -1
- package/dist/core/schema/runtime-field-values.d.ts +1 -1
- package/dist/core/schema/runtime-field-values.js +10 -4
- package/dist/core/schema/runtime-field-values.js.map +1 -1
- package/dist/core/schema/runtime-schema.js +75 -2
- package/dist/core/schema/runtime-schema.js.map +1 -1
- package/dist/core/schema/status-defs-file.d.ts +113 -0
- package/dist/core/schema/status-defs-file.js +260 -0
- package/dist/core/schema/status-defs-file.js.map +1 -0
- package/dist/core/schema/type-workflows.d.ts +64 -0
- package/dist/core/schema/type-workflows.js +98 -0
- package/dist/core/schema/type-workflows.js.map +1 -0
- package/dist/core/search/background-refresh.d.ts +53 -0
- package/dist/core/search/background-refresh.js +286 -0
- package/dist/core/search/background-refresh.js.map +1 -0
- package/dist/core/search/cache.d.ts +23 -2
- package/dist/core/search/cache.js +135 -30
- package/dist/core/search/cache.js.map +1 -1
- package/dist/core/search/http-client.d.ts +2 -2
- package/dist/core/search/http-client.js +2 -2
- package/dist/core/search/http-client.js.map +1 -1
- package/dist/core/search/vector-stores.d.ts +1 -0
- package/dist/core/search/vector-stores.js +69 -15
- package/dist/core/search/vector-stores.js.map +1 -1
- package/dist/core/search/vectorization-metadata.d.ts +13 -0
- package/dist/core/search/vectorization-metadata.js +65 -0
- package/dist/core/search/vectorization-metadata.js.map +1 -0
- package/dist/core/shared/constants.d.ts +2 -2
- package/dist/core/shared/constants.js +2 -3
- package/dist/core/shared/constants.js.map +1 -1
- package/dist/core/shared/serialization.d.ts +1 -0
- package/dist/core/shared/serialization.js +86 -2
- package/dist/core/shared/serialization.js.map +1 -1
- package/dist/core/store/front-matter-cache.js +14 -5
- package/dist/core/store/front-matter-cache.js.map +1 -1
- package/dist/core/store/item-format-migration.js +25 -15
- package/dist/core/store/item-format-migration.js.map +1 -1
- package/dist/core/store/item-store.d.ts +2 -0
- package/dist/core/store/item-store.js +61 -6
- package/dist/core/store/item-store.js.map +1 -1
- package/dist/core/store/settings-validator.js +22 -2
- package/dist/core/store/settings-validator.js.map +1 -1
- package/dist/core/store/settings.js +40 -5
- package/dist/core/store/settings.js.map +1 -1
- package/dist/core/telemetry/consent.js +3 -3
- package/dist/core/telemetry/consent.js.map +1 -1
- package/dist/core/telemetry/observability.js +4 -3
- package/dist/core/telemetry/observability.js.map +1 -1
- package/dist/core/telemetry/runtime.d.ts +10 -0
- package/dist/core/telemetry/runtime.js +86 -2
- package/dist/core/telemetry/runtime.js.map +1 -1
- package/dist/mcp/server.js +221 -12
- package/dist/mcp/server.js.map +1 -1
- package/dist/sdk/cli-contracts/commander-mutation-options.js +16 -2
- package/dist/sdk/cli-contracts/commander-mutation-options.js.map +1 -1
- package/dist/sdk/cli-contracts/commander-types.js +7 -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 +4 -2
- package/dist/sdk/cli-contracts/enum-contracts.js.map +1 -1
- package/dist/sdk/cli-contracts/tool-option-contracts.d.ts +1 -0
- package/dist/sdk/cli-contracts/tool-option-contracts.js +53 -3
- package/dist/sdk/cli-contracts/tool-option-contracts.js.map +1 -1
- package/dist/sdk/cli-contracts/tool-parameter-tables.js +37 -8
- package/dist/sdk/cli-contracts/tool-parameter-tables.js.map +1 -1
- package/dist/sdk/cli-contracts.d.ts +19 -1
- package/dist/sdk/cli-contracts.js +211 -18
- package/dist/sdk/cli-contracts.js.map +1 -1
- package/dist/sdk/errors.d.ts +22 -0
- package/dist/sdk/errors.js +46 -0
- package/dist/sdk/errors.js.map +1 -0
- package/dist/sdk/index.d.ts +2 -1
- package/dist/sdk/index.js +3 -2
- package/dist/sdk/index.js.map +1 -1
- package/dist/sdk/package-import-adapters.js +14 -3
- package/dist/sdk/package-import-adapters.js.map +1 -1
- package/dist/sdk/runtime.d.ts +1 -0
- package/dist/sdk/runtime.js +3 -2
- package/dist/sdk/runtime.js.map +1 -1
- package/dist/sdk/testing.d.ts +77 -0
- package/dist/sdk/testing.js +239 -0
- package/dist/sdk/testing.js.map +1 -0
- package/dist/types.d.ts +26 -1
- package/dist/types.js +3 -2
- package/dist/types.js.map +1 -1
- package/docs/AGENT_GUIDE.md +21 -2
- package/docs/COMMANDS.md +85 -5
- package/docs/CONFIGURATION.md +49 -2
- package/docs/EXTENSIONS.md +118 -6
- package/docs/QUICKSTART.md +2 -0
- package/docs/RELEASING.md +3 -3
- package/docs/SDK.md +273 -1
- package/docs/TESTING.md +17 -0
- package/docs/examples/policy-restricted-extension/manifest.json +1 -0
- package/docs/examples/starter-extension/index.js +9 -1
- package/docs/examples/starter-extension/manifest.json +1 -0
- package/package.json +12 -7
- package/packages/pm-beads/extensions/beads/index.js +2 -4
- package/packages/pm-beads/extensions/beads/index.ts +43 -33
- package/packages/pm-beads/extensions/beads/manifest.json +12 -1
- package/packages/pm-calendar/README.md +6 -0
- package/packages/pm-calendar/extensions/calendar/index.js +6 -1
- package/packages/pm-calendar/extensions/calendar/index.ts +6 -1
- package/packages/pm-calendar/extensions/calendar/manifest.json +6 -1
- package/packages/pm-governance-audit/extensions/governance-audit/manifest.json +6 -1
- package/packages/pm-guide-shell/README.md +4 -0
- package/packages/pm-guide-shell/extensions/guide-shell/index.js +22 -0
- package/packages/pm-guide-shell/extensions/guide-shell/index.ts +22 -0
- package/packages/pm-guide-shell/extensions/guide-shell/manifest.json +6 -1
- package/packages/pm-guide-shell/extensions/guide-shell/runtime.js +74 -3
- package/packages/pm-guide-shell/extensions/guide-shell/runtime.ts +84 -4
- package/packages/pm-lifecycle-hooks/README.md +29 -0
- package/packages/pm-lifecycle-hooks/extensions/lifecycle-hooks/index.js +18 -0
- package/packages/pm-lifecycle-hooks/extensions/lifecycle-hooks/index.ts +20 -0
- package/packages/pm-lifecycle-hooks/extensions/lifecycle-hooks/manifest.json +9 -0
- package/packages/pm-lifecycle-hooks/package.json +52 -0
- package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/manifest.json +13 -1
- package/packages/pm-search-advanced/extensions/search-advanced/index.js +69 -1
- package/packages/pm-search-advanced/extensions/search-advanced/index.ts +91 -2
- package/packages/pm-search-advanced/extensions/search-advanced/manifest.json +13 -1
- package/packages/pm-templates/extensions/templates/manifest.json +6 -1
- package/packages/pm-todos/extensions/todos/index.js +3 -7
- package/packages/pm-todos/extensions/todos/index.ts +55 -42
- package/packages/pm-todos/extensions/todos/manifest.json +13 -1
- package/scripts/bundle-cli.mjs +121 -17
- package/dist/cli-bundle/chunks/chunk-PB2YU2E3.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-RJONRNXN.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-SW5BMMCU.js +0 -13864
- package/dist/cli-bundle/chunks/chunk-SW5BMMCU.js.map +0 -7
- package/dist/cli-bundle/chunks/commands-XJ4TJ5UN.js +0 -24225
- package/dist/cli-bundle/chunks/commands-XJ4TJ5UN.js.map +0 -7
- package/dist/cli-bundle/chunks/register-list-query-EIVQ5FMR.js.map +0 -7
- package/dist/cli-bundle/chunks/register-mutation-RSZNPSGI.js.map +0 -7
- package/dist/cli-bundle/chunks/register-operations-APUSYDMR.js.map +0 -7
- package/dist/cli-bundle/chunks/register-setup-OZOKSMPJ.js.map +0 -7
|
@@ -1,5 +1,5 @@
|
|
|
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]="1a1d092a-4cf8-54c6-aa4c-6a0b22690558")}catch(e){}}();
|
|
3
3
|
import { EXIT_CODE, SETTINGS_DEFAULTS } from "../../core/shared/constants.js";
|
|
4
4
|
import { PmCliError } from "../../core/shared/errors.js";
|
|
5
5
|
import { activateExtensions, getActiveExtensionRegistrations, loadExtensions, } from "../../core/extensions/index.js";
|
|
@@ -8,7 +8,7 @@ import { commandOptionFlagLabel, resolveCommandOptionPolicyState, resolveItemTyp
|
|
|
8
8
|
import { resolveRuntimeFieldRegistry, resolveRuntimeStatusRegistry, } from "../../core/schema/runtime-schema.js";
|
|
9
9
|
import { getSettingsPath, resolvePmRoot } from "../../core/store/paths.js";
|
|
10
10
|
import { readSettings } from "../../core/store/settings.js";
|
|
11
|
-
import { ACTIVITY_COMMANDER_STRING_OPTION_CONTRACTS, ACTIVITY_FLAG_CONTRACTS, AGGREGATE_FLAG_CONTRACTS, APPEND_FLAG_CONTRACTS, CALENDAR_COMMANDER_STRING_OPTION_CONTRACTS, CALENDAR_FLAG_CONTRACTS, CLAIM_FLAG_CONTRACTS, CLOSE_TASK_FLAG_CONTRACTS, COMMENTS_FLAG_CONTRACTS, COMMENTS_AUDIT_FLAG_CONTRACTS, CLOSE_FLAG_CONTRACTS, COMPLETION_FLAG_CONTRACTS, CONFIG_FLAG_CONTRACTS, CONTRACTS_FLAG_CONTRACTS, CONTEXT_COMMANDER_STRING_OPTION_CONTRACTS, CONTEXT_FLAG_CONTRACTS, CREATE_COMMANDER_REPEATABLE_OPTION_CONTRACTS, CREATE_COMMANDER_STRING_OPTION_CONTRACTS, CREATE_FLAG_CONTRACTS, DELETE_FLAG_CONTRACTS, DEPS_FLAG_CONTRACTS, DEDUPE_AUDIT_FLAG_CONTRACTS, DOCS_FLAG_CONTRACTS, EXTENSION_FLAG_CONTRACTS, FILES_FLAG_CONTRACTS, GC_FLAG_CONTRACTS, GET_FLAG_CONTRACTS, GUIDE_FLAG_CONTRACTS, GLOBAL_FLAG_CONTRACTS, HEALTH_FLAG_CONTRACTS, HISTORY_FLAG_CONTRACTS, HISTORY_REDACT_FLAG_CONTRACTS, HISTORY_REPAIR_FLAG_CONTRACTS, INSTALL_FLAG_CONTRACTS, INIT_FLAG_CONTRACTS, LEARNINGS_FLAG_CONTRACTS, LIST_COMMANDER_STRING_OPTION_CONTRACTS, LIST_FILTER_FLAG_CONTRACTS, NORMALIZE_FLAG_CONTRACTS, NOTES_FLAG_CONTRACTS, PM_EXTENSION_CAPABILITY_CONTRACTS, PM_EXTENSION_POLICY_MODE_CONTRACTS, PM_EXTENSION_POLICY_SURFACE_CONTRACTS, PM_EXTENSION_SANDBOX_PROFILE_CONTRACTS, PM_EXTENSION_SERVICE_NAME_CONTRACTS, PM_EXTENSION_TRUST_MODE_CONTRACTS, PLAN_FLAG_CONTRACTS, PM_CORE_COMMAND_NAMES, PM_TOOL_ACTIONS, PM_TOOL_PARAMETERS_SCHEMA, REINDEX_FLAG_CONTRACTS, RELEASE_FLAG_CONTRACTS, RESTORE_FLAG_CONTRACTS, SCHEMA_FLAG_CONTRACTS, SEARCH_COMMANDER_STRING_OPTION_CONTRACTS, SEARCH_FLAG_CONTRACTS, START_TASK_FLAG_CONTRACTS, PAUSE_TASK_FLAG_CONTRACTS, TEST_ALL_FLAG_CONTRACTS, TEST_FLAG_CONTRACTS, TEST_RUNS_FLAG_CONTRACTS, UPDATE_COMMANDER_REPEATABLE_OPTION_CONTRACTS, UPDATE_COMMANDER_STRING_OPTION_CONTRACTS, UPDATE_FLAG_CONTRACTS, UPDATE_MANY_FLAG_CONTRACTS, UPGRADE_FLAG_CONTRACTS, VALIDATE_FLAG_CONTRACTS, compactFlagAliasContracts, } from "../../sdk/cli-contracts.js";
|
|
11
|
+
import { ACTIVITY_COMMANDER_STRING_OPTION_CONTRACTS, ACTIVITY_FLAG_CONTRACTS, AGGREGATE_FLAG_CONTRACTS, APPEND_FLAG_CONTRACTS, CALENDAR_COMMANDER_STRING_OPTION_CONTRACTS, CALENDAR_FLAG_CONTRACTS, CLAIM_FLAG_CONTRACTS, CLOSE_TASK_FLAG_CONTRACTS, COMMENTS_FLAG_CONTRACTS, COMMENTS_AUDIT_FLAG_CONTRACTS, CLOSE_FLAG_CONTRACTS, CLOSE_MANY_FLAG_CONTRACTS, COMPLETION_FLAG_CONTRACTS, CONFIG_FLAG_CONTRACTS, CONTRACTS_FLAG_CONTRACTS, CONTEXT_COMMANDER_STRING_OPTION_CONTRACTS, CONTEXT_FLAG_CONTRACTS, CREATE_COMMANDER_REPEATABLE_OPTION_CONTRACTS, CREATE_COMMANDER_STRING_OPTION_CONTRACTS, CREATE_FLAG_CONTRACTS, DELETE_FLAG_CONTRACTS, DEPS_FLAG_CONTRACTS, DEDUPE_AUDIT_FLAG_CONTRACTS, DOCS_FLAG_CONTRACTS, EXTENSION_ACTIVATE_FLAG_CONTRACTS, EXTENSION_ADOPT_ALL_FLAG_CONTRACTS, EXTENSION_ADOPT_FLAG_CONTRACTS, EXTENSION_CATALOG_FLAG_CONTRACTS, EXTENSION_DEACTIVATE_FLAG_CONTRACTS, EXTENSION_DOCTOR_FLAG_CONTRACTS, EXTENSION_EXPLORE_FLAG_CONTRACTS, EXTENSION_FLAG_CONTRACTS, EXTENSION_INIT_FLAG_CONTRACTS, EXTENSION_INSTALL_FLAG_CONTRACTS, EXTENSION_MANAGE_FLAG_CONTRACTS, EXTENSION_RELOAD_FLAG_CONTRACTS, EXTENSION_UNINSTALL_FLAG_CONTRACTS, FILES_FLAG_CONTRACTS, GC_FLAG_CONTRACTS, GET_FLAG_CONTRACTS, GUIDE_FLAG_CONTRACTS, GLOBAL_FLAG_CONTRACTS, HEALTH_FLAG_CONTRACTS, HISTORY_FLAG_CONTRACTS, HISTORY_REDACT_FLAG_CONTRACTS, HISTORY_REPAIR_FLAG_CONTRACTS, INSTALL_FLAG_CONTRACTS, INIT_FLAG_CONTRACTS, LEARNINGS_FLAG_CONTRACTS, LIST_COMMANDER_STRING_OPTION_CONTRACTS, LIST_FILTER_FLAG_CONTRACTS, NORMALIZE_FLAG_CONTRACTS, NOTES_FLAG_CONTRACTS, PM_EXTENSION_CAPABILITY_CONTRACTS, PM_EXTENSION_POLICY_MODE_CONTRACTS, PM_EXTENSION_POLICY_SURFACE_CONTRACTS, PM_EXTENSION_SANDBOX_PROFILE_CONTRACTS, PM_EXTENSION_SERVICE_NAME_CONTRACTS, PM_EXTENSION_TRUST_MODE_CONTRACTS, PLAN_FLAG_CONTRACTS, PM_CORE_COMMAND_NAMES, PM_TOOL_ACTIONS, PM_TOOL_PARAMETERS_SCHEMA, REINDEX_FLAG_CONTRACTS, RELEASE_FLAG_CONTRACTS, RESTORE_FLAG_CONTRACTS, SCHEMA_FLAG_CONTRACTS, SEARCH_COMMANDER_STRING_OPTION_CONTRACTS, SEARCH_FLAG_CONTRACTS, START_TASK_FLAG_CONTRACTS, PAUSE_TASK_FLAG_CONTRACTS, TEST_ALL_FLAG_CONTRACTS, TEST_FLAG_CONTRACTS, TEST_RUNS_FLAG_CONTRACTS, UPDATE_COMMANDER_REPEATABLE_OPTION_CONTRACTS, UPDATE_COMMANDER_STRING_OPTION_CONTRACTS, UPDATE_FLAG_CONTRACTS, UPDATE_MANY_FLAG_CONTRACTS, UPGRADE_FLAG_CONTRACTS, VALIDATE_FLAG_CONTRACTS, compactFlagAliasContracts, } from "../../sdk/cli-contracts.js";
|
|
12
12
|
const LIST_COMMAND_NAMES = new Set([
|
|
13
13
|
"list",
|
|
14
14
|
"list-all",
|
|
@@ -41,7 +41,9 @@ const PACKAGE_OWNED_COMMANDS = new Set([
|
|
|
41
41
|
"calendar",
|
|
42
42
|
"comments-audit",
|
|
43
43
|
"completion",
|
|
44
|
+
"completion-statuses",
|
|
44
45
|
"completion-tags",
|
|
46
|
+
"completion-types",
|
|
45
47
|
"dedupe-audit",
|
|
46
48
|
"guide",
|
|
47
49
|
"normalize",
|
|
@@ -62,7 +64,9 @@ const PACKAGE_OWNED_COMMAND_INSTALL_HINTS = new Map([
|
|
|
62
64
|
["calendar", "calendar"],
|
|
63
65
|
["comments-audit", "governance-audit"],
|
|
64
66
|
["completion", "guide-shell"],
|
|
67
|
+
["completion-statuses", "guide-shell"],
|
|
65
68
|
["completion-tags", "guide-shell"],
|
|
69
|
+
["completion-types", "guide-shell"],
|
|
66
70
|
["dedupe-audit", "governance-audit"],
|
|
67
71
|
["guide", "guide-shell"],
|
|
68
72
|
["normalize", "governance-audit"],
|
|
@@ -78,6 +82,24 @@ const PACKAGE_OWNED_COMMAND_INSTALL_HINTS = new Map([
|
|
|
78
82
|
["test-runs stop", "linked-test-adapters"],
|
|
79
83
|
["test-runs resume", "linked-test-adapters"],
|
|
80
84
|
]);
|
|
85
|
+
const PACKAGE_OWNED_ACTION_COMMAND_PATHS = new Map([
|
|
86
|
+
["calendar", "calendar|cal"],
|
|
87
|
+
["dedupe-audit", "dedupe-audit"],
|
|
88
|
+
["guide", "guide"],
|
|
89
|
+
["reindex", "reindex"],
|
|
90
|
+
["normalize", "normalize"],
|
|
91
|
+
["comments-audit", "comments-audit"],
|
|
92
|
+
["completion", "completion"],
|
|
93
|
+
["test-runs-list", "test-runs|test-runs list"],
|
|
94
|
+
["test-runs-status", "test-runs status"],
|
|
95
|
+
["test-runs-logs", "test-runs logs"],
|
|
96
|
+
["test-runs-stop", "test-runs stop"],
|
|
97
|
+
["test-runs-resume", "test-runs resume"],
|
|
98
|
+
["templates-list", "templates|templates list"],
|
|
99
|
+
["templates-save", "templates save"],
|
|
100
|
+
["templates-show", "templates show"],
|
|
101
|
+
]);
|
|
102
|
+
const PACKAGE_OWNED_COMMAND_ACTIONS = new Map([...PACKAGE_OWNED_ACTION_COMMAND_PATHS.entries()].flatMap(([action, commandPaths]) => splitCommandPathAliases(commandPaths).map((commandPath) => [commandPath, action])));
|
|
81
103
|
const CANONICAL_COMMAND_ALIASES = [
|
|
82
104
|
{
|
|
83
105
|
canonical: "context",
|
|
@@ -89,6 +111,94 @@ const CANONICAL_COMMAND_ALIASES = [
|
|
|
89
111
|
},
|
|
90
112
|
];
|
|
91
113
|
const COMMAND_ALIAS_TO_CANONICAL = new Map(CANONICAL_COMMAND_ALIASES.flatMap((entry) => entry.aliases.map((alias) => [alias, entry.canonical])));
|
|
114
|
+
const EXTENSION_PACKAGE_LIFECYCLE_FLAG_CONTRACTS = [
|
|
115
|
+
["init", EXTENSION_INIT_FLAG_CONTRACTS],
|
|
116
|
+
["install", EXTENSION_INSTALL_FLAG_CONTRACTS],
|
|
117
|
+
["uninstall", EXTENSION_UNINSTALL_FLAG_CONTRACTS],
|
|
118
|
+
["explore", EXTENSION_EXPLORE_FLAG_CONTRACTS],
|
|
119
|
+
["manage", EXTENSION_MANAGE_FLAG_CONTRACTS],
|
|
120
|
+
["reload", EXTENSION_RELOAD_FLAG_CONTRACTS],
|
|
121
|
+
["doctor", EXTENSION_DOCTOR_FLAG_CONTRACTS],
|
|
122
|
+
["catalog", EXTENSION_CATALOG_FLAG_CONTRACTS],
|
|
123
|
+
["adopt", EXTENSION_ADOPT_FLAG_CONTRACTS],
|
|
124
|
+
["adopt-all", EXTENSION_ADOPT_ALL_FLAG_CONTRACTS],
|
|
125
|
+
["activate", EXTENSION_ACTIVATE_FLAG_CONTRACTS],
|
|
126
|
+
["deactivate", EXTENSION_DEACTIVATE_FLAG_CONTRACTS],
|
|
127
|
+
];
|
|
128
|
+
const CORE_COMMAND_FLAG_CONTRACT_ENTRIES = [
|
|
129
|
+
...EXTENSION_PACKAGE_LIFECYCLE_FLAG_CONTRACTS.flatMap(([subcommand, flags]) => [
|
|
130
|
+
[`extension ${subcommand}`, flags],
|
|
131
|
+
[`package ${subcommand}`, flags],
|
|
132
|
+
[`packages ${subcommand}`, flags],
|
|
133
|
+
]),
|
|
134
|
+
["init", INIT_FLAG_CONTRACTS],
|
|
135
|
+
["config", CONFIG_FLAG_CONTRACTS],
|
|
136
|
+
["extension", EXTENSION_FLAG_CONTRACTS],
|
|
137
|
+
["package", EXTENSION_FLAG_CONTRACTS],
|
|
138
|
+
["packages", EXTENSION_FLAG_CONTRACTS],
|
|
139
|
+
["install", INSTALL_FLAG_CONTRACTS],
|
|
140
|
+
["create", CREATE_FLAG_CONTRACTS],
|
|
141
|
+
["update", UPDATE_FLAG_CONTRACTS],
|
|
142
|
+
["update-many", UPDATE_MANY_FLAG_CONTRACTS],
|
|
143
|
+
["upgrade", UPGRADE_FLAG_CONTRACTS],
|
|
144
|
+
["normalize", NORMALIZE_FLAG_CONTRACTS],
|
|
145
|
+
["calendar", CALENDAR_FLAG_CONTRACTS],
|
|
146
|
+
["cal", CALENDAR_FLAG_CONTRACTS],
|
|
147
|
+
["context", CONTEXT_FLAG_CONTRACTS],
|
|
148
|
+
["ctx", CONTEXT_FLAG_CONTRACTS],
|
|
149
|
+
["get", GET_FLAG_CONTRACTS],
|
|
150
|
+
["search", SEARCH_FLAG_CONTRACTS],
|
|
151
|
+
["aggregate", AGGREGATE_FLAG_CONTRACTS],
|
|
152
|
+
["dedupe-audit", DEDUPE_AUDIT_FLAG_CONTRACTS],
|
|
153
|
+
["deps", DEPS_FLAG_CONTRACTS],
|
|
154
|
+
["guide", GUIDE_FLAG_CONTRACTS],
|
|
155
|
+
["reindex", REINDEX_FLAG_CONTRACTS],
|
|
156
|
+
["history", HISTORY_FLAG_CONTRACTS],
|
|
157
|
+
["history-redact", HISTORY_REDACT_FLAG_CONTRACTS],
|
|
158
|
+
["history-repair", HISTORY_REPAIR_FLAG_CONTRACTS],
|
|
159
|
+
["schema", SCHEMA_FLAG_CONTRACTS],
|
|
160
|
+
["plan", PLAN_FLAG_CONTRACTS],
|
|
161
|
+
["restore", RESTORE_FLAG_CONTRACTS],
|
|
162
|
+
["delete", DELETE_FLAG_CONTRACTS],
|
|
163
|
+
["close", CLOSE_FLAG_CONTRACTS],
|
|
164
|
+
["close-many", CLOSE_MANY_FLAG_CONTRACTS],
|
|
165
|
+
["append", APPEND_FLAG_CONTRACTS],
|
|
166
|
+
["claim", CLAIM_FLAG_CONTRACTS],
|
|
167
|
+
["release", RELEASE_FLAG_CONTRACTS],
|
|
168
|
+
["start-task", START_TASK_FLAG_CONTRACTS],
|
|
169
|
+
["pause-task", PAUSE_TASK_FLAG_CONTRACTS],
|
|
170
|
+
["close-task", CLOSE_TASK_FLAG_CONTRACTS],
|
|
171
|
+
["comments", COMMENTS_FLAG_CONTRACTS],
|
|
172
|
+
["notes", NOTES_FLAG_CONTRACTS],
|
|
173
|
+
["learnings", LEARNINGS_FLAG_CONTRACTS],
|
|
174
|
+
["files", FILES_FLAG_CONTRACTS],
|
|
175
|
+
["docs", DOCS_FLAG_CONTRACTS],
|
|
176
|
+
["test", TEST_FLAG_CONTRACTS],
|
|
177
|
+
["test-all", TEST_ALL_FLAG_CONTRACTS],
|
|
178
|
+
["test-runs", TEST_RUNS_FLAG_CONTRACTS],
|
|
179
|
+
["gc", GC_FLAG_CONTRACTS],
|
|
180
|
+
["validate", VALIDATE_FLAG_CONTRACTS],
|
|
181
|
+
["comments-audit", COMMENTS_AUDIT_FLAG_CONTRACTS],
|
|
182
|
+
["health", HEALTH_FLAG_CONTRACTS],
|
|
183
|
+
["contracts", CONTRACTS_FLAG_CONTRACTS],
|
|
184
|
+
["completion", COMPLETION_FLAG_CONTRACTS],
|
|
185
|
+
["activity", ACTIVITY_FLAG_CONTRACTS],
|
|
186
|
+
...[...LIST_COMMAND_NAMES].map((command) => [command, LIST_FILTER_FLAG_CONTRACTS]),
|
|
187
|
+
];
|
|
188
|
+
const CORE_COMMAND_FLAG_CONTRACTS_BY_COMMAND = new Map(CORE_COMMAND_FLAG_CONTRACT_ENTRIES);
|
|
189
|
+
function packageOwnedActionForCommand(command) {
|
|
190
|
+
const exactAction = PACKAGE_OWNED_COMMAND_ACTIONS.get(command);
|
|
191
|
+
if (exactAction) {
|
|
192
|
+
return exactAction;
|
|
193
|
+
}
|
|
194
|
+
if (command.startsWith("test-runs ")) {
|
|
195
|
+
return `test-runs-${command.slice("test-runs ".length)}`;
|
|
196
|
+
}
|
|
197
|
+
if (command.startsWith("templates ")) {
|
|
198
|
+
return `templates-${command.slice("templates ".length)}`;
|
|
199
|
+
}
|
|
200
|
+
return command;
|
|
201
|
+
}
|
|
92
202
|
function resolveActionCommandPath(action) {
|
|
93
203
|
if (PM_CORE_COMMAND_NAMES.includes(action)) {
|
|
94
204
|
return normalizeCommandPath(action);
|
|
@@ -105,6 +215,9 @@ function resolveActionCommandPath(action) {
|
|
|
105
215
|
if (action.startsWith("templates-")) {
|
|
106
216
|
return normalizeCommandPath(`templates ${action.slice("templates-".length)}`);
|
|
107
217
|
}
|
|
218
|
+
if (PACKAGE_OWNED_ACTIONS.has(action)) {
|
|
219
|
+
return PACKAGE_OWNED_ACTION_COMMAND_PATHS.get(action) ?? normalizeCommandPath(action);
|
|
220
|
+
}
|
|
108
221
|
return null;
|
|
109
222
|
}
|
|
110
223
|
function actionDescriptorMatchesSelectedCommand(descriptor, selectedCommand) {
|
|
@@ -585,20 +698,34 @@ async function resolveRuntimeExtensionActionProbe(global) {
|
|
|
585
698
|
};
|
|
586
699
|
}
|
|
587
700
|
}
|
|
588
|
-
function collectActionContractDescriptors(extensionContracts) {
|
|
701
|
+
function collectActionContractDescriptors(extensionContracts, options = {}) {
|
|
589
702
|
const descriptors = new Map();
|
|
590
703
|
for (const action of PM_TOOL_ACTIONS) {
|
|
591
|
-
|
|
704
|
+
const packageOwned = PACKAGE_OWNED_ACTIONS.has(action);
|
|
705
|
+
if (packageOwned && !options.includePackageOwnedActions) {
|
|
592
706
|
continue;
|
|
593
707
|
}
|
|
594
708
|
const commandPath = resolveActionCommandPath(action);
|
|
595
709
|
descriptors.set(action, {
|
|
596
710
|
action,
|
|
597
|
-
provider: "core",
|
|
598
|
-
requires_extension:
|
|
711
|
+
provider: packageOwned ? "extension" : "core",
|
|
712
|
+
requires_extension: packageOwned,
|
|
599
713
|
command_path: commandPath,
|
|
600
714
|
});
|
|
601
715
|
}
|
|
716
|
+
if (options.includePackageOwnedActions) {
|
|
717
|
+
for (const action of PACKAGE_OWNED_ACTIONS) {
|
|
718
|
+
if (descriptors.has(action)) {
|
|
719
|
+
continue;
|
|
720
|
+
}
|
|
721
|
+
descriptors.set(action, {
|
|
722
|
+
action,
|
|
723
|
+
provider: "extension",
|
|
724
|
+
requires_extension: true,
|
|
725
|
+
command_path: resolveActionCommandPath(action),
|
|
726
|
+
});
|
|
727
|
+
}
|
|
728
|
+
}
|
|
602
729
|
for (const contract of extensionContracts) {
|
|
603
730
|
if (descriptors.has(contract.action)) {
|
|
604
731
|
continue;
|
|
@@ -629,6 +756,9 @@ function resolveActionAvailability(descriptor, runtimeProbe) {
|
|
|
629
756
|
? splitCommandPathAliases(descriptor.command_path)
|
|
630
757
|
: [];
|
|
631
758
|
const extensionCommandAvailable = commandPaths.some((commandPath) => runtimeProbe.handlers.has(commandPath));
|
|
759
|
+
const optionalPackageHint = commandPaths
|
|
760
|
+
.map((commandPath) => PACKAGE_OWNED_COMMAND_INSTALL_HINTS.get(commandPath))
|
|
761
|
+
.find((hint) => typeof hint === "string");
|
|
632
762
|
const invocable = runtimeProbe.disabledReason === null && extensionCommandAvailable;
|
|
633
763
|
return {
|
|
634
764
|
action: descriptor.action,
|
|
@@ -638,7 +768,7 @@ function resolveActionAvailability(descriptor, runtimeProbe) {
|
|
|
638
768
|
provider: "extension",
|
|
639
769
|
disabled_reason: invocable
|
|
640
770
|
? null
|
|
641
|
-
: (runtimeProbe.disabledReason ?? "extension_command_not_registered"),
|
|
771
|
+
: (runtimeProbe.disabledReason ?? (optionalPackageHint ? `optional_package_not_installed:${optionalPackageHint}` : "extension_command_not_registered")),
|
|
642
772
|
command_path: descriptor.command_path,
|
|
643
773
|
cli_exposed: extensionCommandAvailable,
|
|
644
774
|
policy_state: {
|
|
@@ -649,153 +779,13 @@ function resolveActionAvailability(descriptor, runtimeProbe) {
|
|
|
649
779
|
};
|
|
650
780
|
}
|
|
651
781
|
function resolveCoreCommandFlags(command) {
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
if (command
|
|
656
|
-
return
|
|
657
|
-
}
|
|
658
|
-
if (command === "extension" ||
|
|
659
|
-
command === "package" ||
|
|
660
|
-
command === "packages") {
|
|
661
|
-
return EXTENSION_FLAG_CONTRACTS;
|
|
662
|
-
}
|
|
663
|
-
if (command === "install") {
|
|
664
|
-
return INSTALL_FLAG_CONTRACTS;
|
|
665
|
-
}
|
|
666
|
-
if (command === "create") {
|
|
667
|
-
return CREATE_FLAG_CONTRACTS;
|
|
668
|
-
}
|
|
669
|
-
if (command === "update") {
|
|
670
|
-
return UPDATE_FLAG_CONTRACTS;
|
|
671
|
-
}
|
|
672
|
-
if (command === "update-many") {
|
|
673
|
-
return UPDATE_MANY_FLAG_CONTRACTS;
|
|
674
|
-
}
|
|
675
|
-
if (command === "upgrade") {
|
|
676
|
-
return UPGRADE_FLAG_CONTRACTS;
|
|
677
|
-
}
|
|
678
|
-
if (command === "normalize") {
|
|
679
|
-
return NORMALIZE_FLAG_CONTRACTS;
|
|
680
|
-
}
|
|
681
|
-
if (command === "calendar" || command === "cal") {
|
|
682
|
-
return CALENDAR_FLAG_CONTRACTS;
|
|
683
|
-
}
|
|
684
|
-
if (command === "context" || command === "ctx") {
|
|
685
|
-
return CONTEXT_FLAG_CONTRACTS;
|
|
686
|
-
}
|
|
687
|
-
if (command === "get") {
|
|
688
|
-
return GET_FLAG_CONTRACTS;
|
|
689
|
-
}
|
|
690
|
-
if (command === "search") {
|
|
691
|
-
return SEARCH_FLAG_CONTRACTS;
|
|
692
|
-
}
|
|
693
|
-
if (command === "aggregate") {
|
|
694
|
-
return AGGREGATE_FLAG_CONTRACTS;
|
|
695
|
-
}
|
|
696
|
-
if (command === "dedupe-audit") {
|
|
697
|
-
return DEDUPE_AUDIT_FLAG_CONTRACTS;
|
|
698
|
-
}
|
|
699
|
-
if (command === "deps") {
|
|
700
|
-
return DEPS_FLAG_CONTRACTS;
|
|
701
|
-
}
|
|
702
|
-
if (command === "guide") {
|
|
703
|
-
return GUIDE_FLAG_CONTRACTS;
|
|
704
|
-
}
|
|
705
|
-
if (command === "reindex") {
|
|
706
|
-
return REINDEX_FLAG_CONTRACTS;
|
|
707
|
-
}
|
|
708
|
-
if (command === "history") {
|
|
709
|
-
return HISTORY_FLAG_CONTRACTS;
|
|
710
|
-
}
|
|
711
|
-
if (command === "history-redact") {
|
|
712
|
-
return HISTORY_REDACT_FLAG_CONTRACTS;
|
|
713
|
-
}
|
|
714
|
-
if (command === "history-repair") {
|
|
715
|
-
return HISTORY_REPAIR_FLAG_CONTRACTS;
|
|
716
|
-
}
|
|
717
|
-
if (command === "schema") {
|
|
718
|
-
return SCHEMA_FLAG_CONTRACTS;
|
|
719
|
-
}
|
|
720
|
-
if (command === "plan") {
|
|
721
|
-
return PLAN_FLAG_CONTRACTS;
|
|
722
|
-
}
|
|
723
|
-
if (command === "restore") {
|
|
724
|
-
return RESTORE_FLAG_CONTRACTS;
|
|
725
|
-
}
|
|
726
|
-
if (command === "delete") {
|
|
727
|
-
return DELETE_FLAG_CONTRACTS;
|
|
728
|
-
}
|
|
729
|
-
if (command === "close") {
|
|
730
|
-
return CLOSE_FLAG_CONTRACTS;
|
|
731
|
-
}
|
|
732
|
-
if (command === "append") {
|
|
733
|
-
return APPEND_FLAG_CONTRACTS;
|
|
734
|
-
}
|
|
735
|
-
if (command === "claim") {
|
|
736
|
-
return CLAIM_FLAG_CONTRACTS;
|
|
737
|
-
}
|
|
738
|
-
if (command === "release") {
|
|
739
|
-
return RELEASE_FLAG_CONTRACTS;
|
|
740
|
-
}
|
|
741
|
-
if (command === "start-task") {
|
|
742
|
-
return START_TASK_FLAG_CONTRACTS;
|
|
743
|
-
}
|
|
744
|
-
if (command === "pause-task") {
|
|
745
|
-
return PAUSE_TASK_FLAG_CONTRACTS;
|
|
746
|
-
}
|
|
747
|
-
if (command === "close-task") {
|
|
748
|
-
return CLOSE_TASK_FLAG_CONTRACTS;
|
|
749
|
-
}
|
|
750
|
-
if (command === "comments") {
|
|
751
|
-
return COMMENTS_FLAG_CONTRACTS;
|
|
752
|
-
}
|
|
753
|
-
if (command === "notes") {
|
|
754
|
-
return NOTES_FLAG_CONTRACTS;
|
|
755
|
-
}
|
|
756
|
-
if (command === "learnings") {
|
|
757
|
-
return LEARNINGS_FLAG_CONTRACTS;
|
|
758
|
-
}
|
|
759
|
-
if (command === "files") {
|
|
760
|
-
return FILES_FLAG_CONTRACTS;
|
|
761
|
-
}
|
|
762
|
-
if (command === "docs") {
|
|
763
|
-
return DOCS_FLAG_CONTRACTS;
|
|
764
|
-
}
|
|
765
|
-
if (command === "test") {
|
|
766
|
-
return TEST_FLAG_CONTRACTS;
|
|
767
|
-
}
|
|
768
|
-
if (command === "test-all") {
|
|
769
|
-
return TEST_ALL_FLAG_CONTRACTS;
|
|
770
|
-
}
|
|
771
|
-
if (command === "test-runs") {
|
|
772
|
-
return TEST_RUNS_FLAG_CONTRACTS;
|
|
773
|
-
}
|
|
774
|
-
if (command === "gc") {
|
|
775
|
-
return GC_FLAG_CONTRACTS;
|
|
776
|
-
}
|
|
777
|
-
if (command === "validate") {
|
|
778
|
-
return VALIDATE_FLAG_CONTRACTS;
|
|
779
|
-
}
|
|
780
|
-
if (command === "comments-audit") {
|
|
781
|
-
return COMMENTS_AUDIT_FLAG_CONTRACTS;
|
|
782
|
-
}
|
|
783
|
-
if (command === "health") {
|
|
784
|
-
return HEALTH_FLAG_CONTRACTS;
|
|
785
|
-
}
|
|
786
|
-
if (command === "contracts") {
|
|
787
|
-
return CONTRACTS_FLAG_CONTRACTS;
|
|
788
|
-
}
|
|
789
|
-
if (command === "completion") {
|
|
790
|
-
return COMPLETION_FLAG_CONTRACTS;
|
|
791
|
-
}
|
|
792
|
-
if (command === "activity") {
|
|
793
|
-
return ACTIVITY_FLAG_CONTRACTS;
|
|
794
|
-
}
|
|
795
|
-
if (LIST_COMMAND_NAMES.has(command)) {
|
|
796
|
-
return LIST_FILTER_FLAG_CONTRACTS;
|
|
782
|
+
return CORE_COMMAND_FLAG_CONTRACTS_BY_COMMAND.get(command) ?? GLOBAL_FLAG_CONTRACTS;
|
|
783
|
+
}
|
|
784
|
+
function isCoreCommandPath(command) {
|
|
785
|
+
if (PACKAGE_OWNED_COMMANDS.has(command)) {
|
|
786
|
+
return false;
|
|
797
787
|
}
|
|
798
|
-
return
|
|
788
|
+
return CORE_COMMAND_FLAG_CONTRACTS_BY_COMMAND.has(command);
|
|
799
789
|
}
|
|
800
790
|
function normalizeCommandForRuntimeFieldFlags(command) {
|
|
801
791
|
if (LIST_COMMAND_NAMES.has(command)) {
|
|
@@ -808,7 +798,7 @@ function normalizeCommandForRuntimeFieldFlags(command) {
|
|
|
808
798
|
return "context";
|
|
809
799
|
}
|
|
810
800
|
if (command === "update-many") {
|
|
811
|
-
return "
|
|
801
|
+
return "update_many";
|
|
812
802
|
}
|
|
813
803
|
return command;
|
|
814
804
|
}
|
|
@@ -897,7 +887,7 @@ function mergeFlagContracts(primary, secondary) {
|
|
|
897
887
|
function buildCommandFlagSurface(commands, extensionFlagMap, runtimeFieldFlagMap) {
|
|
898
888
|
return commands
|
|
899
889
|
.map((command) => {
|
|
900
|
-
const isCoreCommand =
|
|
890
|
+
const isCoreCommand = isCoreCommandPath(command);
|
|
901
891
|
const coreFlags = isCoreCommand ? resolveCoreCommandFlags(command) : [];
|
|
902
892
|
const runtimeFlags = runtimeFieldFlagMap.get(normalizeCommandForRuntimeFieldFlags(command)) ?? [];
|
|
903
893
|
const extensionFlags = extensionFlagMap.get(command);
|
|
@@ -1068,7 +1058,20 @@ export async function runContracts(options, global) {
|
|
|
1068
1058
|
const extensionContracts = collectExtensionCommandContracts(runtimeProbe);
|
|
1069
1059
|
const mergedExtensionContracts = mergeExtensionContractsByAction(extensionContracts);
|
|
1070
1060
|
const extensionFlagMap = collectExtensionFlagContractsByCommand(runtimeProbe.flagRegistrations);
|
|
1071
|
-
const
|
|
1061
|
+
const includePackageOwnedActions = (selectedAction !== undefined && PACKAGE_OWNED_ACTIONS.has(selectedAction) && availabilityOnly) ||
|
|
1062
|
+
(selectedCommand !== undefined && PACKAGE_OWNED_COMMANDS.has(selectedCommand) && availabilityOnly);
|
|
1063
|
+
const actionDescriptors = collectActionContractDescriptors(mergedExtensionContracts, { includePackageOwnedActions });
|
|
1064
|
+
if (includePackageOwnedActions &&
|
|
1065
|
+
selectedCommand !== undefined &&
|
|
1066
|
+
PACKAGE_OWNED_COMMANDS.has(selectedCommand) &&
|
|
1067
|
+
!actionDescriptors.some((entry) => entry.command_path === selectedCommand)) {
|
|
1068
|
+
actionDescriptors.push({
|
|
1069
|
+
action: packageOwnedActionForCommand(selectedCommand),
|
|
1070
|
+
provider: "extension",
|
|
1071
|
+
requires_extension: true,
|
|
1072
|
+
command_path: selectedCommand,
|
|
1073
|
+
});
|
|
1074
|
+
}
|
|
1072
1075
|
const actionNames = new Set(actionDescriptors.map((entry) => entry.action));
|
|
1073
1076
|
if (selectedAction && !actionNames.has(selectedAction)) {
|
|
1074
1077
|
throw new PmCliError(`Unknown action: "${options.action}".`, EXIT_CODE.USAGE);
|
|
@@ -1076,6 +1079,8 @@ export async function runContracts(options, global) {
|
|
|
1076
1079
|
const commandCatalog = [
|
|
1077
1080
|
...new Set([
|
|
1078
1081
|
...PM_CORE_COMMAND_NAMES.filter((entry) => !PACKAGE_OWNED_COMMANDS.has(entry)),
|
|
1082
|
+
...[...CORE_COMMAND_FLAG_CONTRACTS_BY_COMMAND.keys()].filter((entry) => !PACKAGE_OWNED_COMMANDS.has(entry)),
|
|
1083
|
+
...actionDescriptors.flatMap((entry) => entry.command_path ? splitCommandPathAliases(entry.command_path) : []),
|
|
1079
1084
|
...mergedExtensionContracts.flatMap((entry) => entry.command.split("|")),
|
|
1080
1085
|
]),
|
|
1081
1086
|
]
|
|
@@ -1087,6 +1092,9 @@ export async function runContracts(options, global) {
|
|
|
1087
1092
|
const packageHint = PACKAGE_OWNED_COMMAND_INSTALL_HINTS.get(selectedCommand);
|
|
1088
1093
|
if (packageHint) {
|
|
1089
1094
|
throw new PmCliError(`Unknown command: "${options.command}". Command "${selectedCommand}" is provided by the optional "${packageHint}" package. Run "pm install ${packageHint} --project" and retry.`, EXIT_CODE.USAGE, {
|
|
1095
|
+
code: "unknown_command",
|
|
1096
|
+
required: `Install the optional "${packageHint}" package, or choose a command from pm contracts --flags-only --json.`,
|
|
1097
|
+
why: "Command contracts include core commands plus commands registered by active packages and extensions.",
|
|
1090
1098
|
examples: [`pm install ${packageHint} --project`, `pm contracts --command ${selectedCommand} --flags-only --json`],
|
|
1091
1099
|
nextSteps: [`Install the optional package first: pm install ${packageHint} --project`],
|
|
1092
1100
|
recovery: {
|
|
@@ -1094,10 +1102,24 @@ export async function runContracts(options, global) {
|
|
|
1094
1102
|
},
|
|
1095
1103
|
});
|
|
1096
1104
|
}
|
|
1097
|
-
throw new PmCliError(`Unknown command: "${options.command}".`, EXIT_CODE.USAGE
|
|
1105
|
+
throw new PmCliError(`Unknown command: "${options.command}".`, EXIT_CODE.USAGE, {
|
|
1106
|
+
code: "unknown_command",
|
|
1107
|
+
required: "Use a command path listed by pm contracts --flags-only --json.",
|
|
1108
|
+
why: "Command contracts are generated from the active core, package, and extension command registry.",
|
|
1109
|
+
examples: ["pm contracts --flags-only --json", "pm --help"],
|
|
1110
|
+
nextSteps: ["Verify spelling and active packages/extensions, then rerun with a known command path."],
|
|
1111
|
+
recovery: {
|
|
1112
|
+
suggested_retry: "pm contracts --flags-only --json",
|
|
1113
|
+
},
|
|
1114
|
+
});
|
|
1098
1115
|
}
|
|
1116
|
+
const selectedPackageOwnedAction = selectedCommand
|
|
1117
|
+
? PACKAGE_OWNED_COMMAND_ACTIONS.get(selectedCommand)
|
|
1118
|
+
: undefined;
|
|
1099
1119
|
const commandScopedDescriptors = selectedCommand
|
|
1100
|
-
? actionDescriptors.filter((descriptor) =>
|
|
1120
|
+
? actionDescriptors.filter((descriptor) => selectedPackageOwnedAction
|
|
1121
|
+
? descriptor.action === selectedPackageOwnedAction
|
|
1122
|
+
: actionDescriptorMatchesSelectedCommand(descriptor, selectedCommand))
|
|
1101
1123
|
: actionDescriptors;
|
|
1102
1124
|
if (selectedCommand &&
|
|
1103
1125
|
selectedAction &&
|
|
@@ -1132,11 +1154,18 @@ export async function runContracts(options, global) {
|
|
|
1132
1154
|
const scopedActionDescriptors = selectedAction
|
|
1133
1155
|
? commandScopedDescriptors.filter((descriptor) => descriptor.action === selectedAction)
|
|
1134
1156
|
: commandScopedDescriptors;
|
|
1135
|
-
const allActionAvailability =
|
|
1136
|
-
|
|
1157
|
+
const allActionAvailability = [
|
|
1158
|
+
...new Map(scopedActionDescriptors
|
|
1159
|
+
.map((descriptor) => resolveActionAvailability(descriptor, runtimeProbe))
|
|
1160
|
+
.map((entry) => [
|
|
1161
|
+
selectedPackageOwnedAction ? entry.action : `${entry.action}|${entry.command_path ?? ""}`,
|
|
1162
|
+
entry,
|
|
1163
|
+
])).values(),
|
|
1164
|
+
];
|
|
1165
|
+
const actionAvailability = runtimeOnly && !selectedAction && !availabilityOnly
|
|
1137
1166
|
? allActionAvailability.filter((entry) => entry.invocable)
|
|
1138
1167
|
: allActionAvailability;
|
|
1139
|
-
const actions = actionAvailability.map((entry) => entry.action);
|
|
1168
|
+
const actions = [...new Set(actionAvailability.map((entry) => entry.action))];
|
|
1140
1169
|
const descriptorActionSet = new Set(actionDescriptors.map((descriptor) => descriptor.action));
|
|
1141
1170
|
let filteredSchema = selectedAction
|
|
1142
1171
|
? filterSchemaByAction(mergedSchema, selectedAction)
|
|
@@ -1246,4 +1275,4 @@ export async function runContracts(options, global) {
|
|
|
1246
1275
|
return result;
|
|
1247
1276
|
}
|
|
1248
1277
|
//# sourceMappingURL=contracts.js.map
|
|
1249
|
-
//# debugId=
|
|
1278
|
+
//# debugId=1a1d092a-4cf8-54c6-aa4c-6a0b22690558
|