@unbrained/pm-cli 2026.7.15 → 2026.7.17
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/.claude-plugin/marketplace.json +2 -2
- package/CHANGELOG.md +23 -2
- package/CONTRIBUTING.md +2 -2
- package/dist/cli/bootstrap-args.d.ts +2 -115
- package/dist/cli/bootstrap-args.js +4 -831
- package/dist/cli/bootstrap-args.js.map +1 -1
- package/dist/cli/commands/eval.d.ts +4 -64
- package/dist/cli/commands/eval.js +4 -153
- package/dist/cli/commands/eval.js.map +1 -1
- package/dist/cli/commands/linked-test-entry.d.ts +6 -6
- package/dist/cli/commands/linked-test-entry.js +4 -65
- package/dist/cli/commands/linked-test-entry.js.map +1 -1
- package/dist/cli/commands/linked-test-parsers.d.ts +3 -45
- package/dist/cli/commands/linked-test-parsers.js +4 -516
- package/dist/cli/commands/linked-test-parsers.js.map +1 -1
- package/dist/cli/commands/list.d.ts +3 -210
- package/dist/cli/commands/list.js +4 -1068
- package/dist/cli/commands/list.js.map +1 -1
- package/dist/cli/commands/search.d.ts +3 -464
- package/dist/cli/commands/search.js +4 -2236
- package/dist/cli/commands/search.js.map +1 -1
- package/dist/cli/commands/stats.d.ts +6 -66
- package/dist/cli/commands/stats.js +4 -157
- package/dist/cli/commands/stats.js.map +1 -1
- package/dist/cli/commands/telemetry.d.ts +6 -14
- package/dist/cli/commands/telemetry.js +4 -349
- package/dist/cli/commands/telemetry.js.map +1 -1
- package/dist/cli/commands/test-all.d.ts +6 -95
- package/dist/cli/commands/test-all.js +4 -439
- package/dist/cli/commands/test-all.js.map +1 -1
- package/dist/cli/commands/test-runs.d.ts +6 -92
- package/dist/cli/commands/test-runs.js +4 -189
- package/dist/cli/commands/test-runs.js.map +1 -1
- package/dist/cli/commands/test.d.ts +6 -244
- package/dist/cli/commands/test.js +4 -1780
- package/dist/cli/commands/test.js.map +1 -1
- package/dist/cli/commands/update-many.d.ts +15 -29
- package/dist/cli/commands/update-many.js +355 -259
- package/dist/cli/commands/update-many.js.map +1 -1
- package/dist/cli/main.js +140 -133
- package/dist/cli/main.js.map +1 -1
- package/dist/cli/search-refresh.js +4 -9
- package/dist/cli/search-refresh.js.map +1 -1
- package/dist/cli/shared-parsers.d.ts +6 -9
- package/dist/cli/shared-parsers.js +4 -37
- package/dist/cli/shared-parsers.js.map +1 -1
- package/dist/cli/telemetry-flush.js +4 -4
- package/dist/cli/telemetry-flush.js.map +1 -1
- package/dist/cli-bundle/bundle-manifest.json +341 -341
- package/dist/cli-bundle/chunks/{append-OJQFUQ4T.js → append-5YF3TO7I.js} +5 -5
- package/dist/cli-bundle/chunks/append-JHO5K6RP.js +11 -0
- package/dist/cli-bundle/chunks/{chunk-WT3ZEOGH.js → chunk-23TCGBRK.js} +16 -7
- package/dist/cli-bundle/chunks/{chunk-WT3ZEOGH.js.map → chunk-23TCGBRK.js.map} +1 -1
- package/dist/cli-bundle/chunks/{chunk-BCOFWYW4.js → chunk-2BX74BAS.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-APRVSW2O.js → chunk-2CXL335K.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-KG44YSKD.js → chunk-2FUOXSRN.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-HDH3JUGG.js → chunk-2IPNL3DR.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-J6364LFM.js → chunk-2MPMKJF2.js} +9 -18
- package/dist/cli-bundle/chunks/{chunk-J6364LFM.js.map → chunk-2MPMKJF2.js.map} +1 -1
- package/dist/cli-bundle/chunks/{chunk-GM5QHQU6.js → chunk-2XOSFSTH.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-K3WII2ME.js → chunk-37DRDP2B.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-2WSE6PO2.js → chunk-37V5MXAU.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-UWQHLMEB.js → chunk-3D4YVTNG.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-PMOSXADO.js → chunk-47HXN6RX.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-6CFNAVTF.js → chunk-5HGZKQUL.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-2IFFUZLC.js → chunk-5UKQLQM2.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-DM4H7FP4.js → chunk-633PKXLT.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-XSJUSQAE.js → chunk-646MQXFW.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-ZI6VQWQ7.js → chunk-66MKH7SZ.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-S6MQESFR.js → chunk-67RO3H4N.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-34L5OT3Y.js → chunk-6DYOZS6C.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-RRM5JYJC.js → chunk-6O44IN44.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-ONG5V5CI.js → chunk-6XAZB6SE.js} +97 -69
- package/dist/cli-bundle/chunks/chunk-6XAZB6SE.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-PENXZX3U.js → chunk-74FKFFXO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-LPYWLWDS.js → chunk-7CTQ7WW5.js} +37 -37
- package/dist/cli-bundle/chunks/chunk-7CTQ7WW5.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-HO4KXD6I.js → chunk-7H5NNCJ5.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-XXXF6PAQ.js → chunk-7LTCLTRG.js} +69 -61
- package/dist/cli-bundle/chunks/chunk-7LTCLTRG.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-TQSZFPIS.js → chunk-AFGKSHAM.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-JXQUXVMI.js → chunk-AFSV5HBB.js} +77 -7
- package/dist/cli-bundle/chunks/{chunk-JXQUXVMI.js.map → chunk-AFSV5HBB.js.map} +1 -1
- package/dist/cli-bundle/chunks/{chunk-6N2VXVTQ.js → chunk-ARGDWQ4J.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-3U7ZR6M4.js → chunk-B57RJHBZ.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-7B67ZL4N.js → chunk-B6SH2YNN.js} +75 -5
- package/dist/cli-bundle/chunks/{chunk-7B67ZL4N.js.map → chunk-B6SH2YNN.js.map} +1 -1
- package/dist/cli-bundle/chunks/{chunk-YCQET3OT.js → chunk-BAP7G3N2.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-QKXHFPYM.js → chunk-BIRYX32V.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-RMLWNPH2.js → chunk-BVLOMU6O.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-YBLZ2VE7.js → chunk-CFSUNEL7.js} +320 -239
- package/dist/cli-bundle/chunks/chunk-CFSUNEL7.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-2VPAVL7O.js → chunk-CKX4WOPC.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-TKOVBP6C.js → chunk-D52ZN3BF.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-KPMKHGEA.js → chunk-D53RTYVI.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-ODALILG3.js → chunk-D5XHO4Q7.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-E2OJMKML.js → chunk-DCC2AQBD.js} +18 -9
- package/dist/cli-bundle/chunks/{chunk-E2OJMKML.js.map → chunk-DCC2AQBD.js.map} +1 -1
- package/dist/cli-bundle/chunks/{chunk-YAQEBNY7.js → chunk-DDFGYUCQ.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-EAB64KLB.js → chunk-DG2EQRIH.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-IG3SWA4A.js → chunk-EHJFUOXL.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-ONREO4ST.js → chunk-EY7ZE3TG.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-EJEXHTY5.js → chunk-FHOBCGQO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-H3EIEWGR.js → chunk-FL4D53ND.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-WUJQK4YV.js → chunk-FVNWHUME.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-INU6DKT5.js → chunk-FXFCFL73.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-QEHQ2GVG.js → chunk-FY4RLHSC.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-EACOH7AU.js → chunk-FZGM3PNA.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-FNSPG7MU.js → chunk-G6KM4YKY.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-AHVTB5I5.js → chunk-G6MYGULG.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-TSMHDIW4.js → chunk-GLZKZON6.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-2JKGO6QX.js → chunk-H5IOT54C.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-5ZSLZLDN.js → chunk-HF63SBLC.js} +585 -456
- package/dist/cli-bundle/chunks/chunk-HF63SBLC.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-SELVXEZK.js → chunk-HO4DLBNK.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-3CLU2XZO.js → chunk-HSYV4ZYT.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-EH2OPHBI.js → chunk-HTXXXF45.js} +23 -19
- package/dist/cli-bundle/chunks/chunk-HTXXXF45.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-CRVF2JDM.js → chunk-HXVHBERL.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-NU3IMIEA.js → chunk-I7DIDUSP.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-2NCIPMQP.js → chunk-I7GY4X6Y.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-JYFOV7FC.js → chunk-IE5KRAKN.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-UY2ACEMF.js → chunk-ILVOOAT4.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-GOSLKLFE.js → chunk-KH6QAHME.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-J6EY5V4N.js → chunk-KOEZCHRF.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-QKECXBBG.js → chunk-KX62NMZC.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-QKECXBBG.js.map → chunk-KX62NMZC.js.map} +1 -1
- package/dist/cli-bundle/chunks/{chunk-WQPUU7XD.js → chunk-L337QKWJ.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-LSG2U345.js → chunk-L6FVNR7X.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-ILX33QXL.js → chunk-LLODAQMP.js} +706 -532
- package/dist/cli-bundle/chunks/chunk-LLODAQMP.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-FMBNM2EN.js → chunk-LSOWTLEM.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-4223PVZT.js → chunk-M7MVOKVV.js} +3 -3
- package/dist/cli-bundle/chunks/chunk-MNV226E4.js +834 -0
- package/dist/cli-bundle/chunks/chunk-MNV226E4.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-UMOPHQSU.js → chunk-MR4SHYR4.js} +41 -19
- package/dist/cli-bundle/chunks/chunk-MR4SHYR4.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-BKVG6XOA.js → chunk-MSGETE6I.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-3WM75PWC.js → chunk-N33FD2UI.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-UFXU44HV.js → chunk-N7I2DGLP.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-3S5QVM5H.js → chunk-NCAFUBJX.js} +13 -13
- package/dist/cli-bundle/chunks/chunk-NCAFUBJX.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-6S3YSUYG.js → chunk-NNANAWFH.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-IJIICKVW.js → chunk-NTRQLE2R.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-SDQLJWBO.js → chunk-NVZ6NVHJ.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-H2Z3FYXQ.js → chunk-OWP6QFBV.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-Q7A43DS4.js → chunk-P22HGFFI.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-NLDFBC6J.js → chunk-P56LKFQX.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-NVPZIJVR.js → chunk-PT7MCCGD.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-P74IZQ7A.js → chunk-QKVVV6QO.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-5JLUII3O.js → chunk-QNUAZYGW.js} +321 -240
- package/dist/cli-bundle/chunks/chunk-QNUAZYGW.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-QIPLHNP7.js → chunk-QWBKN3QC.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-7PIWCHTW.js → chunk-R5XTTZSJ.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-JOUQZENX.js → chunk-RC4UOUXA.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-BEP7WJA2.js → chunk-RGMWJLXF.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-NP22ERDF.js → chunk-RTBX3C4C.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-HYB5AZ63.js → chunk-S46R2M3W.js} +117 -71
- package/dist/cli-bundle/chunks/chunk-S46R2M3W.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-H5APFTHZ.js → chunk-S6FF7VW6.js} +18 -18
- package/dist/cli-bundle/chunks/chunk-S6FF7VW6.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-UXONS674.js → chunk-SIJV365F.js} +54 -55
- package/dist/cli-bundle/chunks/chunk-SIJV365F.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-7Z4LKRS4.js → chunk-SPFZV2GR.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-ULTHRDBP.js → chunk-TM5CIO3F.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-4XQ3BDV4.js → chunk-V3VBXQQV.js} +36 -36
- package/dist/cli-bundle/chunks/chunk-V3VBXQQV.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-YAROI3PD.js → chunk-V7MP6YTN.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-OW4JWD5M.js → chunk-VAHZIPWS.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-DYH63FX7.js → chunk-VE6ZSTQW.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-3AUGG2DP.js → chunk-W5E2UUSH.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-BSEQUTQP.js → chunk-WACRQ26A.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-BSEQUTQP.js.map → chunk-WACRQ26A.js.map} +1 -1
- package/dist/cli-bundle/chunks/{chunk-UOHFKBUV.js → chunk-WL3SS45P.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-QKJGPFAF.js → chunk-WU3KAN6A.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-IA5FKNII.js → chunk-X2MGQMZO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-TD3LVC7D.js → chunk-X5YCTFKT.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-B7PE22W6.js → chunk-XC2HEEOV.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-J5AOEGDC.js → chunk-XNPMDSQQ.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-K2X6U4UA.js → chunk-XXLXJL7V.js} +4 -4
- package/dist/cli-bundle/chunks/chunk-XYJK6GIQ.js +851 -0
- package/dist/cli-bundle/chunks/chunk-XYJK6GIQ.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-RLCHOOHC.js → chunk-YJSURTBB.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-PGY23YTC.js → chunk-YKFHF37B.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-JFTKLTEF.js → chunk-YQCWK2MB.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-EYLCSJAI.js → chunk-YQEZWI3R.js} +2 -2
- package/dist/cli-bundle/chunks/close-BEP7MHF3.js +12 -0
- package/dist/cli-bundle/chunks/{close-CWODTPKG.js → close-Y6QFUJQN.js} +5 -5
- package/dist/cli-bundle/chunks/{close-many-CQFUY7MR.js → close-many-JJFW7KTT.js} +14 -14
- package/dist/cli-bundle/chunks/close-many-QJ6FKJUE.js +23 -0
- package/dist/cli-bundle/chunks/comments-2AOZQ5D2.js +13 -0
- package/dist/cli-bundle/chunks/{comments-WGLHR7LB.js → comments-TMHMALA5.js} +7 -7
- package/dist/cli-bundle/chunks/{copy-LXVDXH7B.js → copy-FWQA5OU4.js} +4 -4
- package/dist/cli-bundle/chunks/copy-N3LCQBMC.js +9 -0
- package/dist/cli-bundle/chunks/{create-LBVCYMEG.js → create-AQ5SIGZC.js} +9 -9
- package/dist/cli-bundle/chunks/{create-J5U6ND4K.js → create-KOGQ3JKD.js} +9 -9
- package/dist/cli-bundle/chunks/delete-6G3MBZ6S.js +10 -0
- package/dist/cli-bundle/chunks/{delete-PMJBNY5G.js → delete-YYYFOSEA.js} +4 -4
- package/dist/cli-bundle/chunks/{deps-OA26IS25.js → deps-5NC4IZH7.js} +5 -5
- package/dist/cli-bundle/chunks/{deps-JZ7TMVCB.js → deps-EVTOQMKW.js} +5 -5
- package/dist/cli-bundle/chunks/{docs-FEWB2DQB.js → docs-53NUGMIQ.js} +6 -6
- package/dist/cli-bundle/chunks/docs-OWRGDMNY.js +14 -0
- package/dist/cli-bundle/chunks/{files-EFIWKFTM.js → files-3PXGXYDB.js} +6 -6
- package/dist/cli-bundle/chunks/{files-6YFBJRBG.js → files-EGLKHD7O.js} +6 -6
- package/dist/cli-bundle/chunks/focus-KZLIA6WS.js +10 -0
- package/dist/cli-bundle/chunks/{focus-4QJR7FOQ.js → focus-SRPASFTN.js} +5 -5
- package/dist/cli-bundle/chunks/{history-compact-CKRPDTJN.js → history-compact-G4DULDCX.js} +6 -6
- package/dist/cli-bundle/chunks/history-compact-HHIUOMZ7.js +16 -0
- package/dist/cli-bundle/chunks/{history-redact-BB3TGDAE.js → history-redact-IUSJ6X3E.js} +4 -4
- package/dist/cli-bundle/chunks/{history-redact-D225BHOZ.js → history-redact-THHGRQXV.js} +4 -4
- package/dist/cli-bundle/chunks/history-repair-KG7SWXI6.js +16 -0
- package/dist/cli-bundle/chunks/{history-repair-RQXKQHL4.js → history-repair-LUQWRS7X.js} +6 -6
- package/dist/cli-bundle/chunks/{learnings-JLNLCOL5.js → learnings-2MRNBFJF.js} +7 -7
- package/dist/cli-bundle/chunks/learnings-ZVHSALJY.js +13 -0
- package/dist/cli-bundle/chunks/{notes-GB47XXQQ.js → notes-73JWKWUD.js} +7 -7
- package/dist/cli-bundle/chunks/notes-BAKUL5DJ.js +13 -0
- package/dist/cli-bundle/chunks/{plan-VDCJ2PCN.js → plan-AZPMCG37.js} +10 -10
- package/dist/cli-bundle/chunks/plan-LEAGLPGP.js +24 -0
- package/dist/cli-bundle/chunks/{profile-IVXQEL3D.js → profile-AGUKS52S.js} +9 -9
- package/dist/cli-bundle/chunks/{profile-FAU7NZML.js → profile-U2B6Y7GE.js} +9 -9
- package/dist/cli-bundle/chunks/{register-list-query-UL4UKBBN.js → register-list-query-A5KRJ5J2.js} +16 -16
- package/dist/cli-bundle/chunks/{register-list-query-DKA3EH5D.js → register-list-query-NEYP3TXO.js} +16 -16
- package/dist/cli-bundle/chunks/{register-mutation-RBBJ52DK.js → register-mutation-6LOPBAHC.js} +29 -29
- package/dist/cli-bundle/chunks/{register-mutation-ARFHRW55.js → register-mutation-GCZOALNJ.js} +29 -29
- package/dist/cli-bundle/chunks/{register-operations-ZIBBRSED.js → register-operations-6ZZIF27A.js} +35 -35
- package/dist/cli-bundle/chunks/{register-operations-ZUJ5JWPE.js → register-operations-REDIAEGI.js} +35 -35
- package/dist/cli-bundle/chunks/{register-setup-TDCGWIOS.js → register-setup-BHPMN5SK.js} +15 -15
- package/dist/cli-bundle/chunks/{register-setup-BCVLFEYS.js → register-setup-J3JS2ZVT.js} +15 -15
- package/dist/cli-bundle/chunks/{restore-25DLT2Q2.js → restore-E3PRGDN3.js} +6 -6
- package/dist/cli-bundle/chunks/restore-KIUYTAEJ.js +14 -0
- package/dist/cli-bundle/chunks/{schema-FNU3WE4O.js → schema-5JNFQFUW.js} +6 -6
- package/dist/cli-bundle/chunks/{schema-NBCM3RAD.js → schema-TMIW4XZC.js} +6 -6
- package/dist/cli-bundle/chunks/update-PQQHLYCC.js +21 -0
- package/dist/cli-bundle/chunks/{update-XHSIAIXE.js → update-SA6AG23P.js} +12 -12
- package/dist/cli-bundle/chunks/update-many-RQVTFJPD.js +36 -0
- package/dist/cli-bundle/chunks/update-many-TV3L3KBX.js +32 -0
- package/dist/cli-bundle/main.js +153 -855
- package/dist/cli-bundle/main.js.map +4 -4
- package/dist/cli-bundle/sdk-runtime.js +54 -54
- package/dist/cli-bundle/sdk-testing.js +6 -6
- package/dist/cli-bundle/sdk.js +195 -59
- package/dist/cli-bundle/sdk.js.map +3 -3
- package/dist/core/extensions/item-fields.js +2 -2
- package/dist/core/extensions/item-fields.js.map +1 -1
- package/dist/sdk/cli-bootstrap.d.ts +122 -0
- package/dist/sdk/cli-bootstrap.js +879 -0
- package/dist/sdk/cli-bootstrap.js.map +1 -0
- package/dist/sdk/eval.d.ts +66 -0
- package/dist/sdk/eval.js +186 -0
- package/dist/sdk/eval.js.map +1 -0
- package/dist/sdk/index.d.ts +16 -4
- package/dist/sdk/index.js +18 -6
- package/dist/sdk/index.js.map +1 -1
- package/dist/{cli/commands → sdk/query}/item-filter-options.d.ts +1 -1
- package/dist/{cli/commands → sdk/query}/item-filter-options.js +3 -3
- package/dist/sdk/query/item-filter-options.js.map +1 -0
- package/dist/sdk/query/list.d.ts +254 -0
- package/dist/sdk/query/list.js +1073 -0
- package/dist/sdk/query/list.js.map +1 -0
- package/dist/sdk/query/parsers.d.ts +9 -0
- package/dist/sdk/query/parsers.js +45 -0
- package/dist/sdk/query/parsers.js.map +1 -0
- package/dist/{cli/commands → sdk/query}/search-pagination.js +4 -4
- package/dist/sdk/query/search-pagination.js.map +1 -0
- package/dist/{cli/commands → sdk/query}/search-rendering.js +3 -3
- package/dist/sdk/query/search-rendering.js.map +1 -0
- package/dist/sdk/query/search.d.ts +469 -0
- package/dist/sdk/query/search.js +2247 -0
- package/dist/sdk/query/search.js.map +1 -0
- package/dist/sdk/runtime.d.ts +7 -7
- package/dist/sdk/runtime.js +13 -7
- package/dist/sdk/runtime.js.map +1 -1
- package/dist/sdk/search-refresh-worker.d.ts +2 -0
- package/dist/sdk/search-refresh-worker.js +19 -0
- package/dist/sdk/search-refresh-worker.js.map +1 -0
- package/dist/sdk/stats.d.ts +66 -0
- package/dist/sdk/stats.js +151 -0
- package/dist/sdk/stats.js.map +1 -0
- package/dist/sdk/telemetry-flush.d.ts +2 -0
- package/dist/sdk/telemetry-flush.js +14 -0
- package/dist/sdk/telemetry-flush.js.map +1 -0
- package/dist/sdk/telemetry.d.ts +14 -0
- package/dist/sdk/telemetry.js +398 -0
- package/dist/sdk/telemetry.js.map +1 -0
- package/dist/sdk/test/batch.d.ts +94 -0
- package/dist/sdk/test/batch.js +492 -0
- package/dist/sdk/test/batch.js.map +1 -0
- package/dist/sdk/test/entry.d.ts +6 -0
- package/dist/sdk/test/entry.js +74 -0
- package/dist/sdk/test/entry.js.map +1 -0
- package/dist/sdk/test/execution.d.ts +282 -0
- package/dist/sdk/test/execution.js +1817 -0
- package/dist/sdk/test/execution.js.map +1 -0
- package/dist/sdk/test/parsers.d.ts +48 -0
- package/dist/sdk/test/parsers.js +522 -0
- package/dist/sdk/test/parsers.js.map +1 -0
- package/dist/sdk/test/runs.d.ts +92 -0
- package/dist/sdk/test/runs.js +195 -0
- package/dist/sdk/test/runs.js.map +1 -0
- package/docs/SDK.md +122 -0
- package/docs/SDK_PRIMITIVE_INVENTORY.md +5 -3
- package/docs/examples/sdk-custom-tool/README.md +27 -0
- package/docs/examples/sdk-custom-tool/package.json +13 -0
- package/docs/examples/sdk-custom-tool/src/cli.ts +36 -0
- package/docs/examples/sdk-custom-tool/src/entry.ts +15 -0
- package/docs/examples/sdk-custom-tool/src/index.ts +223 -0
- package/marketplace.json +2 -2
- package/package.json +4 -4
- package/packages/pm-beads/package.json +1 -1
- package/packages/pm-calendar/package.json +1 -1
- package/packages/pm-command-kit/package.json +1 -1
- package/packages/pm-governance-audit/extensions/governance-audit/comments-audit.ts +77 -57
- package/packages/pm-governance-audit/extensions/governance-audit/dedupe-audit.ts +202 -194
- package/packages/pm-governance-audit/extensions/governance-audit/dedupe-merge.ts +227 -153
- package/packages/pm-governance-audit/extensions/governance-audit/normalize.ts +169 -125
- package/packages/pm-governance-audit/extensions/governance-audit/runtime-utils.ts +130 -81
- package/packages/pm-governance-audit/extensions/governance-audit/sdk.ts +53 -4
- package/packages/pm-governance-audit/package.json +1 -1
- package/packages/pm-guide-shell/package.json +1 -1
- package/packages/pm-kanban/package.json +1 -1
- package/packages/pm-lifecycle-hooks/package.json +1 -1
- package/packages/pm-linked-test-adapters/package.json +1 -1
- package/packages/pm-search-advanced/package.json +1 -1
- package/packages/pm-templates/package.json +1 -1
- package/packages/pm-todos/package.json +1 -1
- package/plugins/pm-claude/.claude-plugin/plugin.json +1 -1
- package/plugins/pm-codex/.codex-plugin/plugin.json +1 -1
- package/dist/cli/commands/item-filter-options.js.map +0 -1
- package/dist/cli/commands/search-pagination.js.map +0 -1
- package/dist/cli/commands/search-rendering.js.map +0 -1
- package/dist/cli-bundle/chunks/append-UZVHUO74.js +0 -11
- package/dist/cli-bundle/chunks/chunk-3S5QVM5H.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-4XQ3BDV4.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-5JLUII3O.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-5ZSLZLDN.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-EH2OPHBI.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-H5APFTHZ.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-HYB5AZ63.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-ILX33QXL.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-LPYWLWDS.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-ONG5V5CI.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-UMOPHQSU.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-UXONS674.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-XXXF6PAQ.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-YBLZ2VE7.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-YXSHIAUJ.js +0 -58
- package/dist/cli-bundle/chunks/chunk-YXSHIAUJ.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-ZKRZY773.js +0 -68
- package/dist/cli-bundle/chunks/chunk-ZKRZY773.js.map +0 -7
- package/dist/cli-bundle/chunks/close-W6LI2PKM.js +0 -12
- package/dist/cli-bundle/chunks/close-many-DLDDVSH5.js +0 -23
- package/dist/cli-bundle/chunks/comments-E3TNTK24.js +0 -13
- package/dist/cli-bundle/chunks/copy-Q5ZJPUKR.js +0 -9
- package/dist/cli-bundle/chunks/delete-WNHB3LYW.js +0 -10
- package/dist/cli-bundle/chunks/docs-HA2AIDBB.js +0 -14
- package/dist/cli-bundle/chunks/focus-POIW5LTJ.js +0 -10
- package/dist/cli-bundle/chunks/history-compact-FWG2C7FZ.js +0 -16
- package/dist/cli-bundle/chunks/history-repair-6GEAM7HE.js +0 -16
- package/dist/cli-bundle/chunks/learnings-RSNLSWDC.js +0 -13
- package/dist/cli-bundle/chunks/notes-2WDH6DXU.js +0 -13
- package/dist/cli-bundle/chunks/plan-DOVI2VMW.js +0 -24
- package/dist/cli-bundle/chunks/restore-YPMVUUEX.js +0 -14
- package/dist/cli-bundle/chunks/update-WWBYOPXO.js +0 -21
- package/dist/cli-bundle/chunks/update-many-OUGIU5SF.js +0 -32
- package/dist/cli-bundle/chunks/update-many-TA7NGQBO.js +0 -36
- /package/dist/cli-bundle/chunks/{append-OJQFUQ4T.js.map → append-5YF3TO7I.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{append-UZVHUO74.js.map → append-JHO5K6RP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-BCOFWYW4.js.map → chunk-2BX74BAS.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-APRVSW2O.js.map → chunk-2CXL335K.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-KG44YSKD.js.map → chunk-2FUOXSRN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-HDH3JUGG.js.map → chunk-2IPNL3DR.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-GM5QHQU6.js.map → chunk-2XOSFSTH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-K3WII2ME.js.map → chunk-37DRDP2B.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-2WSE6PO2.js.map → chunk-37V5MXAU.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-UWQHLMEB.js.map → chunk-3D4YVTNG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-PMOSXADO.js.map → chunk-47HXN6RX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-6CFNAVTF.js.map → chunk-5HGZKQUL.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-2IFFUZLC.js.map → chunk-5UKQLQM2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-DM4H7FP4.js.map → chunk-633PKXLT.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-XSJUSQAE.js.map → chunk-646MQXFW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ZI6VQWQ7.js.map → chunk-66MKH7SZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-S6MQESFR.js.map → chunk-67RO3H4N.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-34L5OT3Y.js.map → chunk-6DYOZS6C.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-RRM5JYJC.js.map → chunk-6O44IN44.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-PENXZX3U.js.map → chunk-74FKFFXO.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-HO4KXD6I.js.map → chunk-7H5NNCJ5.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-TQSZFPIS.js.map → chunk-AFGKSHAM.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-6N2VXVTQ.js.map → chunk-ARGDWQ4J.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-3U7ZR6M4.js.map → chunk-B57RJHBZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-YCQET3OT.js.map → chunk-BAP7G3N2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-QKXHFPYM.js.map → chunk-BIRYX32V.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-RMLWNPH2.js.map → chunk-BVLOMU6O.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-2VPAVL7O.js.map → chunk-CKX4WOPC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-TKOVBP6C.js.map → chunk-D52ZN3BF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-KPMKHGEA.js.map → chunk-D53RTYVI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ODALILG3.js.map → chunk-D5XHO4Q7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-YAQEBNY7.js.map → chunk-DDFGYUCQ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-EAB64KLB.js.map → chunk-DG2EQRIH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-IG3SWA4A.js.map → chunk-EHJFUOXL.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ONREO4ST.js.map → chunk-EY7ZE3TG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-EJEXHTY5.js.map → chunk-FHOBCGQO.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-H3EIEWGR.js.map → chunk-FL4D53ND.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-WUJQK4YV.js.map → chunk-FVNWHUME.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-INU6DKT5.js.map → chunk-FXFCFL73.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-QEHQ2GVG.js.map → chunk-FY4RLHSC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-EACOH7AU.js.map → chunk-FZGM3PNA.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-FNSPG7MU.js.map → chunk-G6KM4YKY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-AHVTB5I5.js.map → chunk-G6MYGULG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-TSMHDIW4.js.map → chunk-GLZKZON6.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-2JKGO6QX.js.map → chunk-H5IOT54C.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-SELVXEZK.js.map → chunk-HO4DLBNK.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-3CLU2XZO.js.map → chunk-HSYV4ZYT.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-CRVF2JDM.js.map → chunk-HXVHBERL.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-NU3IMIEA.js.map → chunk-I7DIDUSP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-2NCIPMQP.js.map → chunk-I7GY4X6Y.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-JYFOV7FC.js.map → chunk-IE5KRAKN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-UY2ACEMF.js.map → chunk-ILVOOAT4.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-GOSLKLFE.js.map → chunk-KH6QAHME.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-J6EY5V4N.js.map → chunk-KOEZCHRF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-WQPUU7XD.js.map → chunk-L337QKWJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-LSG2U345.js.map → chunk-L6FVNR7X.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-FMBNM2EN.js.map → chunk-LSOWTLEM.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-4223PVZT.js.map → chunk-M7MVOKVV.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-BKVG6XOA.js.map → chunk-MSGETE6I.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-3WM75PWC.js.map → chunk-N33FD2UI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-UFXU44HV.js.map → chunk-N7I2DGLP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-6S3YSUYG.js.map → chunk-NNANAWFH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-IJIICKVW.js.map → chunk-NTRQLE2R.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-SDQLJWBO.js.map → chunk-NVZ6NVHJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-H2Z3FYXQ.js.map → chunk-OWP6QFBV.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-Q7A43DS4.js.map → chunk-P22HGFFI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-NLDFBC6J.js.map → chunk-P56LKFQX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-NVPZIJVR.js.map → chunk-PT7MCCGD.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-P74IZQ7A.js.map → chunk-QKVVV6QO.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-QIPLHNP7.js.map → chunk-QWBKN3QC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-7PIWCHTW.js.map → chunk-R5XTTZSJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-JOUQZENX.js.map → chunk-RC4UOUXA.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-BEP7WJA2.js.map → chunk-RGMWJLXF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-NP22ERDF.js.map → chunk-RTBX3C4C.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-7Z4LKRS4.js.map → chunk-SPFZV2GR.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ULTHRDBP.js.map → chunk-TM5CIO3F.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-YAROI3PD.js.map → chunk-V7MP6YTN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-OW4JWD5M.js.map → chunk-VAHZIPWS.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-DYH63FX7.js.map → chunk-VE6ZSTQW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-3AUGG2DP.js.map → chunk-W5E2UUSH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-UOHFKBUV.js.map → chunk-WL3SS45P.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-QKJGPFAF.js.map → chunk-WU3KAN6A.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-IA5FKNII.js.map → chunk-X2MGQMZO.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-TD3LVC7D.js.map → chunk-X5YCTFKT.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-B7PE22W6.js.map → chunk-XC2HEEOV.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-J5AOEGDC.js.map → chunk-XNPMDSQQ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-K2X6U4UA.js.map → chunk-XXLXJL7V.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-RLCHOOHC.js.map → chunk-YJSURTBB.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-PGY23YTC.js.map → chunk-YKFHF37B.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-JFTKLTEF.js.map → chunk-YQCWK2MB.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-EYLCSJAI.js.map → chunk-YQEZWI3R.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-W6LI2PKM.js.map → close-BEP7MHF3.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-CWODTPKG.js.map → close-Y6QFUJQN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-many-CQFUY7MR.js.map → close-many-JJFW7KTT.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-many-DLDDVSH5.js.map → close-many-QJ6FKJUE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{comments-E3TNTK24.js.map → comments-2AOZQ5D2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{comments-WGLHR7LB.js.map → comments-TMHMALA5.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{copy-LXVDXH7B.js.map → copy-FWQA5OU4.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{copy-Q5ZJPUKR.js.map → copy-N3LCQBMC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{create-LBVCYMEG.js.map → create-AQ5SIGZC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{create-J5U6ND4K.js.map → create-KOGQ3JKD.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{delete-WNHB3LYW.js.map → delete-6G3MBZ6S.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{delete-PMJBNY5G.js.map → delete-YYYFOSEA.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{deps-OA26IS25.js.map → deps-5NC4IZH7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{deps-JZ7TMVCB.js.map → deps-EVTOQMKW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{docs-FEWB2DQB.js.map → docs-53NUGMIQ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{docs-HA2AIDBB.js.map → docs-OWRGDMNY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{files-EFIWKFTM.js.map → files-3PXGXYDB.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{files-6YFBJRBG.js.map → files-EGLKHD7O.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{focus-POIW5LTJ.js.map → focus-KZLIA6WS.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{focus-4QJR7FOQ.js.map → focus-SRPASFTN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-compact-CKRPDTJN.js.map → history-compact-G4DULDCX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-compact-FWG2C7FZ.js.map → history-compact-HHIUOMZ7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-redact-BB3TGDAE.js.map → history-redact-IUSJ6X3E.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-redact-D225BHOZ.js.map → history-redact-THHGRQXV.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-repair-6GEAM7HE.js.map → history-repair-KG7SWXI6.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-repair-RQXKQHL4.js.map → history-repair-LUQWRS7X.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{learnings-JLNLCOL5.js.map → learnings-2MRNBFJF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{learnings-RSNLSWDC.js.map → learnings-ZVHSALJY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{notes-GB47XXQQ.js.map → notes-73JWKWUD.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{notes-2WDH6DXU.js.map → notes-BAKUL5DJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{plan-VDCJ2PCN.js.map → plan-AZPMCG37.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{plan-DOVI2VMW.js.map → plan-LEAGLPGP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{profile-IVXQEL3D.js.map → profile-AGUKS52S.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{profile-FAU7NZML.js.map → profile-U2B6Y7GE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-list-query-UL4UKBBN.js.map → register-list-query-A5KRJ5J2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-list-query-DKA3EH5D.js.map → register-list-query-NEYP3TXO.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-mutation-RBBJ52DK.js.map → register-mutation-6LOPBAHC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-mutation-ARFHRW55.js.map → register-mutation-GCZOALNJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-operations-ZIBBRSED.js.map → register-operations-6ZZIF27A.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-operations-ZUJ5JWPE.js.map → register-operations-REDIAEGI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-setup-TDCGWIOS.js.map → register-setup-BHPMN5SK.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-setup-BCVLFEYS.js.map → register-setup-J3JS2ZVT.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{restore-25DLT2Q2.js.map → restore-E3PRGDN3.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{restore-YPMVUUEX.js.map → restore-KIUYTAEJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{schema-FNU3WE4O.js.map → schema-5JNFQFUW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{schema-NBCM3RAD.js.map → schema-TMIW4XZC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-WWBYOPXO.js.map → update-PQQHLYCC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-XHSIAIXE.js.map → update-SA6AG23P.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-many-TA7NGQBO.js.map → update-many-RQVTFJPD.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-many-OUGIU5SF.js.map → update-many-TV3L3KBX.js.map} +0 -0
- /package/dist/{cli/commands → sdk/query}/search-pagination.d.ts +0 -0
- /package/dist/{cli/commands → sdk/query}/search-rendering.d.ts +0 -0
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import type { GlobalOptions } from "../../core/shared/command-types.js";
|
|
2
|
+
import { type BackgroundLogStream, type BackgroundTestRunKind, type BackgroundTestRunStatus } from "../../core/test/background-runs.js";
|
|
3
|
+
/** Documents the start background run command options payload exchanged by command, SDK, and package integrations. */
|
|
4
|
+
export interface StartBackgroundRunCommandOptions {
|
|
5
|
+
/** Value that configures or reports kind for this contract. */
|
|
6
|
+
kind: BackgroundTestRunKind;
|
|
7
|
+
/** Value that configures or reports command args for this contract. */
|
|
8
|
+
commandArgs: string[];
|
|
9
|
+
/** Value that configures or reports target id for this contract. */
|
|
10
|
+
targetId?: string;
|
|
11
|
+
/** Value that configures or reports status filter for this contract. */
|
|
12
|
+
statusFilter?: string;
|
|
13
|
+
/** Value that configures or reports author for this contract. */
|
|
14
|
+
author?: string;
|
|
15
|
+
/** Value that configures or reports no extensions for this contract. */
|
|
16
|
+
noExtensions?: boolean;
|
|
17
|
+
}
|
|
18
|
+
/** Documents the start background run result payload exchanged by command, SDK, and package integrations. */
|
|
19
|
+
export interface StartBackgroundRunResult {
|
|
20
|
+
/** Value that configures or reports started for this contract. */
|
|
21
|
+
started: boolean;
|
|
22
|
+
/** Value that configures or reports duplicate of for this contract. */
|
|
23
|
+
duplicate_of?: string;
|
|
24
|
+
/** Value that configures or reports run for this contract. */
|
|
25
|
+
run: unknown;
|
|
26
|
+
}
|
|
27
|
+
/** Implements run start background run for the public runtime surface of this module. */
|
|
28
|
+
export declare function runStartBackgroundRun(options: StartBackgroundRunCommandOptions, global: GlobalOptions): Promise<StartBackgroundRunResult>;
|
|
29
|
+
/** Documents the test runs list command options payload exchanged by command, SDK, and package integrations. */
|
|
30
|
+
export interface TestRunsListCommandOptions {
|
|
31
|
+
/** Lifecycle state reported for status. */
|
|
32
|
+
status?: string;
|
|
33
|
+
/** Value that configures or reports limit for this contract. */
|
|
34
|
+
limit?: string;
|
|
35
|
+
}
|
|
36
|
+
/** Implements run test runs list for the public runtime surface of this module. */
|
|
37
|
+
export declare function runTestRunsList(options: TestRunsListCommandOptions, global: GlobalOptions): Promise<{
|
|
38
|
+
runs: unknown[];
|
|
39
|
+
count: number;
|
|
40
|
+
filters: {
|
|
41
|
+
status?: BackgroundTestRunStatus;
|
|
42
|
+
limit?: number;
|
|
43
|
+
};
|
|
44
|
+
}>;
|
|
45
|
+
/** Implements run test runs status for the public runtime surface of this module. */
|
|
46
|
+
export declare function runTestRunsStatus(runId: string, global: GlobalOptions): Promise<{
|
|
47
|
+
run: unknown;
|
|
48
|
+
health: unknown;
|
|
49
|
+
}>;
|
|
50
|
+
/** Documents the test runs logs command options payload exchanged by command, SDK, and package integrations. */
|
|
51
|
+
export interface TestRunsLogsCommandOptions {
|
|
52
|
+
/** Value that configures or reports stream for this contract. */
|
|
53
|
+
stream?: string;
|
|
54
|
+
/** Value that configures or reports tail for this contract. */
|
|
55
|
+
tail?: string;
|
|
56
|
+
}
|
|
57
|
+
/** Implements run test runs logs for the public runtime surface of this module. */
|
|
58
|
+
export declare function runTestRunsLogs(runId: string, options: TestRunsLogsCommandOptions, global: GlobalOptions): Promise<{
|
|
59
|
+
run: unknown;
|
|
60
|
+
stream: BackgroundLogStream;
|
|
61
|
+
tail: number;
|
|
62
|
+
stdout: string[];
|
|
63
|
+
stderr: string[];
|
|
64
|
+
}>;
|
|
65
|
+
/** Documents the test runs stop command options payload exchanged by command, SDK, and package integrations. */
|
|
66
|
+
export interface TestRunsStopCommandOptions {
|
|
67
|
+
/** Value that configures or reports force for this contract. */
|
|
68
|
+
force?: boolean;
|
|
69
|
+
}
|
|
70
|
+
/** Implements run test runs stop for the public runtime surface of this module. */
|
|
71
|
+
export declare function runTestRunsStop(runId: string, options: TestRunsStopCommandOptions, global: GlobalOptions): Promise<{
|
|
72
|
+
run: unknown;
|
|
73
|
+
signal_sent: "SIGTERM" | "SIGKILL" | "none";
|
|
74
|
+
}>;
|
|
75
|
+
/** Documents the test runs resume command options payload exchanged by command, SDK, and package integrations. */
|
|
76
|
+
export interface TestRunsResumeCommandOptions {
|
|
77
|
+
/** Value that configures or reports author for this contract. */
|
|
78
|
+
author?: string;
|
|
79
|
+
/** Value that configures or reports no extensions for this contract. */
|
|
80
|
+
noExtensions?: boolean;
|
|
81
|
+
}
|
|
82
|
+
/** Implements run test runs resume for the public runtime surface of this module. */
|
|
83
|
+
export declare function runTestRunsResume(runId: string, options: TestRunsResumeCommandOptions, global: GlobalOptions): Promise<{
|
|
84
|
+
resumed_from: string;
|
|
85
|
+
run: unknown;
|
|
86
|
+
}>;
|
|
87
|
+
/** Implements run test runs worker for the public runtime surface of this module. */
|
|
88
|
+
export declare function runTestRunsWorker(runId: string, global: GlobalOptions): Promise<{
|
|
89
|
+
id: string;
|
|
90
|
+
status: BackgroundTestRunStatus;
|
|
91
|
+
exit_code?: number;
|
|
92
|
+
}>;
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module sdk/test/runs
|
|
3
|
+
*
|
|
4
|
+
* Implements the pm test runs command surface and its agent-facing runtime behavior.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
!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]="2c42bfb9-c598-5a6e-bfff-0c073bb44205")}catch(e){}}();
|
|
8
|
+
import os from "node:os";
|
|
9
|
+
import { pathExists } from "../../core/fs/fs-utils.js";
|
|
10
|
+
import { EXIT_CODE } from "../../core/shared/constants.js";
|
|
11
|
+
import { PmCliError } from "../../core/shared/errors.js";
|
|
12
|
+
import { getBackgroundTestRunStatus, listBackgroundTestRuns, readBackgroundTestRunLogs, resumeBackgroundTestRun, runBackgroundTestRunWorker, spawnBackgroundTestRunWorker, startBackgroundTestRun, stopBackgroundTestRun, } from "../../core/test/background-runs.js";
|
|
13
|
+
import { getSettingsPath, resolveGlobalPmRoot, resolvePmRoot, } from "../../core/store/paths.js";
|
|
14
|
+
import { readSettings } from "../../core/store/settings.js";
|
|
15
|
+
import { parseLimit } from "../../core/shared/numeric-parsers.js";
|
|
16
|
+
const BACKGROUND_STATUS_VALUES = [
|
|
17
|
+
"queued",
|
|
18
|
+
"running",
|
|
19
|
+
"passed",
|
|
20
|
+
"failed",
|
|
21
|
+
"stopped",
|
|
22
|
+
"canceled",
|
|
23
|
+
];
|
|
24
|
+
const BACKGROUND_STREAM_VALUES = [
|
|
25
|
+
"stdout",
|
|
26
|
+
"stderr",
|
|
27
|
+
"both",
|
|
28
|
+
];
|
|
29
|
+
function normalizeStatus(value) {
|
|
30
|
+
if (value === undefined) {
|
|
31
|
+
return undefined;
|
|
32
|
+
}
|
|
33
|
+
const normalized = value.trim().toLowerCase();
|
|
34
|
+
if (BACKGROUND_STATUS_VALUES.includes(normalized)) {
|
|
35
|
+
return normalized;
|
|
36
|
+
}
|
|
37
|
+
throw new PmCliError(`Invalid --status value "${value}"`, EXIT_CODE.USAGE);
|
|
38
|
+
}
|
|
39
|
+
function normalizeStream(value) {
|
|
40
|
+
if (value === undefined || value.trim().length === 0) {
|
|
41
|
+
return "stderr";
|
|
42
|
+
}
|
|
43
|
+
const normalized = value.trim().toLowerCase();
|
|
44
|
+
if (BACKGROUND_STREAM_VALUES.includes(normalized)) {
|
|
45
|
+
return normalized;
|
|
46
|
+
}
|
|
47
|
+
throw new PmCliError(`Invalid --stream value "${value}"`, EXIT_CODE.USAGE);
|
|
48
|
+
}
|
|
49
|
+
function resolveWhoamiFallback() {
|
|
50
|
+
try {
|
|
51
|
+
const username = os.userInfo().username.trim();
|
|
52
|
+
if (username.length > 0) {
|
|
53
|
+
return username;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
catch {
|
|
57
|
+
// Fall back to environment-derived attribution.
|
|
58
|
+
}
|
|
59
|
+
return undefined;
|
|
60
|
+
}
|
|
61
|
+
function resolveRequestedBy(author, fallback) {
|
|
62
|
+
const candidates = [
|
|
63
|
+
author,
|
|
64
|
+
process.env.PM_AUTHOR,
|
|
65
|
+
fallback,
|
|
66
|
+
process.env.USER,
|
|
67
|
+
process.env.LOGNAME,
|
|
68
|
+
process.env.USERNAME,
|
|
69
|
+
resolveWhoamiFallback(),
|
|
70
|
+
];
|
|
71
|
+
for (const candidate of candidates) {
|
|
72
|
+
if (typeof candidate !== "string") {
|
|
73
|
+
continue;
|
|
74
|
+
}
|
|
75
|
+
const trimmed = candidate.trim();
|
|
76
|
+
if (trimmed.length > 0) {
|
|
77
|
+
return trimmed;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
return "unknown";
|
|
81
|
+
}
|
|
82
|
+
async function ensureInitialized(pmRoot) {
|
|
83
|
+
if (!(await pathExists(getSettingsPath(pmRoot)))) {
|
|
84
|
+
throw new PmCliError(`Tracker is not initialized at ${pmRoot}. Run pm init first.`, EXIT_CODE.NOT_FOUND);
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
/** Implements run start background run for the public runtime surface of this module. */
|
|
88
|
+
export async function runStartBackgroundRun(options, global) {
|
|
89
|
+
const pmRoot = resolvePmRoot(process.cwd(), global.path);
|
|
90
|
+
const globalPmRoot = resolveGlobalPmRoot(process.cwd());
|
|
91
|
+
await ensureInitialized(pmRoot);
|
|
92
|
+
const settings = await readSettings(pmRoot);
|
|
93
|
+
const requestedBy = resolveRequestedBy(options.author, settings.author_default);
|
|
94
|
+
const started = await startBackgroundTestRun({
|
|
95
|
+
pmRoot,
|
|
96
|
+
globalPmRoot,
|
|
97
|
+
kind: options.kind,
|
|
98
|
+
commandArgs: options.commandArgs,
|
|
99
|
+
requestedBy,
|
|
100
|
+
targetId: options.targetId,
|
|
101
|
+
statusFilter: options.statusFilter,
|
|
102
|
+
});
|
|
103
|
+
if (!started.started) {
|
|
104
|
+
return {
|
|
105
|
+
started: false,
|
|
106
|
+
duplicate_of: started.duplicate_of,
|
|
107
|
+
run: started.run,
|
|
108
|
+
};
|
|
109
|
+
}
|
|
110
|
+
const spawned = await spawnBackgroundTestRunWorker({
|
|
111
|
+
pmRoot,
|
|
112
|
+
runId: started.run.id,
|
|
113
|
+
noExtensions: options.noExtensions === true,
|
|
114
|
+
});
|
|
115
|
+
return {
|
|
116
|
+
started: true,
|
|
117
|
+
run: spawned,
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
/** Implements run test runs list for the public runtime surface of this module. */
|
|
121
|
+
export async function runTestRunsList(options, global) {
|
|
122
|
+
const pmRoot = resolvePmRoot(process.cwd(), global.path);
|
|
123
|
+
await ensureInitialized(pmRoot);
|
|
124
|
+
const status = normalizeStatus(options.status);
|
|
125
|
+
const limit = parseLimit(options.limit, "limit");
|
|
126
|
+
const runs = await listBackgroundTestRuns(pmRoot, { status, limit });
|
|
127
|
+
return {
|
|
128
|
+
runs,
|
|
129
|
+
count: runs.length,
|
|
130
|
+
filters: {
|
|
131
|
+
status,
|
|
132
|
+
limit,
|
|
133
|
+
},
|
|
134
|
+
};
|
|
135
|
+
}
|
|
136
|
+
/** Implements run test runs status for the public runtime surface of this module. */
|
|
137
|
+
export async function runTestRunsStatus(runId, global) {
|
|
138
|
+
const pmRoot = resolvePmRoot(process.cwd(), global.path);
|
|
139
|
+
await ensureInitialized(pmRoot);
|
|
140
|
+
const status = await getBackgroundTestRunStatus(pmRoot, runId);
|
|
141
|
+
return {
|
|
142
|
+
run: status.run,
|
|
143
|
+
health: status.health,
|
|
144
|
+
};
|
|
145
|
+
}
|
|
146
|
+
/** Implements run test runs logs for the public runtime surface of this module. */
|
|
147
|
+
export async function runTestRunsLogs(runId, options, global) {
|
|
148
|
+
const pmRoot = resolvePmRoot(process.cwd(), global.path);
|
|
149
|
+
await ensureInitialized(pmRoot);
|
|
150
|
+
const stream = normalizeStream(options.stream);
|
|
151
|
+
const tail = parseLimit(options.tail, "tail");
|
|
152
|
+
const logs = await readBackgroundTestRunLogs(pmRoot, runId, stream, tail);
|
|
153
|
+
return {
|
|
154
|
+
run: logs.run,
|
|
155
|
+
stream: logs.stream,
|
|
156
|
+
tail: logs.tail,
|
|
157
|
+
stdout: logs.stdout,
|
|
158
|
+
stderr: logs.stderr,
|
|
159
|
+
};
|
|
160
|
+
}
|
|
161
|
+
/** Implements run test runs stop for the public runtime surface of this module. */
|
|
162
|
+
export async function runTestRunsStop(runId, options, global) {
|
|
163
|
+
const pmRoot = resolvePmRoot(process.cwd(), global.path);
|
|
164
|
+
await ensureInitialized(pmRoot);
|
|
165
|
+
const stopped = await stopBackgroundTestRun(pmRoot, runId, options.force === true);
|
|
166
|
+
return {
|
|
167
|
+
run: stopped.run,
|
|
168
|
+
signal_sent: stopped.signal_sent,
|
|
169
|
+
};
|
|
170
|
+
}
|
|
171
|
+
/** Implements run test runs resume for the public runtime surface of this module. */
|
|
172
|
+
export async function runTestRunsResume(runId, options, global) {
|
|
173
|
+
const pmRoot = resolvePmRoot(process.cwd(), global.path);
|
|
174
|
+
await ensureInitialized(pmRoot);
|
|
175
|
+
const settings = await readSettings(pmRoot);
|
|
176
|
+
const requestedBy = resolveRequestedBy(options.author, settings.author_default);
|
|
177
|
+
const resumed = await resumeBackgroundTestRun(pmRoot, runId, requestedBy, options.noExtensions === true);
|
|
178
|
+
return {
|
|
179
|
+
resumed_from: runId,
|
|
180
|
+
run: resumed,
|
|
181
|
+
};
|
|
182
|
+
}
|
|
183
|
+
/** Implements run test runs worker for the public runtime surface of this module. */
|
|
184
|
+
export async function runTestRunsWorker(runId, global) {
|
|
185
|
+
const pmRoot = resolvePmRoot(process.cwd(), global.path);
|
|
186
|
+
await ensureInitialized(pmRoot);
|
|
187
|
+
const finished = await runBackgroundTestRunWorker(pmRoot, runId, global.noExtensions === true);
|
|
188
|
+
return {
|
|
189
|
+
id: finished.id,
|
|
190
|
+
status: finished.status,
|
|
191
|
+
exit_code: finished.exit_code,
|
|
192
|
+
};
|
|
193
|
+
}
|
|
194
|
+
//# sourceMappingURL=runs.js.map
|
|
195
|
+
//# debugId=2c42bfb9-c598-5a6e-bfff-0c073bb44205
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runs.js","sources":["sdk/test/runs.ts"],"sourceRoot":"/","sourcesContent":["/**\n * @module sdk/test/runs\n *\n * Implements the pm test runs command surface and its agent-facing runtime behavior.\n */\nimport os from \"node:os\";\nimport { pathExists } from \"../../core/fs/fs-utils.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 {\n type BackgroundLogStream,\n type BackgroundTestRunKind,\n type BackgroundTestRunStatus,\n getBackgroundTestRunStatus,\n listBackgroundTestRuns,\n readBackgroundTestRunLogs,\n resumeBackgroundTestRun,\n runBackgroundTestRunWorker,\n spawnBackgroundTestRunWorker,\n startBackgroundTestRun,\n stopBackgroundTestRun,\n} from \"../../core/test/background-runs.js\";\nimport {\n getSettingsPath,\n resolveGlobalPmRoot,\n resolvePmRoot,\n} from \"../../core/store/paths.js\";\nimport { readSettings } from \"../../core/store/settings.js\";\nimport { parseLimit } from \"../../core/shared/numeric-parsers.js\";\n\nconst BACKGROUND_STATUS_VALUES: readonly BackgroundTestRunStatus[] = [\n \"queued\",\n \"running\",\n \"passed\",\n \"failed\",\n \"stopped\",\n \"canceled\",\n];\nconst BACKGROUND_STREAM_VALUES: readonly BackgroundLogStream[] = [\n \"stdout\",\n \"stderr\",\n \"both\",\n];\n\nfunction normalizeStatus(\n value: string | undefined,\n): BackgroundTestRunStatus | undefined {\n if (value === undefined) {\n return undefined;\n }\n const normalized = value.trim().toLowerCase();\n if ((BACKGROUND_STATUS_VALUES as readonly string[]).includes(normalized)) {\n return normalized as BackgroundTestRunStatus;\n }\n throw new PmCliError(`Invalid --status value \"${value}\"`, EXIT_CODE.USAGE);\n}\n\nfunction normalizeStream(value: string | undefined): BackgroundLogStream {\n if (value === undefined || value.trim().length === 0) {\n return \"stderr\";\n }\n const normalized = value.trim().toLowerCase();\n if ((BACKGROUND_STREAM_VALUES as readonly string[]).includes(normalized)) {\n return normalized as BackgroundLogStream;\n }\n throw new PmCliError(`Invalid --stream value \"${value}\"`, EXIT_CODE.USAGE);\n}\n\nfunction resolveWhoamiFallback(): string | undefined {\n try {\n const username = os.userInfo().username.trim();\n if (username.length > 0) {\n return username;\n }\n } catch {\n // Fall back to environment-derived attribution.\n }\n return undefined;\n}\n\nfunction resolveRequestedBy(\n author: string | undefined,\n fallback: string,\n): string {\n const candidates = [\n author,\n process.env.PM_AUTHOR,\n fallback,\n process.env.USER,\n process.env.LOGNAME,\n process.env.USERNAME,\n resolveWhoamiFallback(),\n ];\n for (const candidate of candidates) {\n if (typeof candidate !== \"string\") {\n continue;\n }\n const trimmed = candidate.trim();\n if (trimmed.length > 0) {\n return trimmed;\n }\n }\n return \"unknown\";\n}\n\nasync function ensureInitialized(pmRoot: string): Promise<void> {\n if (!(await pathExists(getSettingsPath(pmRoot)))) {\n throw new PmCliError(\n `Tracker is not initialized at ${pmRoot}. Run pm init first.`,\n EXIT_CODE.NOT_FOUND,\n );\n }\n}\n\n/** Documents the start background run command options payload exchanged by command, SDK, and package integrations. */\nexport interface StartBackgroundRunCommandOptions {\n /** Value that configures or reports kind for this contract. */\n kind: BackgroundTestRunKind;\n /** Value that configures or reports command args for this contract. */\n commandArgs: string[];\n /** Value that configures or reports target id for this contract. */\n targetId?: string;\n /** Value that configures or reports status filter for this contract. */\n statusFilter?: string;\n /** Value that configures or reports author for this contract. */\n author?: string;\n /** Value that configures or reports no extensions for this contract. */\n noExtensions?: boolean;\n}\n\n/** Documents the start background run result payload exchanged by command, SDK, and package integrations. */\nexport interface StartBackgroundRunResult {\n /** Value that configures or reports started for this contract. */\n started: boolean;\n /** Value that configures or reports duplicate of for this contract. */\n duplicate_of?: string;\n /** Value that configures or reports run for this contract. */\n run: unknown;\n}\n\n/** Implements run start background run for the public runtime surface of this module. */\nexport async function runStartBackgroundRun(\n options: StartBackgroundRunCommandOptions,\n global: GlobalOptions,\n): Promise<StartBackgroundRunResult> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n const globalPmRoot = resolveGlobalPmRoot(process.cwd());\n await ensureInitialized(pmRoot);\n const settings = await readSettings(pmRoot);\n const requestedBy = resolveRequestedBy(\n options.author,\n settings.author_default,\n );\n const started = await startBackgroundTestRun({\n pmRoot,\n globalPmRoot,\n kind: options.kind,\n commandArgs: options.commandArgs,\n requestedBy,\n targetId: options.targetId,\n statusFilter: options.statusFilter,\n });\n if (!started.started) {\n return {\n started: false,\n duplicate_of: started.duplicate_of,\n run: started.run,\n };\n }\n const spawned = await spawnBackgroundTestRunWorker({\n pmRoot,\n runId: started.run.id,\n noExtensions: options.noExtensions === true,\n });\n return {\n started: true,\n run: spawned,\n };\n}\n\n/** Documents the test runs list command options payload exchanged by command, SDK, and package integrations. */\nexport interface TestRunsListCommandOptions {\n /** Lifecycle state reported for status. */\n status?: string;\n /** Value that configures or reports limit for this contract. */\n limit?: string;\n}\n\n/** Implements run test runs list for the public runtime surface of this module. */\nexport async function runTestRunsList(\n options: TestRunsListCommandOptions,\n global: GlobalOptions,\n): Promise<{\n runs: unknown[];\n count: number;\n filters: {\n status?: BackgroundTestRunStatus;\n limit?: number;\n };\n}> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n await ensureInitialized(pmRoot);\n const status = normalizeStatus(options.status);\n const limit = parseLimit(options.limit, \"limit\");\n const runs = await listBackgroundTestRuns(pmRoot, { status, limit });\n return {\n runs,\n count: runs.length,\n filters: {\n status,\n limit,\n },\n };\n}\n\n/** Implements run test runs status for the public runtime surface of this module. */\nexport async function runTestRunsStatus(\n runId: string,\n global: GlobalOptions,\n): Promise<{\n run: unknown;\n health: unknown;\n}> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n await ensureInitialized(pmRoot);\n const status = await getBackgroundTestRunStatus(pmRoot, runId);\n return {\n run: status.run,\n health: status.health,\n };\n}\n\n/** Documents the test runs logs command options payload exchanged by command, SDK, and package integrations. */\nexport interface TestRunsLogsCommandOptions {\n /** Value that configures or reports stream for this contract. */\n stream?: string;\n /** Value that configures or reports tail for this contract. */\n tail?: string;\n}\n\n/** Implements run test runs logs for the public runtime surface of this module. */\nexport async function runTestRunsLogs(\n runId: string,\n options: TestRunsLogsCommandOptions,\n global: GlobalOptions,\n): Promise<{\n run: unknown;\n stream: BackgroundLogStream;\n tail: number;\n stdout: string[];\n stderr: string[];\n}> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n await ensureInitialized(pmRoot);\n const stream = normalizeStream(options.stream);\n const tail = parseLimit(options.tail, \"tail\");\n const logs = await readBackgroundTestRunLogs(pmRoot, runId, stream, tail);\n return {\n run: logs.run,\n stream: logs.stream,\n tail: logs.tail,\n stdout: logs.stdout,\n stderr: logs.stderr,\n };\n}\n\n/** Documents the test runs stop command options payload exchanged by command, SDK, and package integrations. */\nexport interface TestRunsStopCommandOptions {\n /** Value that configures or reports force for this contract. */\n force?: boolean;\n}\n\n/** Implements run test runs stop for the public runtime surface of this module. */\nexport async function runTestRunsStop(\n runId: string,\n options: TestRunsStopCommandOptions,\n global: GlobalOptions,\n): Promise<{\n run: unknown;\n signal_sent: \"SIGTERM\" | \"SIGKILL\" | \"none\";\n}> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n await ensureInitialized(pmRoot);\n const stopped = await stopBackgroundTestRun(\n pmRoot,\n runId,\n options.force === true,\n );\n return {\n run: stopped.run,\n signal_sent: stopped.signal_sent,\n };\n}\n\n/** Documents the test runs resume command options payload exchanged by command, SDK, and package integrations. */\nexport interface TestRunsResumeCommandOptions {\n /** Value that configures or reports author for this contract. */\n author?: string;\n /** Value that configures or reports no extensions for this contract. */\n noExtensions?: boolean;\n}\n\n/** Implements run test runs resume for the public runtime surface of this module. */\nexport async function runTestRunsResume(\n runId: string,\n options: TestRunsResumeCommandOptions,\n global: GlobalOptions,\n): Promise<{\n resumed_from: string;\n run: unknown;\n}> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n await ensureInitialized(pmRoot);\n const settings = await readSettings(pmRoot);\n const requestedBy = resolveRequestedBy(\n options.author,\n settings.author_default,\n );\n const resumed = await resumeBackgroundTestRun(\n pmRoot,\n runId,\n requestedBy,\n options.noExtensions === true,\n );\n return {\n resumed_from: runId,\n run: resumed,\n };\n}\n\n/** Implements run test runs worker for the public runtime surface of this module. */\nexport async function runTestRunsWorker(\n runId: string,\n global: GlobalOptions,\n): Promise<{\n id: string;\n status: BackgroundTestRunStatus;\n exit_code?: number;\n}> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n await ensureInitialized(pmRoot);\n const finished = await runBackgroundTestRunWorker(\n pmRoot,\n runId,\n global.noExtensions === true,\n );\n return {\n id: finished.id,\n status: finished.status,\n exit_code: finished.exit_code,\n };\n}\n"],"names":[],"mappings":"AAAA;;;;GAIG;;;AACH,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAE3D,OAAO,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AACzD,OAAO,EAIL,0BAA0B,EAC1B,sBAAsB,EACtB,yBAAyB,EACzB,uBAAuB,EACvB,0BAA0B,EAC1B,4BAA4B,EAC5B,sBAAsB,EACtB,qBAAqB,GACt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AAC;AAED,qFAAqF;AACrF,MAAM,CAAC,KAAK,UAAU,iBAAiB,CACrC,KAAa,EACb,MAAqB;IAMrB,MAAM,MAAM,GAAG,aAAa,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,MAAM,CAAC,IAAI,CAAC,CAAC;IACzD,MAAM,iBAAiB,CAAC,MAAM,CAAC,CAAC;IAChC,MAAM,QAAQ,GAAG,MAAM,0BAA0B,CAC/C,MAAM,EACN,KAAK,EACL,MAAM,CAAC,YAAY,KAAK,IAAI,CAC7B,CAAC;IACF,OAAO;QACL,EAAE,EAAE,QAAQ,CAAC,EAAE;QACf,MAAM,EAAE,QAAQ,CAAC,MAAM;QACvB,SAAS,EAAE,QAAQ,CAAC,SAAS;KAC9B,CAAC;AACJ,CAAC","debugId":"2c42bfb9-c598-5a6e-bfff-0c073bb44205"}
|
package/docs/SDK.md
CHANGED
|
@@ -45,7 +45,21 @@ Source of truth:
|
|
|
45
45
|
- [`src/sdk/governance/validate.ts`](../src/sdk/governance/validate.ts)
|
|
46
46
|
- [`src/sdk/governance/health.ts`](../src/sdk/governance/health.ts)
|
|
47
47
|
- [`src/sdk/governance/gc.ts`](../src/sdk/governance/gc.ts)
|
|
48
|
+
- [`src/sdk/query/list.ts`](../src/sdk/query/list.ts)
|
|
49
|
+
- [`src/sdk/query/search.ts`](../src/sdk/query/search.ts)
|
|
50
|
+
- [`src/sdk/query/search-pagination.ts`](../src/sdk/query/search-pagination.ts)
|
|
51
|
+
- [`src/sdk/query/search-rendering.ts`](../src/sdk/query/search-rendering.ts)
|
|
52
|
+
- [`src/sdk/query/item-filter-options.ts`](../src/sdk/query/item-filter-options.ts)
|
|
53
|
+
- [`src/sdk/query/parsers.ts`](../src/sdk/query/parsers.ts)
|
|
54
|
+
- [`src/sdk/test/execution.ts`](../src/sdk/test/execution.ts)
|
|
55
|
+
- [`src/sdk/test/batch.ts`](../src/sdk/test/batch.ts)
|
|
56
|
+
- [`src/sdk/test/runs.ts`](../src/sdk/test/runs.ts)
|
|
57
|
+
- [`src/sdk/test/parsers.ts`](../src/sdk/test/parsers.ts)
|
|
58
|
+
- [`src/sdk/eval.ts`](../src/sdk/eval.ts)
|
|
59
|
+
- [`src/sdk/telemetry.ts`](../src/sdk/telemetry.ts)
|
|
60
|
+
- [`src/sdk/stats.ts`](../src/sdk/stats.ts)
|
|
48
61
|
- [`src/sdk/cli-contracts.ts`](../src/sdk/cli-contracts.ts)
|
|
62
|
+
- [`src/sdk/cli-bootstrap.ts`](../src/sdk/cli-bootstrap.ts)
|
|
49
63
|
- [`src/sdk/cli-contracts/commander-types.ts`](../src/sdk/cli-contracts/commander-types.ts)
|
|
50
64
|
- [`src/sdk/cli-contracts/commander-mutation-options.ts`](../src/sdk/cli-contracts/commander-mutation-options.ts)
|
|
51
65
|
|
|
@@ -137,6 +151,9 @@ Command/action contract exports:
|
|
|
137
151
|
- Typed governance and maintenance primitives on `PmClient`: `validate`, `health`, `gc`, `historyRedact`, `historyRepair`, `historyRepairAll`, `historyCompact`, and `historyCompactBulk`
|
|
138
152
|
- Governance and maintenance option/result contracts: `ValidateCommandOptions` / `ValidateResult`, `RunHealthOptions` / `HealthResult`, `GcCommandOptions` / `GcResult`, `HistoryRedactCommandOptions` / `HistoryRedactResult`, `HistoryRepairCommandOptions` / `HistoryRepairResult` / `HistoryRepairAllResult`, and `HistoryCompactCommandOptions` / `HistoryCompactResult` / `HistoryCompactBulkCommandOptions` / `HistoryCompactBulkResult`
|
|
139
153
|
- Direct governance engines: `runValidate`, `runHealth`, and `runGc` are public SDK exports used by the CLI compatibility adapters and by custom policy engines that already own `GlobalOptions`. Their structured results are identical to CLI JSON output; no shell process or private core import is required.
|
|
154
|
+
- Execution and diagnostics engines: `runTest`, `runLinkedTests`, `runTestAll`, `runStartBackgroundRun`, `runTestRunsList`, `runTestRunsStatus`, `runTestRunsLogs`, `runTestRunsStop`, `runTestRunsResume`, `runTestRunsWorker`, `runEval`, `runTelemetry`, and `runStats`. Their CLI modules are compatibility re-exports of SDK-owned implementations.
|
|
155
|
+
- Execution and diagnostics contracts: `TestCommandOptions` / `TestResult` / `TestRunResult`, `TestAllCommandOptions` / `TestAllResult`, `StartBackgroundRunCommandOptions` / `StartBackgroundRunResult`, `TestRuns*CommandOptions`, `EvalOptions` / `EvalResult`, `TelemetryCommandOptions` / `TelemetrySubcommand`, and `StatsCommandOptions` / `StatsResult`.
|
|
156
|
+
- Linked-test authoring primitives: `parseLinkedTestJsonEntries`, the `parseLinkedTest*` field parsers, `LINKED_TEST_PM_CONTEXT_MODE_VALUES`, `LINKED_TEST_PROTECTED_ENV_KEYS`, `classifyLinkedTestFailure`, `countFailureCategories`, and `summarizeContextPreflight` let custom hosts validate, execute, classify, and report linked tests without duplicating CLI policy.
|
|
140
157
|
- Typed plan workflow primitives on `PmClient`: `plan`, `planCreate`, `planShow`, `planAddStep`, `planUpdateStep`, `planCompleteStep`, `planBlockStep`, `planReorderStep`, `planRemoveStep`, `planLink`, `planUnlink`, `planDecision`, `planDiscovery`, `planValidation`, `planResume`, `planApprove`, and `planMaterialize`
|
|
141
158
|
- Plan contracts: `PlanSubcommand`, `PlanCommandOptions`, `PlanCommandResult`, `PlanResultPlan`, `PlanStepSummary`, `PlanShowDepth`, and `PlanTemplateName`
|
|
142
159
|
- Typed package and extension lifecycle primitives on `PmClient`: `extension`, `extensionList`, `extensionActivate`, `extensionDeactivate`, `package`, `packageList`, `packageInstall`, `packageUninstall`, `packageDoctor`, `packageManage`, `packageDescribe`, `packageReload`, `packageCatalog`, `packageActivate`, `packageDeactivate`, and `upgrade`
|
|
@@ -147,6 +164,29 @@ Command/action contract exports:
|
|
|
147
164
|
- `PM_PROVIDER_TOOL_PARAMETERS_SCHEMA`
|
|
148
165
|
- `PM_TOOL_ACTION_PARAMETER_CONTRACTS`
|
|
149
166
|
|
|
167
|
+
### Build an entire custom project tool
|
|
168
|
+
|
|
169
|
+
The [SDK-only custom-tool exemplar](examples/sdk-custom-tool/README.md)
|
|
170
|
+
is the acceptance reference for applications that use pm as a universal
|
|
171
|
+
context engine rather than as an extension host. It imports only
|
|
172
|
+
`@unbrained/pm-cli/sdk` and composes schema customization, custom workflow
|
|
173
|
+
statuses, lifecycle mutations, annotations, linked resources, dependency
|
|
174
|
+
graphs, bounded context, search, health, and validation into a standalone
|
|
175
|
+
domain CLI.
|
|
176
|
+
|
|
177
|
+
Copy its reusable client pattern when building a company workflow,
|
|
178
|
+
domain-specific tracker, VCS-like system, or other application whose durable
|
|
179
|
+
state and business rules fit pm's public primitives. Keep the executable layer
|
|
180
|
+
thin: domain logic belongs in a reusable SDK client, while argv parsing and
|
|
181
|
+
rendering stay at the edge.
|
|
182
|
+
|
|
183
|
+
Embedded hosts can also import the SDK-owned bootstrap normalization primitives
|
|
184
|
+
(`normalizeBootstrapInvocation`, `parseBootstrapGlobalOptions`, and related
|
|
185
|
+
contracts) when they intentionally expose pm-compatible argv. Every
|
|
186
|
+
`runPmCli()` call constructs a fresh Commander graph, so extension commands,
|
|
187
|
+
extension flags, and runtime schema options from one workspace cannot leak into
|
|
188
|
+
the next in-process invocation.
|
|
189
|
+
|
|
150
190
|
### Plan workflows
|
|
151
191
|
|
|
152
192
|
Custom tools can manage durable plans without shelling out or importing CLI internals. The typed façade uses the same engine and result envelopes as `pm plan` and MCP `pm_plan`:
|
|
@@ -785,6 +825,87 @@ the same bounded maintenance engine as the CLI. Prefer these typed calls over
|
|
|
785
825
|
shelling out when building CI, editor integrations, or long-running agent
|
|
786
826
|
runtimes.
|
|
787
827
|
|
|
828
|
+
### Query execution
|
|
829
|
+
|
|
830
|
+
Tracked by [pm-rjqr](../.agents/pm/features/pm-rjqr.toon) and the SDK boundary
|
|
831
|
+
capstone [pm-9x6e](../.agents/pm/tasks/pm-9x6e.toon).
|
|
832
|
+
|
|
833
|
+
`runList` and `runSearch` are SDK-owned query engines, including filtering,
|
|
834
|
+
projection, pagination, keyword and semantic ranking, extension-provider
|
|
835
|
+
dispatch, and token-efficient response metadata. Their historical CLI module
|
|
836
|
+
paths are identity-preserving compatibility exports, while `runEval` consumes
|
|
837
|
+
the SDK search engine directly. Package authors can import these functions and
|
|
838
|
+
their typed result contracts from `@unbrained/pm-cli/sdk` without importing CLI
|
|
839
|
+
implementation modules.
|
|
840
|
+
|
|
841
|
+
List result rows are modeled by projection: `ListFullResult` contains complete
|
|
842
|
+
`ListedItem` records, tree ordering may enrich them with `ListTreeMetadata`, and
|
|
843
|
+
compact or `fields` projections return `ListProjectedItem` dictionaries. Use
|
|
844
|
+
`full: true` when an integration requires complete item metadata; the overload
|
|
845
|
+
then returns `ListFullResult` without an assertion or cast.
|
|
846
|
+
|
|
847
|
+
### Execution and diagnostics
|
|
848
|
+
|
|
849
|
+
Tracked by [pm-oslr](../.agents/pm/features/pm-oslr.toon) and the SDK boundary
|
|
850
|
+
capstone [pm-9x6e](../.agents/pm/tasks/pm-9x6e.toon).
|
|
851
|
+
|
|
852
|
+
Test execution, background-run supervision, search evaluation, telemetry
|
|
853
|
+
inspection, and tracker statistics are SDK-owned primitives. A custom CI host or
|
|
854
|
+
project-specific tool can compose the same sandboxing, context-preflight,
|
|
855
|
+
deduplication, failure classification, progress, consent, and structured-result
|
|
856
|
+
behavior as the CLI without spawning `pm` or importing `src/core` modules:
|
|
857
|
+
|
|
858
|
+
```ts
|
|
859
|
+
import {
|
|
860
|
+
runEval,
|
|
861
|
+
runTelemetry,
|
|
862
|
+
runTest,
|
|
863
|
+
runTestAll,
|
|
864
|
+
runTestRunsStatus,
|
|
865
|
+
type GlobalOptions,
|
|
866
|
+
} from "@unbrained/pm-cli/sdk";
|
|
867
|
+
|
|
868
|
+
const pmRoot = "/path/to/project/.agents/pm";
|
|
869
|
+
const itemId = "pm-example";
|
|
870
|
+
const runId = "test-run-example";
|
|
871
|
+
const global: GlobalOptions = { path: pmRoot };
|
|
872
|
+
|
|
873
|
+
const itemRun = await runTest(
|
|
874
|
+
itemId,
|
|
875
|
+
{
|
|
876
|
+
run: true,
|
|
877
|
+
autoPmContext: true,
|
|
878
|
+
checkContext: true,
|
|
879
|
+
failOnEmptyTestRun: true,
|
|
880
|
+
},
|
|
881
|
+
global,
|
|
882
|
+
);
|
|
883
|
+
|
|
884
|
+
const workspaceRun = await runTestAll(
|
|
885
|
+
{ status: "open", autoPmContext: true, failOnSkipped: true },
|
|
886
|
+
global,
|
|
887
|
+
);
|
|
888
|
+
const background = await runTestRunsStatus(runId, global);
|
|
889
|
+
const relevance = await runEval({ mode: "keyword", k: 10 }, global);
|
|
890
|
+
const telemetry = await runTelemetry(
|
|
891
|
+
{ subcommand: "stats", limit: 20 },
|
|
892
|
+
global,
|
|
893
|
+
);
|
|
894
|
+
```
|
|
895
|
+
|
|
896
|
+
`runTest` and `runTestAll` always execute linked commands in isolated project and
|
|
897
|
+
global tracker roots. `pm_context_mode`, run-level overrides, automatic tracker
|
|
898
|
+
context, assertion requirements, empty-run detection, and failure categories are
|
|
899
|
+
part of the SDK result contract rather than presentation-layer behavior.
|
|
900
|
+
Background-run helpers return durable records and health/log projections; the
|
|
901
|
+
host remains responsible for its own rendering and exit-code policy.
|
|
902
|
+
|
|
903
|
+
`runTelemetry` retains consent and storage ownership inside the primitive:
|
|
904
|
+
`status` and `stats` are observational, `flush` uses the consent-aware queue
|
|
905
|
+
runtime, and `clear` disables telemetry and removes runtime artifacts. `runEval`
|
|
906
|
+
uses the same live search path and unrounded gate decision as `pm eval`, returning
|
|
907
|
+
compact rounded report metrics for stable machine output.
|
|
908
|
+
|
|
788
909
|
### Context relevance and evaluation
|
|
789
910
|
|
|
790
911
|
Tracked by [pm-4k6b](../.agents/pm/features/pm-4k6b.toon),
|
|
@@ -2226,6 +2347,7 @@ search degrades gracefully and emits warning codes instead of hard-failing.
|
|
|
2226
2347
|
|
|
2227
2348
|
Runnable examples:
|
|
2228
2349
|
|
|
2350
|
+
- [SDK-only custom project tool](examples/sdk-custom-tool/README.md)
|
|
2229
2351
|
- [SDK contract consumer](examples/sdk-contract-consumer/README.md)
|
|
2230
2352
|
- [SDK app embedding](examples/sdk-app-embedding/README.md)
|
|
2231
2353
|
- [CI examples](examples/ci/)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# SDK Primitive Inventory
|
|
2
2
|
|
|
3
|
-
Tracked work: [pm-lodl](../.agents/pm/tasks/pm-lodl.toon), [pm-8778](../.agents/pm/tasks/pm-8778.toon), parent [pm-usfg](../.agents/pm/epics/pm-usfg.toon).
|
|
3
|
+
Tracked work: [pm-lodl](../.agents/pm/tasks/pm-lodl.toon), [pm-8778](../.agents/pm/tasks/pm-8778.toon), [pm-rjqr](../.agents/pm/features/pm-rjqr.toon), [pm-oslr](../.agents/pm/features/pm-oslr.toon), capstone [pm-9x6e](../.agents/pm/tasks/pm-9x6e.toon), parent [pm-usfg](../.agents/pm/epics/pm-usfg.toon).
|
|
4
4
|
|
|
5
5
|
This inventory is the current SDK-first migration map for the principle `project management = context management`.
|
|
6
6
|
The exact per-source CLI/MCP module inventory is checked in at [`scripts/release/sdk-import-boundary-baseline.json`](../scripts/release/sdk-import-boundary-baseline.json): each `allowed_private_core_imports[]` entry names one command, helper, or MCP source file and the private `src/core` modules it currently imports. The static quality gate reads that file and fails when `src/cli` or `src/mcp` adds a new private `src/core` import, uses a computed dynamic `import()` that cannot be ratcheted, or leaves a stale baseline entry after an import has been removed.
|
|
@@ -9,6 +9,7 @@ The exact per-source CLI/MCP module inventory is checked in at [`scripts/release
|
|
|
9
9
|
|
|
10
10
|
- Boundary scope: `src/cli.ts`, `src/cli/**`, `src/mcp.ts`, and `src/mcp/**`.
|
|
11
11
|
- Current scan size and private-edge counts are derived from [`scripts/release/sdk-import-boundary-baseline.json`](../scripts/release/sdk-import-boundary-baseline.json) and the `pnpm quality:static` ratchet output.
|
|
12
|
+
- Current enforced baseline after the query/execution bundle: 51 CLI/MCP source modules and 412 private-core import edges, down from 62 sources and 538 edges at the start of the bundle.
|
|
12
13
|
- Type-only imports and re-exports are intentionally counted because they still expose presentation layers to private core contracts.
|
|
13
14
|
- Baseline owner: [pm-8778](../.agents/pm/tasks/pm-8778.toon).
|
|
14
15
|
- Ratchet rule: SDK promotion PRs must shrink the baseline when they move a primitive behind `src/sdk`; no PR may grow it.
|
|
@@ -36,12 +37,13 @@ Use [`scripts/release/sdk-import-boundary-baseline.json`](../scripts/release/sdk
|
|
|
36
37
|
| --- | --- | --- |
|
|
37
38
|
| `create`, `update`, `update-many`, `copy`, `delete`, `restore` | [pm-98cz](../.agents/pm/features/pm-98cz.toon) | Item CRUD and replay paths should become typed lifecycle SDK calls. |
|
|
38
39
|
| `claim`, `release`, `focus`, lifecycle shortcut helpers | [pm-98cz](../.agents/pm/features/pm-98cz.toon) | Ownership and actionable-state changes belong beside lifecycle primitives. |
|
|
39
|
-
| `list`, `get`, `search`, `context`, `next`, `aggregate`, `stats` | [pm-rjqr](../.agents/pm/features/pm-rjqr.toon) |
|
|
40
|
+
| `list`, `get`, `search`, `context`, `next`, `aggregate`, `stats` | [pm-rjqr](../.agents/pm/features/pm-rjqr.toon) | `list` and `search` implementations now live under `src/sdk/query/**`; remaining read models should follow the same SDK-owned pattern. |
|
|
40
41
|
| `comments`, `notes`, `learnings`, `files`, `docs`, `deps`, `append` | [pm-zwpp](../.agents/pm/features/pm-zwpp.toon) | Annotation/link mutation semantics must be stable SDK primitives. |
|
|
41
42
|
| `schema`, `config`, `profile`, `init`, `init-agent-guidance` | [pm-3mna](../.agents/pm/features/pm-3mna.toon) | Universal customization requires programmatic schema, profile, and config APIs. |
|
|
42
43
|
| `history`, `activity`, `history-redact`, `history-repair`, `history-compact` | [pm-4a7m](../.agents/pm/features/pm-4a7m.toon) | Audited history read, activity, rewrite, and checkpoint operations need explicit public contracts. |
|
|
43
44
|
| `plan` | [pm-je50](../.agents/pm/features/pm-je50.toon) | Plan harness operations should be usable by external orchestrators through SDK calls. |
|
|
44
|
-
| `test`, `test-all`, `test-runs`, `eval`, `telemetry`, `
|
|
45
|
+
| `test`, `test-all`, `test-runs`, `eval`, `telemetry`, `stats` | [pm-oslr](../.agents/pm/features/pm-oslr.toon) | Implementations live under `src/sdk/test/**`, `src/sdk/eval.ts`, `src/sdk/telemetry.ts`, and `src/sdk/stats.ts`; CLI paths are compatibility exports with typed structured results. |
|
|
46
|
+
| `reindex` | [pm-rjqr](../.agents/pm/features/pm-rjqr.toon) / [pm-9x6e](../.agents/pm/tasks/pm-9x6e.toon) | Search-index refresh remains part of the query/read ownership and terminal boundary burn-down. |
|
|
45
47
|
| `extension`, `upgrade`, package lifecycle helpers | [pm-ugqx](../.agents/pm/epics/pm-ugqx.toon) | Existing package-author SDK surfaces stay public; package lifecycle can move behind SDK runtime helpers. |
|
|
46
48
|
| `src/mcp/**` | [pm-usfg](../.agents/pm/epics/pm-usfg.toon) | MCP tools should call SDK primitives directly once each family is promoted. |
|
|
47
49
|
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# SDK-only custom project tool
|
|
2
|
+
|
|
3
|
+
Tracked by [pm-cbwg](../../../.agents/pm/features/pm-cbwg.toon) and
|
|
4
|
+
[pm-w89s](../../../.agents/pm/stories/pm-w89s.toon).
|
|
5
|
+
|
|
6
|
+
This package is the end-to-end acceptance proof for pm's universal-tool goal.
|
|
7
|
+
It is a standalone domain CLI, not an extension: its implementation imports
|
|
8
|
+
only `@unbrained/pm-cli/sdk` and composes customization, lifecycle, query,
|
|
9
|
+
context, annotation, linked-resource, relationship, and governance primitives.
|
|
10
|
+
|
|
11
|
+
Run the acceptance suite, including the executable adapter contract, against
|
|
12
|
+
fresh temporary workspaces:
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
node scripts/run-tests.mjs test -- tests/unit/sdk/sdk-universal-tool-exemplar.spec.ts
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
The `pm-custom` flow registers a `Deliverable` type and `reviewing` status,
|
|
19
|
+
creates a related parent/child graph, records comments/notes/learnings, links
|
|
20
|
+
workspace evidence, reads list/search/context/dependency projections, closes
|
|
21
|
+
the work with resolution evidence, and returns health/history verification as
|
|
22
|
+
structured JSON. It never imports `src/core`, `src/cli`, or spawns `pm`.
|
|
23
|
+
|
|
24
|
+
Use [src/index.ts](src/index.ts) as the copyable library pattern and
|
|
25
|
+
[src/cli.ts](src/cli.ts) as the process-independent executable adapter. The
|
|
26
|
+
package maps `pm-custom` to [src/entry.ts](src/entry.ts), which wires that
|
|
27
|
+
adapter to Node.js arguments, author identity, output streams, and exit status.
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@unbrained/pm-sdk-custom-tool",
|
|
3
|
+
"version": "2026.7.16",
|
|
4
|
+
"private": true,
|
|
5
|
+
"type": "module",
|
|
6
|
+
"description": "SDK-only exemplar for building a complete custom project-management tool on pm primitives.",
|
|
7
|
+
"bin": {
|
|
8
|
+
"pm-custom": "src/entry.ts"
|
|
9
|
+
},
|
|
10
|
+
"peerDependencies": {
|
|
11
|
+
"@unbrained/pm-cli": ">=2026.7.16"
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module docs/examples/sdk-custom-tool/cli
|
|
3
|
+
*
|
|
4
|
+
* Runs the SDK-only exemplar as a small domain CLI.
|
|
5
|
+
*/
|
|
6
|
+
import {
|
|
7
|
+
runUniversalToolScenario,
|
|
8
|
+
type UniversalToolScenarioOptions,
|
|
9
|
+
type UniversalToolScenarioResult,
|
|
10
|
+
} from "./index.ts";
|
|
11
|
+
|
|
12
|
+
/** Scenario boundary accepted by the executable adapter. */
|
|
13
|
+
export type UniversalToolScenarioRunner = (
|
|
14
|
+
options: UniversalToolScenarioOptions,
|
|
15
|
+
) => Promise<UniversalToolScenarioResult>;
|
|
16
|
+
|
|
17
|
+
/** Run the exemplar CLI against process-independent argument and I/O ports. */
|
|
18
|
+
export async function runUniversalToolCli(
|
|
19
|
+
args: string[],
|
|
20
|
+
author: string | undefined,
|
|
21
|
+
writeOutput: (value: string) => void,
|
|
22
|
+
writeError: (value: string) => void,
|
|
23
|
+
runScenario: UniversalToolScenarioRunner = runUniversalToolScenario,
|
|
24
|
+
): Promise<number> {
|
|
25
|
+
const workspace = args[0];
|
|
26
|
+
if (!workspace) {
|
|
27
|
+
writeError("Usage: pm-custom <workspace>\n");
|
|
28
|
+
return 2;
|
|
29
|
+
}
|
|
30
|
+
const result = await runScenario({
|
|
31
|
+
workspace,
|
|
32
|
+
author: author ?? "pm-sdk-custom-tool",
|
|
33
|
+
});
|
|
34
|
+
writeOutput(`${JSON.stringify(result, null, 2)}\n`);
|
|
35
|
+
return 0;
|
|
36
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* @module docs/examples/sdk-custom-tool/entry
|
|
4
|
+
*
|
|
5
|
+
* Connects the process-independent SDK exemplar adapter to Node.js process
|
|
6
|
+
* arguments, author identity, output streams, and exit status.
|
|
7
|
+
*/
|
|
8
|
+
import { runUniversalToolCli } from "./cli.ts";
|
|
9
|
+
|
|
10
|
+
process.exitCode = await runUniversalToolCli(
|
|
11
|
+
process.argv.slice(2),
|
|
12
|
+
process.env.PM_AUTHOR,
|
|
13
|
+
(value) => process.stdout.write(value),
|
|
14
|
+
(value) => process.stderr.write(value),
|
|
15
|
+
);
|