@unbrained/pm-cli 2026.7.11 → 2026.7.12

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.
Files changed (436) hide show
  1. package/.claude-plugin/marketplace.json +2 -2
  2. package/CHANGELOG.md +36 -2
  3. package/README.md +0 -33
  4. package/dist/cli/commands/claim.d.ts +32 -1
  5. package/dist/cli/commands/claim.js +52 -15
  6. package/dist/cli/commands/claim.js.map +1 -1
  7. package/dist/cli/commands/completion.js +11 -2
  8. package/dist/cli/commands/completion.js.map +1 -1
  9. package/dist/cli/commands/create.js +4 -65
  10. package/dist/cli/commands/create.js.map +1 -1
  11. package/dist/cli/commands/index.d.ts +1 -1
  12. package/dist/cli/commands/index.js +3 -3
  13. package/dist/cli/commands/index.js.map +1 -1
  14. package/dist/cli/commands/init.js +18 -2
  15. package/dist/cli/commands/init.js.map +1 -1
  16. package/dist/cli/commands/legacy-none-tokens.d.ts +49 -1
  17. package/dist/cli/commands/legacy-none-tokens.js +73 -2
  18. package/dist/cli/commands/legacy-none-tokens.js.map +1 -1
  19. package/dist/cli/commands/next.d.ts +14 -2
  20. package/dist/cli/commands/next.js +39 -11
  21. package/dist/cli/commands/next.js.map +1 -1
  22. package/dist/cli/commands/plan.d.ts +5 -0
  23. package/dist/cli/commands/plan.js +44 -2
  24. package/dist/cli/commands/plan.js.map +1 -1
  25. package/dist/cli/commands/update.js +7 -67
  26. package/dist/cli/commands/update.js.map +1 -1
  27. package/dist/cli/extension-command-help.d.ts +13 -1
  28. package/dist/cli/extension-command-help.js +79 -5
  29. package/dist/cli/extension-command-help.js.map +1 -1
  30. package/dist/cli/main.js +9 -6
  31. package/dist/cli/main.js.map +1 -1
  32. package/dist/cli/register-list-query.js +3 -2
  33. package/dist/cli/register-list-query.js.map +1 -1
  34. package/dist/cli/register-mutation.js +3 -2
  35. package/dist/cli/register-mutation.js.map +1 -1
  36. package/dist/cli/register-operations.js +24 -3
  37. package/dist/cli/register-operations.js.map +1 -1
  38. package/dist/cli-bundle/chunks/append-RH3G5RAV.js +11 -0
  39. package/dist/cli-bundle/chunks/{append-464PHZ65.js → append-T5DTS4NU.js} +5 -5
  40. package/dist/cli-bundle/chunks/{chunk-YMP6AKGU.js → chunk-2XWRFOPR.js} +3 -3
  41. package/dist/cli-bundle/chunks/{chunk-HT5P3WC6.js → chunk-2Z36LSAT.js} +6 -6
  42. package/dist/cli-bundle/chunks/{chunk-WQ5227PH.js → chunk-33O5P6KT.js} +135 -41
  43. package/dist/cli-bundle/chunks/chunk-33O5P6KT.js.map +7 -0
  44. package/dist/cli-bundle/chunks/{chunk-DBV6QRYT.js → chunk-3KJ3FG5O.js} +3 -3
  45. package/dist/cli-bundle/chunks/{chunk-AQLKMQQA.js → chunk-3M5BWYUA.js} +3 -3
  46. package/dist/cli-bundle/chunks/{chunk-GPBKJERW.js → chunk-3WASQS5G.js} +42 -6
  47. package/dist/cli-bundle/chunks/chunk-3WASQS5G.js.map +1 -0
  48. package/dist/cli-bundle/chunks/{chunk-47CCRGRH.js → chunk-47TKJR3D.js} +4 -4
  49. package/dist/cli-bundle/chunks/{chunk-YCSDMIQW.js → chunk-4MO4PPR2.js} +4 -4
  50. package/dist/cli-bundle/chunks/{chunk-WCRAUCJO.js → chunk-546WPG33.js} +5 -5
  51. package/dist/cli-bundle/chunks/{chunk-RLOWK5EQ.js → chunk-5754C5XS.js} +3 -3
  52. package/dist/cli-bundle/chunks/{chunk-7U5INZ2C.js → chunk-5V746BN3.js} +2 -2
  53. package/dist/cli-bundle/chunks/{chunk-7324AI5M.js → chunk-66YL6RR5.js} +30 -20
  54. package/dist/cli-bundle/chunks/{chunk-7324AI5M.js.map → chunk-66YL6RR5.js.map} +2 -2
  55. package/dist/cli-bundle/chunks/{chunk-ZLQDOBZL.js → chunk-6OK5QSGH.js} +4 -4
  56. package/dist/cli-bundle/chunks/{chunk-ROH64TST.js → chunk-6XNMSLBT.js} +78 -72
  57. package/dist/cli-bundle/chunks/chunk-6XNMSLBT.js.map +1 -0
  58. package/dist/cli-bundle/chunks/{chunk-2HNZKLHV.js → chunk-7SHFQB2A.js} +4 -4
  59. package/dist/cli-bundle/chunks/{chunk-6APTSPP5.js → chunk-7SIWW7C3.js} +4 -4
  60. package/dist/cli-bundle/chunks/{chunk-7HQQT6AT.js → chunk-7TYZTBEV.js} +3 -3
  61. package/dist/cli-bundle/chunks/{chunk-VTOQH22Y.js → chunk-A2HZUSEA.js} +8 -6
  62. package/dist/cli-bundle/chunks/{chunk-VTOQH22Y.js.map → chunk-A2HZUSEA.js.map} +1 -1
  63. package/dist/cli-bundle/chunks/{chunk-YCHJLOO2.js → chunk-A6AK7W5M.js} +2 -2
  64. package/dist/cli-bundle/chunks/{chunk-WBKZAO3P.js → chunk-A6AVSYRJ.js} +5 -5
  65. package/dist/cli-bundle/chunks/{chunk-L7C6RTGH.js → chunk-ACDIA6NP.js} +5 -5
  66. package/dist/cli-bundle/chunks/{chunk-AX3BJLPV.js → chunk-ACRC3HI4.js} +2 -2
  67. package/dist/cli-bundle/chunks/{chunk-QCKPSFII.js → chunk-AHIEDSW2.js} +30 -20
  68. package/dist/cli-bundle/chunks/{chunk-QCKPSFII.js.map → chunk-AHIEDSW2.js.map} +1 -1
  69. package/dist/cli-bundle/chunks/{chunk-B6JBI7JX.js → chunk-ANLHBXAE.js} +5 -5
  70. package/dist/cli-bundle/chunks/{chunk-2KQG6L3J.js → chunk-AS62PEJE.js} +4 -4
  71. package/dist/cli-bundle/chunks/{chunk-OJ64VYGO.js → chunk-BAK2VLTQ.js} +62 -33
  72. package/dist/cli-bundle/chunks/chunk-BAK2VLTQ.js.map +1 -0
  73. package/dist/cli-bundle/chunks/{chunk-J3EXRK2H.js → chunk-BLRO2POO.js} +3 -3
  74. package/dist/cli-bundle/chunks/{chunk-KDNZSVCK.js → chunk-CDR2A3VI.js} +15 -74
  75. package/dist/cli-bundle/chunks/chunk-CDR2A3VI.js.map +1 -0
  76. package/dist/cli-bundle/chunks/{chunk-2WGV5WRW.js → chunk-DJI5IS46.js} +42 -20
  77. package/dist/cli-bundle/chunks/{chunk-2WGV5WRW.js.map → chunk-DJI5IS46.js.map} +1 -1
  78. package/dist/cli-bundle/chunks/{chunk-VOXOXART.js → chunk-DLZ3RXAL.js} +5 -5
  79. package/dist/cli-bundle/chunks/{chunk-H6YDNW46.js → chunk-DNH44IKP.js} +4 -4
  80. package/dist/cli-bundle/chunks/{chunk-QI5KTH6A.js → chunk-EBBROE54.js} +9 -9
  81. package/dist/cli-bundle/chunks/{chunk-GC5ME4ZU.js → chunk-FF523THY.js} +4 -4
  82. package/dist/cli-bundle/chunks/{chunk-5OBMSBWX.js → chunk-FIZUJWXQ.js} +3 -3
  83. package/dist/cli-bundle/chunks/{chunk-HLBSL5KE.js → chunk-FVWQFTTW.js} +6 -6
  84. package/dist/cli-bundle/chunks/{chunk-YIWYD7TC.js → chunk-FVZEIWTL.js} +10 -10
  85. package/dist/cli-bundle/chunks/{chunk-E72ZO34Z.js → chunk-G6B5XGNV.js} +97 -32
  86. package/dist/cli-bundle/chunks/{chunk-E72ZO34Z.js.map → chunk-G6B5XGNV.js.map} +4 -4
  87. package/dist/cli-bundle/chunks/{chunk-4DC5XNMS.js → chunk-GFBV2254.js} +5 -5
  88. package/dist/cli-bundle/chunks/{chunk-OKZ35F3Y.js → chunk-GRB3TFOC.js} +3 -3
  89. package/dist/cli-bundle/chunks/{chunk-TZFULSN4.js → chunk-GVGFLZQS.js} +4 -4
  90. package/dist/cli-bundle/chunks/{chunk-RTG2LHQ7.js → chunk-HLZXQKGZ.js} +2 -2
  91. package/dist/cli-bundle/chunks/{chunk-5F7UJHFY.js → chunk-HO6CDURZ.js} +2 -2
  92. package/dist/cli-bundle/chunks/{chunk-MN2YMU55.js → chunk-HOE3UV3G.js} +3 -3
  93. package/dist/cli-bundle/chunks/{chunk-XQLLRYOX.js → chunk-HRCJGQXL.js} +134 -40
  94. package/dist/cli-bundle/chunks/chunk-HRCJGQXL.js.map +1 -0
  95. package/dist/cli-bundle/chunks/{chunk-I535LTZ2.js → chunk-IS6M4ETF.js} +4 -4
  96. package/dist/cli-bundle/chunks/{chunk-K7HEURQ4.js → chunk-J2XEW4YL.js} +3 -3
  97. package/dist/cli-bundle/chunks/{chunk-GZNB5V5J.js → chunk-J2ZDZG4A.js} +44 -12
  98. package/dist/cli-bundle/chunks/chunk-J2ZDZG4A.js.map +7 -0
  99. package/dist/cli-bundle/chunks/{chunk-O2Q7YQGO.js → chunk-J7XSQCJO.js} +4 -4
  100. package/dist/cli-bundle/chunks/{chunk-RA2LPP6E.js → chunk-JM4Z53DN.js} +2 -2
  101. package/dist/cli-bundle/chunks/{chunk-JR6FIX53.js → chunk-JNNPTGXR.js} +3 -3
  102. package/dist/cli-bundle/chunks/{chunk-I5VZGPS2.js → chunk-K7CGOZK5.js} +6 -6
  103. package/dist/cli-bundle/chunks/{chunk-B6OANV3G.js → chunk-KDH62ECD.js} +4 -4
  104. package/dist/cli-bundle/chunks/{chunk-LIY2ILWI.js → chunk-KXFY6AI4.js} +41 -5
  105. package/dist/cli-bundle/chunks/chunk-KXFY6AI4.js.map +7 -0
  106. package/dist/cli-bundle/chunks/{chunk-NR7PTIR7.js → chunk-L23NAJHL.js} +2 -2
  107. package/dist/cli-bundle/chunks/{chunk-FCZ6WYSR.js → chunk-LEXFDABF.js} +2 -2
  108. package/dist/cli-bundle/chunks/{chunk-GP54I36Z.js → chunk-LNAGQRIL.js} +2 -2
  109. package/dist/cli-bundle/chunks/{chunk-DD2WZD6L.js → chunk-LU4Z7POS.js} +3 -3
  110. package/dist/cli-bundle/chunks/{chunk-FEVEIX53.js → chunk-LX265XY7.js} +6 -6
  111. package/dist/cli-bundle/chunks/{chunk-NJABR6EB.js → chunk-MQAGSAMS.js} +4 -4
  112. package/dist/cli-bundle/chunks/{chunk-MRMS62WQ.js → chunk-N4NKVLPY.js} +4 -4
  113. package/dist/cli-bundle/chunks/{chunk-RY57ESL2.js → chunk-ND3MDD6L.js} +9 -9
  114. package/dist/cli-bundle/chunks/{chunk-Y476SA4V.js → chunk-NEJKKTCG.js} +2 -2
  115. package/dist/cli-bundle/chunks/{chunk-Q3EW4RE5.js → chunk-NGL3X3XM.js} +3 -3
  116. package/dist/cli-bundle/chunks/{chunk-ENJDRDDP.js → chunk-NK54BSL7.js} +8 -8
  117. package/dist/cli-bundle/chunks/{chunk-KHQYX2QB.js → chunk-NN57FRRN.js} +3 -3
  118. package/dist/cli-bundle/chunks/{chunk-VNCQ7SSG.js → chunk-NNRXTZ7Y.js} +4 -4
  119. package/dist/cli-bundle/chunks/{chunk-KZQHMDS6.js → chunk-NOIIRLCO.js} +2 -2
  120. package/dist/cli-bundle/chunks/{chunk-CTAPVM6C.js → chunk-O5ELBOEJ.js} +14 -73
  121. package/dist/cli-bundle/chunks/chunk-O5ELBOEJ.js.map +7 -0
  122. package/dist/cli-bundle/chunks/{chunk-K2PDZYUF.js → chunk-OC2CLNMS.js} +2 -2
  123. package/dist/cli-bundle/chunks/{chunk-SN7Q7M4U.js → chunk-OKUFGORG.js} +2 -2
  124. package/dist/cli-bundle/chunks/{chunk-ZLWBLI5R.js → chunk-OOK6V7BF.js} +3 -3
  125. package/dist/cli-bundle/chunks/{chunk-DDEYJ3BH.js → chunk-OUQ4I6HC.js} +3 -3
  126. package/dist/cli-bundle/chunks/{chunk-C4FIA5U6.js → chunk-OYCZDDUC.js} +61 -32
  127. package/dist/cli-bundle/chunks/chunk-OYCZDDUC.js.map +7 -0
  128. package/dist/cli-bundle/chunks/{chunk-X7ZXLB3C.js → chunk-PDOJRPYR.js} +7 -7
  129. package/dist/cli-bundle/chunks/{chunk-HDNEQAHV.js → chunk-PHQPQNAT.js} +4 -4
  130. package/dist/cli-bundle/chunks/{chunk-FMFSUTTD.js → chunk-PTJ7NVUU.js} +4 -4
  131. package/dist/cli-bundle/chunks/{chunk-5URFS7C4.js → chunk-PUMGO764.js} +7 -7
  132. package/dist/cli-bundle/chunks/{chunk-RPZ57GQ7.js → chunk-QFCCN4JO.js} +2 -2
  133. package/dist/cli-bundle/chunks/{chunk-RAC2UXLT.js → chunk-QPWXNK56.js} +43 -11
  134. package/dist/cli-bundle/chunks/chunk-QPWXNK56.js.map +1 -0
  135. package/dist/cli-bundle/chunks/{chunk-35YNX7RQ.js → chunk-QYIDXRRX.js} +7 -7
  136. package/dist/cli-bundle/chunks/{chunk-ITIUEWD5.js → chunk-RFDT674H.js} +4 -4
  137. package/dist/cli-bundle/chunks/{chunk-2BUNV627.js → chunk-SJ2DADDH.js} +8 -8
  138. package/dist/cli-bundle/chunks/{chunk-MSPZSUKQ.js → chunk-SV7PEWKW.js} +41 -19
  139. package/dist/cli-bundle/chunks/{chunk-MSPZSUKQ.js.map → chunk-SV7PEWKW.js.map} +2 -2
  140. package/dist/cli-bundle/chunks/{chunk-ZYDUOY54.js → chunk-TKD4NESJ.js} +3 -3
  141. package/dist/cli-bundle/chunks/{chunk-BU2CV5ZU.js → chunk-TMNQV4EK.js} +2 -2
  142. package/dist/cli-bundle/chunks/{chunk-GJNBKU6G.js → chunk-TWELUDDF.js} +2 -2
  143. package/dist/cli-bundle/chunks/{chunk-A3AIKEYC.js → chunk-TYCM65DJ.js} +78 -72
  144. package/dist/cli-bundle/chunks/chunk-TYCM65DJ.js.map +7 -0
  145. package/dist/cli-bundle/chunks/{chunk-Y5E6FCAL.js → chunk-U3S22BOJ.js} +4 -4
  146. package/dist/cli-bundle/chunks/{chunk-MORRAQXQ.js → chunk-UAZ6W3H3.js} +91 -33
  147. package/dist/cli-bundle/chunks/chunk-UAZ6W3H3.js.map +1 -0
  148. package/dist/cli-bundle/chunks/{chunk-2BKRMFGK.js → chunk-UFY4ETU6.js} +3 -3
  149. package/dist/cli-bundle/chunks/{chunk-EEUIIDWF.js → chunk-UGQENMKM.js} +2 -2
  150. package/dist/cli-bundle/chunks/{chunk-XK5CTXMB.js → chunk-UGSHP6SR.js} +4 -4
  151. package/dist/cli-bundle/chunks/{chunk-2JWIRG4V.js → chunk-VF24O6TV.js} +4 -4
  152. package/dist/cli-bundle/chunks/{chunk-PZBRTJ3Y.js → chunk-VLVTXEGG.js} +4 -4
  153. package/dist/cli-bundle/chunks/{chunk-X6HT3FP3.js → chunk-VMGK6ESD.js} +7 -5
  154. package/dist/cli-bundle/chunks/{chunk-X6HT3FP3.js.map → chunk-VMGK6ESD.js.map} +2 -2
  155. package/dist/cli-bundle/chunks/{chunk-NAGOH4YJ.js → chunk-VXUWCJS7.js} +2 -2
  156. package/dist/cli-bundle/chunks/{chunk-ETGRUM64.js → chunk-WBMARQCV.js} +3 -3
  157. package/dist/cli-bundle/chunks/{chunk-L6C62S4V.js → chunk-WZDABROA.js} +5 -5
  158. package/dist/cli-bundle/chunks/{chunk-P63GUQK5.js → chunk-XG5GVZRX.js} +4 -4
  159. package/dist/cli-bundle/chunks/{chunk-6UWHAJEX.js → chunk-XGCPTS6L.js} +10 -10
  160. package/dist/cli-bundle/chunks/{chunk-XGUXU4IQ.js → chunk-Y44B5FBE.js} +3 -3
  161. package/dist/cli-bundle/chunks/{chunk-C3QR2DPR.js → chunk-YP6DWEWQ.js} +3 -3
  162. package/dist/cli-bundle/chunks/{chunk-TB6364F7.js → chunk-Z7XTVIN5.js} +5 -5
  163. package/dist/cli-bundle/chunks/{chunk-XSJZF3TO.js → chunk-ZEKVLV6P.js} +4 -4
  164. package/dist/cli-bundle/chunks/{chunk-SNFLSFFH.js → chunk-ZFPOBSPC.js} +3 -3
  165. package/dist/cli-bundle/chunks/{chunk-RYASC6U3.js → chunk-ZUB725AA.js} +7 -7
  166. package/dist/cli-bundle/chunks/{close-A77IGXNC.js → close-CQHW3WMK.js} +5 -5
  167. package/dist/cli-bundle/chunks/close-ZZW5FLTB.js +12 -0
  168. package/dist/cli-bundle/chunks/{close-many-P2YOWN52.js → close-many-AR2YH3SJ.js} +12 -12
  169. package/dist/cli-bundle/chunks/close-many-IKCEGBLQ.js +21 -0
  170. package/dist/cli-bundle/chunks/comments-NV4SIY5Z.js +13 -0
  171. package/dist/cli-bundle/chunks/{comments-FNLKE3TW.js → comments-UV4HMI2K.js} +7 -7
  172. package/dist/cli-bundle/chunks/{copy-U6H22S7E.js → copy-OUFWOHVG.js} +4 -4
  173. package/dist/cli-bundle/chunks/copy-X7HJFWIH.js +9 -0
  174. package/dist/cli-bundle/chunks/{create-HS64DHTL.js → create-QEDL4KKT.js} +9 -9
  175. package/dist/cli-bundle/chunks/create-R6MMMMJS.js +25 -0
  176. package/dist/cli-bundle/chunks/{delete-4XPF5XLP.js → delete-MJGZFDHZ.js} +4 -4
  177. package/dist/cli-bundle/chunks/delete-OOJRG4HF.js +10 -0
  178. package/dist/cli-bundle/chunks/{deps-TMOF765V.js → deps-4OP6Q76N.js} +4 -4
  179. package/dist/cli-bundle/chunks/{deps-R44LVZTU.js → deps-Y5X6NFT5.js} +4 -4
  180. package/dist/cli-bundle/chunks/docs-SILTBWSO.js +14 -0
  181. package/dist/cli-bundle/chunks/{docs-HN6QKGEU.js → docs-UKTQVUHS.js} +6 -6
  182. package/dist/cli-bundle/chunks/{files-RNFWG435.js → files-2QEI2V3C.js} +6 -6
  183. package/dist/cli-bundle/chunks/{files-NX4LNOPL.js → files-7OIKZPI3.js} +6 -6
  184. package/dist/cli-bundle/chunks/focus-3YC5LFCG.js +10 -0
  185. package/dist/cli-bundle/chunks/{focus-OBSDVVI7.js → focus-FFWH32BF.js} +5 -5
  186. package/dist/cli-bundle/chunks/{history-compact-RZMMFSTO.js → history-compact-AAA4W6LY.js} +8 -8
  187. package/dist/cli-bundle/chunks/{history-compact-CKNRN637.js → history-compact-PIURAPW5.js} +8 -8
  188. package/dist/cli-bundle/chunks/history-redact-KWZ7LKQB.js +16 -0
  189. package/dist/cli-bundle/chunks/{history-redact-W7TTAEX2.js → history-redact-NTO74EIV.js} +6 -6
  190. package/dist/cli-bundle/chunks/history-repair-QWZJYYOJ.js +18 -0
  191. package/dist/cli-bundle/chunks/{history-repair-RGAQBOIS.js → history-repair-ROV5TD3L.js} +8 -8
  192. package/dist/cli-bundle/chunks/learnings-25TJCVON.js +13 -0
  193. package/dist/cli-bundle/chunks/{learnings-VDRTXWTF.js → learnings-3WJFJT7E.js} +7 -7
  194. package/dist/cli-bundle/chunks/{notes-UXXTI3J5.js → notes-FM53JJ5C.js} +7 -7
  195. package/dist/cli-bundle/chunks/notes-IAHGNCYQ.js +13 -0
  196. package/dist/cli-bundle/chunks/{plan-H3OPE2RP.js → plan-EJ4USP2S.js} +10 -10
  197. package/dist/cli-bundle/chunks/plan-WHV4H2RW.js +24 -0
  198. package/dist/cli-bundle/chunks/{profile-PFNN3CBJ.js → profile-SZQVKHUQ.js} +9 -9
  199. package/dist/cli-bundle/chunks/{profile-FCZWT5LE.js → profile-TXE673DR.js} +9 -9
  200. package/dist/cli-bundle/chunks/{register-list-query-BGEGWQ6S.js → register-list-query-LSR2G2SJ.js} +16 -16
  201. package/dist/cli-bundle/chunks/{register-list-query-BGEGWQ6S.js.map → register-list-query-LSR2G2SJ.js.map} +1 -1
  202. package/dist/cli-bundle/chunks/{register-list-query-ODDZVR6N.js → register-list-query-S6I73L5W.js} +15 -15
  203. package/dist/cli-bundle/chunks/{register-list-query-ODDZVR6N.js.map → register-list-query-S6I73L5W.js.map} +2 -2
  204. package/dist/cli-bundle/chunks/{register-mutation-OAJXSNWK.js → register-mutation-77GYER52.js} +32 -32
  205. package/dist/cli-bundle/chunks/{register-mutation-OAJXSNWK.js.map → register-mutation-77GYER52.js.map} +1 -1
  206. package/dist/cli-bundle/chunks/{register-mutation-2APBEHTJ.js → register-mutation-A2SC3K5G.js} +31 -31
  207. package/dist/cli-bundle/chunks/{register-mutation-2APBEHTJ.js.map → register-mutation-A2SC3K5G.js.map} +2 -2
  208. package/dist/cli-bundle/chunks/{register-operations-3TYKCKEZ.js → register-operations-KSAIBSZH.js} +43 -33
  209. package/dist/cli-bundle/chunks/register-operations-KSAIBSZH.js.map +1 -0
  210. package/dist/cli-bundle/chunks/{register-operations-WKZSX4QP.js → register-operations-W6Z5LVI5.js} +42 -32
  211. package/dist/cli-bundle/chunks/register-operations-W6Z5LVI5.js.map +7 -0
  212. package/dist/cli-bundle/chunks/{register-setup-HSVJDV3R.js → register-setup-KB5U3RES.js} +15 -15
  213. package/dist/cli-bundle/chunks/{register-setup-KE5L3H7U.js → register-setup-ZG7YXPHJ.js} +15 -15
  214. package/dist/cli-bundle/chunks/{restore-MDNVYUDD.js → restore-F5HPTRBR.js} +6 -6
  215. package/dist/cli-bundle/chunks/restore-LN57EB5H.js +14 -0
  216. package/dist/cli-bundle/chunks/{schema-AJCAANMB.js → schema-3DKXA4KR.js} +6 -6
  217. package/dist/cli-bundle/chunks/{schema-2B37DMM2.js → schema-QLTOK23S.js} +6 -6
  218. package/dist/cli-bundle/chunks/update-2T5EWMXD.js +21 -0
  219. package/dist/cli-bundle/chunks/{update-ZCDGTSNL.js → update-IKMNH3W4.js} +12 -12
  220. package/dist/cli-bundle/chunks/{update-many-6E2DDBE4.js → update-many-3Q6Z2Q4Y.js} +19 -19
  221. package/dist/cli-bundle/chunks/update-many-OTAS4BWH.js +30 -0
  222. package/dist/cli-bundle/main.js +75 -20
  223. package/dist/cli-bundle/main.js.map +2 -2
  224. package/dist/cli-bundle/sdk-runtime.js +63 -52
  225. package/dist/cli-bundle/sdk-testing.js +6 -6
  226. package/dist/cli-bundle/sdk.js +63 -54
  227. package/dist/cli-bundle/sdk.js.map +2 -2
  228. package/dist/core/extensions/item-fields.js +3 -3
  229. package/dist/core/extensions/item-fields.js.map +1 -1
  230. package/dist/core/extensions/loader.js +29 -20
  231. package/dist/core/extensions/loader.js.map +1 -1
  232. package/dist/core/schema/fields-file.js +5 -3
  233. package/dist/core/schema/fields-file.js.map +1 -1
  234. package/dist/sdk/cli-contracts/flag-contracts.js +12 -2
  235. package/dist/sdk/cli-contracts/flag-contracts.js.map +1 -1
  236. package/dist/sdk/cli-contracts/tool-parameter-tables.js +14 -2
  237. package/dist/sdk/cli-contracts/tool-parameter-tables.js.map +1 -1
  238. package/dist/sdk/cli-contracts/tool-schema.d.ts +1 -1
  239. package/dist/sdk/cli-contracts/tool-schema.js +18 -6
  240. package/dist/sdk/cli-contracts/tool-schema.js.map +1 -1
  241. package/dist/sdk/index.d.ts +3 -1
  242. package/dist/sdk/index.js +4 -3
  243. package/dist/sdk/index.js.map +1 -1
  244. package/dist/sdk/runtime.d.ts +51 -1
  245. package/dist/sdk/runtime.js +91 -4
  246. package/dist/sdk/runtime.js.map +1 -1
  247. package/dist/sdk/workspace.d.ts +15 -0
  248. package/dist/sdk/workspace.js +50 -0
  249. package/dist/sdk/workspace.js.map +1 -0
  250. package/docs/AGENT_GUIDE.md +1 -0
  251. package/docs/CHATGPT_CODEX_PLUGIN_IMPLEMENTATION.md +775 -0
  252. package/docs/CODEX_PLUGIN.md +11 -1
  253. package/docs/COMMANDS.md +3 -1
  254. package/docs/README.md +3 -0
  255. package/docs/SDK.md +204 -71
  256. package/marketplace.json +2 -2
  257. package/package.json +3 -2
  258. package/packages/pm-beads/extensions/beads/runtime-loader.ts +3 -0
  259. package/packages/pm-beads/package.json +1 -1
  260. package/packages/pm-calendar/package.json +1 -1
  261. package/packages/pm-command-kit/package.json +1 -1
  262. package/packages/pm-governance-audit/package.json +1 -1
  263. package/packages/pm-guide-shell/package.json +1 -1
  264. package/packages/pm-kanban/package.json +1 -1
  265. package/packages/pm-lifecycle-hooks/package.json +1 -1
  266. package/packages/pm-linked-test-adapters/package.json +1 -1
  267. package/packages/pm-search-advanced/package.json +1 -1
  268. package/packages/pm-templates/package.json +1 -1
  269. package/packages/pm-todos/extensions/todos/runtime-loader.ts +3 -0
  270. package/packages/pm-todos/package.json +1 -1
  271. package/plugins/pm-claude/.claude-plugin/plugin.json +1 -1
  272. package/plugins/pm-codex/.codex-plugin/plugin.json +1 -1
  273. package/dist/cli-bundle/chunks/append-425YGJMY.js +0 -11
  274. package/dist/cli-bundle/chunks/chunk-A3AIKEYC.js.map +0 -7
  275. package/dist/cli-bundle/chunks/chunk-C4FIA5U6.js.map +0 -7
  276. package/dist/cli-bundle/chunks/chunk-CTAPVM6C.js.map +0 -7
  277. package/dist/cli-bundle/chunks/chunk-GPBKJERW.js.map +0 -1
  278. package/dist/cli-bundle/chunks/chunk-GZNB5V5J.js.map +0 -7
  279. package/dist/cli-bundle/chunks/chunk-KDNZSVCK.js.map +0 -1
  280. package/dist/cli-bundle/chunks/chunk-LIY2ILWI.js.map +0 -7
  281. package/dist/cli-bundle/chunks/chunk-MORRAQXQ.js.map +0 -1
  282. package/dist/cli-bundle/chunks/chunk-OJ64VYGO.js.map +0 -1
  283. package/dist/cli-bundle/chunks/chunk-RAC2UXLT.js.map +0 -1
  284. package/dist/cli-bundle/chunks/chunk-ROH64TST.js.map +0 -1
  285. package/dist/cli-bundle/chunks/chunk-WQ5227PH.js.map +0 -7
  286. package/dist/cli-bundle/chunks/chunk-XQLLRYOX.js.map +0 -1
  287. package/dist/cli-bundle/chunks/close-II7JKV32.js +0 -12
  288. package/dist/cli-bundle/chunks/close-many-FD46X4WK.js +0 -21
  289. package/dist/cli-bundle/chunks/comments-OAU2E7RK.js +0 -13
  290. package/dist/cli-bundle/chunks/copy-5MOERABQ.js +0 -9
  291. package/dist/cli-bundle/chunks/create-DOMKSBHN.js +0 -25
  292. package/dist/cli-bundle/chunks/delete-BMOQWZRQ.js +0 -10
  293. package/dist/cli-bundle/chunks/docs-J4OI4PWM.js +0 -14
  294. package/dist/cli-bundle/chunks/focus-7H5B4PKZ.js +0 -10
  295. package/dist/cli-bundle/chunks/history-redact-ZNS2QTMI.js +0 -16
  296. package/dist/cli-bundle/chunks/history-repair-LQ5IU4ZX.js +0 -18
  297. package/dist/cli-bundle/chunks/learnings-AHMJNIQZ.js +0 -13
  298. package/dist/cli-bundle/chunks/notes-GJI26GJR.js +0 -13
  299. package/dist/cli-bundle/chunks/plan-ZHJH6VMF.js +0 -24
  300. package/dist/cli-bundle/chunks/register-operations-3TYKCKEZ.js.map +0 -1
  301. package/dist/cli-bundle/chunks/register-operations-WKZSX4QP.js.map +0 -7
  302. package/dist/cli-bundle/chunks/restore-AR77QSO6.js +0 -14
  303. package/dist/cli-bundle/chunks/update-D3ZZ2V7Z.js +0 -21
  304. package/dist/cli-bundle/chunks/update-many-2Q2PRSSB.js +0 -30
  305. /package/dist/cli-bundle/chunks/{append-425YGJMY.js.map → append-RH3G5RAV.js.map} +0 -0
  306. /package/dist/cli-bundle/chunks/{append-464PHZ65.js.map → append-T5DTS4NU.js.map} +0 -0
  307. /package/dist/cli-bundle/chunks/{chunk-YMP6AKGU.js.map → chunk-2XWRFOPR.js.map} +0 -0
  308. /package/dist/cli-bundle/chunks/{chunk-HT5P3WC6.js.map → chunk-2Z36LSAT.js.map} +0 -0
  309. /package/dist/cli-bundle/chunks/{chunk-DBV6QRYT.js.map → chunk-3KJ3FG5O.js.map} +0 -0
  310. /package/dist/cli-bundle/chunks/{chunk-AQLKMQQA.js.map → chunk-3M5BWYUA.js.map} +0 -0
  311. /package/dist/cli-bundle/chunks/{chunk-47CCRGRH.js.map → chunk-47TKJR3D.js.map} +0 -0
  312. /package/dist/cli-bundle/chunks/{chunk-YCSDMIQW.js.map → chunk-4MO4PPR2.js.map} +0 -0
  313. /package/dist/cli-bundle/chunks/{chunk-WCRAUCJO.js.map → chunk-546WPG33.js.map} +0 -0
  314. /package/dist/cli-bundle/chunks/{chunk-RLOWK5EQ.js.map → chunk-5754C5XS.js.map} +0 -0
  315. /package/dist/cli-bundle/chunks/{chunk-7U5INZ2C.js.map → chunk-5V746BN3.js.map} +0 -0
  316. /package/dist/cli-bundle/chunks/{chunk-ZLQDOBZL.js.map → chunk-6OK5QSGH.js.map} +0 -0
  317. /package/dist/cli-bundle/chunks/{chunk-2HNZKLHV.js.map → chunk-7SHFQB2A.js.map} +0 -0
  318. /package/dist/cli-bundle/chunks/{chunk-6APTSPP5.js.map → chunk-7SIWW7C3.js.map} +0 -0
  319. /package/dist/cli-bundle/chunks/{chunk-7HQQT6AT.js.map → chunk-7TYZTBEV.js.map} +0 -0
  320. /package/dist/cli-bundle/chunks/{chunk-YCHJLOO2.js.map → chunk-A6AK7W5M.js.map} +0 -0
  321. /package/dist/cli-bundle/chunks/{chunk-WBKZAO3P.js.map → chunk-A6AVSYRJ.js.map} +0 -0
  322. /package/dist/cli-bundle/chunks/{chunk-L7C6RTGH.js.map → chunk-ACDIA6NP.js.map} +0 -0
  323. /package/dist/cli-bundle/chunks/{chunk-AX3BJLPV.js.map → chunk-ACRC3HI4.js.map} +0 -0
  324. /package/dist/cli-bundle/chunks/{chunk-B6JBI7JX.js.map → chunk-ANLHBXAE.js.map} +0 -0
  325. /package/dist/cli-bundle/chunks/{chunk-2KQG6L3J.js.map → chunk-AS62PEJE.js.map} +0 -0
  326. /package/dist/cli-bundle/chunks/{chunk-J3EXRK2H.js.map → chunk-BLRO2POO.js.map} +0 -0
  327. /package/dist/cli-bundle/chunks/{chunk-VOXOXART.js.map → chunk-DLZ3RXAL.js.map} +0 -0
  328. /package/dist/cli-bundle/chunks/{chunk-H6YDNW46.js.map → chunk-DNH44IKP.js.map} +0 -0
  329. /package/dist/cli-bundle/chunks/{chunk-QI5KTH6A.js.map → chunk-EBBROE54.js.map} +0 -0
  330. /package/dist/cli-bundle/chunks/{chunk-GC5ME4ZU.js.map → chunk-FF523THY.js.map} +0 -0
  331. /package/dist/cli-bundle/chunks/{chunk-5OBMSBWX.js.map → chunk-FIZUJWXQ.js.map} +0 -0
  332. /package/dist/cli-bundle/chunks/{chunk-HLBSL5KE.js.map → chunk-FVWQFTTW.js.map} +0 -0
  333. /package/dist/cli-bundle/chunks/{chunk-YIWYD7TC.js.map → chunk-FVZEIWTL.js.map} +0 -0
  334. /package/dist/cli-bundle/chunks/{chunk-4DC5XNMS.js.map → chunk-GFBV2254.js.map} +0 -0
  335. /package/dist/cli-bundle/chunks/{chunk-OKZ35F3Y.js.map → chunk-GRB3TFOC.js.map} +0 -0
  336. /package/dist/cli-bundle/chunks/{chunk-TZFULSN4.js.map → chunk-GVGFLZQS.js.map} +0 -0
  337. /package/dist/cli-bundle/chunks/{chunk-RTG2LHQ7.js.map → chunk-HLZXQKGZ.js.map} +0 -0
  338. /package/dist/cli-bundle/chunks/{chunk-5F7UJHFY.js.map → chunk-HO6CDURZ.js.map} +0 -0
  339. /package/dist/cli-bundle/chunks/{chunk-MN2YMU55.js.map → chunk-HOE3UV3G.js.map} +0 -0
  340. /package/dist/cli-bundle/chunks/{chunk-I535LTZ2.js.map → chunk-IS6M4ETF.js.map} +0 -0
  341. /package/dist/cli-bundle/chunks/{chunk-K7HEURQ4.js.map → chunk-J2XEW4YL.js.map} +0 -0
  342. /package/dist/cli-bundle/chunks/{chunk-O2Q7YQGO.js.map → chunk-J7XSQCJO.js.map} +0 -0
  343. /package/dist/cli-bundle/chunks/{chunk-RA2LPP6E.js.map → chunk-JM4Z53DN.js.map} +0 -0
  344. /package/dist/cli-bundle/chunks/{chunk-JR6FIX53.js.map → chunk-JNNPTGXR.js.map} +0 -0
  345. /package/dist/cli-bundle/chunks/{chunk-I5VZGPS2.js.map → chunk-K7CGOZK5.js.map} +0 -0
  346. /package/dist/cli-bundle/chunks/{chunk-B6OANV3G.js.map → chunk-KDH62ECD.js.map} +0 -0
  347. /package/dist/cli-bundle/chunks/{chunk-NR7PTIR7.js.map → chunk-L23NAJHL.js.map} +0 -0
  348. /package/dist/cli-bundle/chunks/{chunk-FCZ6WYSR.js.map → chunk-LEXFDABF.js.map} +0 -0
  349. /package/dist/cli-bundle/chunks/{chunk-GP54I36Z.js.map → chunk-LNAGQRIL.js.map} +0 -0
  350. /package/dist/cli-bundle/chunks/{chunk-DD2WZD6L.js.map → chunk-LU4Z7POS.js.map} +0 -0
  351. /package/dist/cli-bundle/chunks/{chunk-FEVEIX53.js.map → chunk-LX265XY7.js.map} +0 -0
  352. /package/dist/cli-bundle/chunks/{chunk-NJABR6EB.js.map → chunk-MQAGSAMS.js.map} +0 -0
  353. /package/dist/cli-bundle/chunks/{chunk-MRMS62WQ.js.map → chunk-N4NKVLPY.js.map} +0 -0
  354. /package/dist/cli-bundle/chunks/{chunk-RY57ESL2.js.map → chunk-ND3MDD6L.js.map} +0 -0
  355. /package/dist/cli-bundle/chunks/{chunk-Y476SA4V.js.map → chunk-NEJKKTCG.js.map} +0 -0
  356. /package/dist/cli-bundle/chunks/{chunk-Q3EW4RE5.js.map → chunk-NGL3X3XM.js.map} +0 -0
  357. /package/dist/cli-bundle/chunks/{chunk-ENJDRDDP.js.map → chunk-NK54BSL7.js.map} +0 -0
  358. /package/dist/cli-bundle/chunks/{chunk-KHQYX2QB.js.map → chunk-NN57FRRN.js.map} +0 -0
  359. /package/dist/cli-bundle/chunks/{chunk-VNCQ7SSG.js.map → chunk-NNRXTZ7Y.js.map} +0 -0
  360. /package/dist/cli-bundle/chunks/{chunk-KZQHMDS6.js.map → chunk-NOIIRLCO.js.map} +0 -0
  361. /package/dist/cli-bundle/chunks/{chunk-K2PDZYUF.js.map → chunk-OC2CLNMS.js.map} +0 -0
  362. /package/dist/cli-bundle/chunks/{chunk-SN7Q7M4U.js.map → chunk-OKUFGORG.js.map} +0 -0
  363. /package/dist/cli-bundle/chunks/{chunk-ZLWBLI5R.js.map → chunk-OOK6V7BF.js.map} +0 -0
  364. /package/dist/cli-bundle/chunks/{chunk-DDEYJ3BH.js.map → chunk-OUQ4I6HC.js.map} +0 -0
  365. /package/dist/cli-bundle/chunks/{chunk-X7ZXLB3C.js.map → chunk-PDOJRPYR.js.map} +0 -0
  366. /package/dist/cli-bundle/chunks/{chunk-HDNEQAHV.js.map → chunk-PHQPQNAT.js.map} +0 -0
  367. /package/dist/cli-bundle/chunks/{chunk-FMFSUTTD.js.map → chunk-PTJ7NVUU.js.map} +0 -0
  368. /package/dist/cli-bundle/chunks/{chunk-5URFS7C4.js.map → chunk-PUMGO764.js.map} +0 -0
  369. /package/dist/cli-bundle/chunks/{chunk-RPZ57GQ7.js.map → chunk-QFCCN4JO.js.map} +0 -0
  370. /package/dist/cli-bundle/chunks/{chunk-35YNX7RQ.js.map → chunk-QYIDXRRX.js.map} +0 -0
  371. /package/dist/cli-bundle/chunks/{chunk-ITIUEWD5.js.map → chunk-RFDT674H.js.map} +0 -0
  372. /package/dist/cli-bundle/chunks/{chunk-2BUNV627.js.map → chunk-SJ2DADDH.js.map} +0 -0
  373. /package/dist/cli-bundle/chunks/{chunk-ZYDUOY54.js.map → chunk-TKD4NESJ.js.map} +0 -0
  374. /package/dist/cli-bundle/chunks/{chunk-BU2CV5ZU.js.map → chunk-TMNQV4EK.js.map} +0 -0
  375. /package/dist/cli-bundle/chunks/{chunk-GJNBKU6G.js.map → chunk-TWELUDDF.js.map} +0 -0
  376. /package/dist/cli-bundle/chunks/{chunk-Y5E6FCAL.js.map → chunk-U3S22BOJ.js.map} +0 -0
  377. /package/dist/cli-bundle/chunks/{chunk-2BKRMFGK.js.map → chunk-UFY4ETU6.js.map} +0 -0
  378. /package/dist/cli-bundle/chunks/{chunk-EEUIIDWF.js.map → chunk-UGQENMKM.js.map} +0 -0
  379. /package/dist/cli-bundle/chunks/{chunk-XK5CTXMB.js.map → chunk-UGSHP6SR.js.map} +0 -0
  380. /package/dist/cli-bundle/chunks/{chunk-2JWIRG4V.js.map → chunk-VF24O6TV.js.map} +0 -0
  381. /package/dist/cli-bundle/chunks/{chunk-PZBRTJ3Y.js.map → chunk-VLVTXEGG.js.map} +0 -0
  382. /package/dist/cli-bundle/chunks/{chunk-NAGOH4YJ.js.map → chunk-VXUWCJS7.js.map} +0 -0
  383. /package/dist/cli-bundle/chunks/{chunk-ETGRUM64.js.map → chunk-WBMARQCV.js.map} +0 -0
  384. /package/dist/cli-bundle/chunks/{chunk-L6C62S4V.js.map → chunk-WZDABROA.js.map} +0 -0
  385. /package/dist/cli-bundle/chunks/{chunk-P63GUQK5.js.map → chunk-XG5GVZRX.js.map} +0 -0
  386. /package/dist/cli-bundle/chunks/{chunk-6UWHAJEX.js.map → chunk-XGCPTS6L.js.map} +0 -0
  387. /package/dist/cli-bundle/chunks/{chunk-XGUXU4IQ.js.map → chunk-Y44B5FBE.js.map} +0 -0
  388. /package/dist/cli-bundle/chunks/{chunk-C3QR2DPR.js.map → chunk-YP6DWEWQ.js.map} +0 -0
  389. /package/dist/cli-bundle/chunks/{chunk-TB6364F7.js.map → chunk-Z7XTVIN5.js.map} +0 -0
  390. /package/dist/cli-bundle/chunks/{chunk-XSJZF3TO.js.map → chunk-ZEKVLV6P.js.map} +0 -0
  391. /package/dist/cli-bundle/chunks/{chunk-SNFLSFFH.js.map → chunk-ZFPOBSPC.js.map} +0 -0
  392. /package/dist/cli-bundle/chunks/{chunk-RYASC6U3.js.map → chunk-ZUB725AA.js.map} +0 -0
  393. /package/dist/cli-bundle/chunks/{close-A77IGXNC.js.map → close-CQHW3WMK.js.map} +0 -0
  394. /package/dist/cli-bundle/chunks/{close-II7JKV32.js.map → close-ZZW5FLTB.js.map} +0 -0
  395. /package/dist/cli-bundle/chunks/{close-many-P2YOWN52.js.map → close-many-AR2YH3SJ.js.map} +0 -0
  396. /package/dist/cli-bundle/chunks/{close-many-FD46X4WK.js.map → close-many-IKCEGBLQ.js.map} +0 -0
  397. /package/dist/cli-bundle/chunks/{comments-OAU2E7RK.js.map → comments-NV4SIY5Z.js.map} +0 -0
  398. /package/dist/cli-bundle/chunks/{comments-FNLKE3TW.js.map → comments-UV4HMI2K.js.map} +0 -0
  399. /package/dist/cli-bundle/chunks/{copy-U6H22S7E.js.map → copy-OUFWOHVG.js.map} +0 -0
  400. /package/dist/cli-bundle/chunks/{copy-5MOERABQ.js.map → copy-X7HJFWIH.js.map} +0 -0
  401. /package/dist/cli-bundle/chunks/{create-HS64DHTL.js.map → create-QEDL4KKT.js.map} +0 -0
  402. /package/dist/cli-bundle/chunks/{create-DOMKSBHN.js.map → create-R6MMMMJS.js.map} +0 -0
  403. /package/dist/cli-bundle/chunks/{delete-4XPF5XLP.js.map → delete-MJGZFDHZ.js.map} +0 -0
  404. /package/dist/cli-bundle/chunks/{delete-BMOQWZRQ.js.map → delete-OOJRG4HF.js.map} +0 -0
  405. /package/dist/cli-bundle/chunks/{deps-TMOF765V.js.map → deps-4OP6Q76N.js.map} +0 -0
  406. /package/dist/cli-bundle/chunks/{deps-R44LVZTU.js.map → deps-Y5X6NFT5.js.map} +0 -0
  407. /package/dist/cli-bundle/chunks/{docs-J4OI4PWM.js.map → docs-SILTBWSO.js.map} +0 -0
  408. /package/dist/cli-bundle/chunks/{docs-HN6QKGEU.js.map → docs-UKTQVUHS.js.map} +0 -0
  409. /package/dist/cli-bundle/chunks/{files-RNFWG435.js.map → files-2QEI2V3C.js.map} +0 -0
  410. /package/dist/cli-bundle/chunks/{files-NX4LNOPL.js.map → files-7OIKZPI3.js.map} +0 -0
  411. /package/dist/cli-bundle/chunks/{focus-7H5B4PKZ.js.map → focus-3YC5LFCG.js.map} +0 -0
  412. /package/dist/cli-bundle/chunks/{focus-OBSDVVI7.js.map → focus-FFWH32BF.js.map} +0 -0
  413. /package/dist/cli-bundle/chunks/{history-compact-RZMMFSTO.js.map → history-compact-AAA4W6LY.js.map} +0 -0
  414. /package/dist/cli-bundle/chunks/{history-compact-CKNRN637.js.map → history-compact-PIURAPW5.js.map} +0 -0
  415. /package/dist/cli-bundle/chunks/{history-redact-ZNS2QTMI.js.map → history-redact-KWZ7LKQB.js.map} +0 -0
  416. /package/dist/cli-bundle/chunks/{history-redact-W7TTAEX2.js.map → history-redact-NTO74EIV.js.map} +0 -0
  417. /package/dist/cli-bundle/chunks/{history-repair-LQ5IU4ZX.js.map → history-repair-QWZJYYOJ.js.map} +0 -0
  418. /package/dist/cli-bundle/chunks/{history-repair-RGAQBOIS.js.map → history-repair-ROV5TD3L.js.map} +0 -0
  419. /package/dist/cli-bundle/chunks/{learnings-AHMJNIQZ.js.map → learnings-25TJCVON.js.map} +0 -0
  420. /package/dist/cli-bundle/chunks/{learnings-VDRTXWTF.js.map → learnings-3WJFJT7E.js.map} +0 -0
  421. /package/dist/cli-bundle/chunks/{notes-UXXTI3J5.js.map → notes-FM53JJ5C.js.map} +0 -0
  422. /package/dist/cli-bundle/chunks/{notes-GJI26GJR.js.map → notes-IAHGNCYQ.js.map} +0 -0
  423. /package/dist/cli-bundle/chunks/{plan-H3OPE2RP.js.map → plan-EJ4USP2S.js.map} +0 -0
  424. /package/dist/cli-bundle/chunks/{plan-ZHJH6VMF.js.map → plan-WHV4H2RW.js.map} +0 -0
  425. /package/dist/cli-bundle/chunks/{profile-PFNN3CBJ.js.map → profile-SZQVKHUQ.js.map} +0 -0
  426. /package/dist/cli-bundle/chunks/{profile-FCZWT5LE.js.map → profile-TXE673DR.js.map} +0 -0
  427. /package/dist/cli-bundle/chunks/{register-setup-HSVJDV3R.js.map → register-setup-KB5U3RES.js.map} +0 -0
  428. /package/dist/cli-bundle/chunks/{register-setup-KE5L3H7U.js.map → register-setup-ZG7YXPHJ.js.map} +0 -0
  429. /package/dist/cli-bundle/chunks/{restore-MDNVYUDD.js.map → restore-F5HPTRBR.js.map} +0 -0
  430. /package/dist/cli-bundle/chunks/{restore-AR77QSO6.js.map → restore-LN57EB5H.js.map} +0 -0
  431. /package/dist/cli-bundle/chunks/{schema-AJCAANMB.js.map → schema-3DKXA4KR.js.map} +0 -0
  432. /package/dist/cli-bundle/chunks/{schema-2B37DMM2.js.map → schema-QLTOK23S.js.map} +0 -0
  433. /package/dist/cli-bundle/chunks/{update-D3ZZ2V7Z.js.map → update-2T5EWMXD.js.map} +0 -0
  434. /package/dist/cli-bundle/chunks/{update-ZCDGTSNL.js.map → update-IKMNH3W4.js.map} +0 -0
  435. /package/dist/cli-bundle/chunks/{update-many-6E2DDBE4.js.map → update-many-3Q6Z2Q4Y.js.map} +0 -0
  436. /package/dist/cli-bundle/chunks/{update-many-2Q2PRSSB.js.map → update-many-OTAS4BWH.js.map} +0 -0
@@ -4,8 +4,9 @@
4
4
  * Resolves configurable schema, fields, statuses, and workflows for Fields File.
5
5
  */
6
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]="d385bfd4-56bb-5b73-9769-b443473e139a")}catch(e){}}();
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]="5b67948f-d13c-52e4-8e6a-6ba23768d589")}catch(e){}}();
8
8
  import { RUNTIME_FIELD_COMMAND_VALUES, RUNTIME_FIELD_TYPE_VALUES, } from "../../types/index.js";
9
+ import { FRONT_MATTER_KEY_ORDER } from "../shared/constants.js";
9
10
  /**
10
11
  * Pure logic for the `pm schema add-field` / `pm schema remove-field` commands
11
12
  * and the `list-fields` / `show-field` inspectors. The CLI command file
@@ -22,6 +23,7 @@ const RUNTIME_FIELD_TYPE_SET = new Set(RUNTIME_FIELD_TYPE_VALUES);
22
23
  const RUNTIME_FIELD_COMMAND_SET = new Set(RUNTIME_FIELD_COMMAND_VALUES);
23
24
  /** Built-in front-matter field names a custom field key must never shadow. A custom key that collides with one of these would let `pm create --<key>` write over reserved metadata, so add-field rejects them up front (symmetric with the built-in-type guard in item-types-file.ts). */
24
25
  export const BUILTIN_FIELD_KEYS = new Set([
26
+ ...FRONT_MATTER_KEY_ORDER.filter((key) => key !== "severity"),
25
27
  "id",
26
28
  "title",
27
29
  "type",
@@ -120,7 +122,7 @@ export function normalizeAddFieldInput(raw) {
120
122
  throw new Error("Field key must not be empty.");
121
123
  }
122
124
  if (BUILTIN_FIELD_KEYS.has(key)) {
123
- throw new Error(`Cannot define custom field "${key}": it shadows a built-in field. Built-in fields are reserved.`);
125
+ throw new Error(`Cannot define custom field "${key}": custom schema field "${key}" collides with built-in item metadata "${key}". Rename the custom field with a project-specific prefix. Reserved fields: ${[...BUILTIN_FIELD_KEYS].sort((left, right) => left.localeCompare(right)).join(", ")}.`);
124
126
  }
125
127
  const typeCandidate = typeof raw.type === "string" && raw.type.trim().length > 0
126
128
  ? raw.type.trim().toLowerCase()
@@ -290,4 +292,4 @@ function applyBooleanFlag(definition, key, value) {
290
292
  }
291
293
  }
292
294
  //# sourceMappingURL=fields-file.js.map
293
- //# debugId=d385bfd4-56bb-5b73-9769-b443473e139a
295
+ //# debugId=5b67948f-d13c-52e4-8e6a-6ba23768d589
@@ -1 +1 @@
1
- {"version":3,"file":"fields-file.js","sources":["core/schema/fields-file.ts"],"sourceRoot":"/","sourcesContent":["/**\n * @module core/schema/fields-file\n *\n * Resolves configurable schema, fields, statuses, and workflows for Fields File.\n */\nimport {\n RUNTIME_FIELD_COMMAND_VALUES,\n RUNTIME_FIELD_TYPE_VALUES,\n} from \"../../types/index.js\";\nimport type {\n RuntimeFieldCommand,\n RuntimeFieldDefinition,\n RuntimeFieldType,\n} from \"../../types/index.js\";\n\nexport type {\n RuntimeFieldCommand,\n RuntimeFieldDefinition,\n RuntimeFieldType,\n} from \"../../types/index.js\";\n\n/**\n * Pure logic for the `pm schema add-field` / `pm schema remove-field` commands\n * and the `list-fields` / `show-field` inspectors. The CLI command file\n * (schema.ts) owns IO/governance; everything testable and side-effect-free lives\n * here so it can be coverage-gated to 100%.\n *\n * Custom fields persist at `.agents/pm/schema/fields.json` under the shape\n * `{ fields: RuntimeFieldDefinition[] }`. The runtime merge layer\n * (loadRuntimeSchemaFromOptionalFiles) reads that file and dynamically registers\n * a CLI flag per field on create/update/list/search/context, so this module only\n * has to manage the persisted entries; it never duplicates the registration.\n */\n\nconst RUNTIME_FIELD_TYPE_SET = new Set<string>(RUNTIME_FIELD_TYPE_VALUES);\nconst RUNTIME_FIELD_COMMAND_SET = new Set<string>(RUNTIME_FIELD_COMMAND_VALUES);\n\n/** Built-in front-matter field names a custom field key must never shadow. A custom key that collides with one of these would let `pm create --<key>` write over reserved metadata, so add-field rejects them up front (symmetric with the built-in-type guard in item-types-file.ts). */\nexport const BUILTIN_FIELD_KEYS: ReadonlySet<string> = new Set([\n \"id\",\n \"title\",\n \"type\",\n \"status\",\n \"priority\",\n \"tags\",\n \"assignee\",\n \"parent\",\n \"description\",\n \"body\",\n \"created_at\",\n \"updated_at\",\n \"closed_at\",\n \"author\",\n \"deadline\",\n \"estimate\",\n \"sprint\",\n \"release\",\n \"risk\",\n \"confidence\",\n \"reviewer\",\n \"resolution\",\n \"expected\",\n \"actual\",\n]);\n\n/** The default commands a field is wired onto when `--commands` is omitted, matching the runtime default in runtime-schema.ts (normalizeRuntimeFieldDefinition). */\nconst DEFAULT_FIELD_COMMANDS: RuntimeFieldCommand[] = [\"create\", \"update\"];\n\n/** The shape persisted at `.agents/pm/schema/fields.json`. */\nexport interface FieldsFile {\n /** Value that configures or reports fields for this contract. */\n fields: RuntimeFieldDefinition[];\n}\n\n/** Documents the raw add field input payload exchanged by command, SDK, and package integrations. */\nexport interface RawAddFieldInput {\n /** Value that configures or reports key for this contract. */\n key: string | undefined;\n /** Schema type that determines the shape and validation rules for this value. */\n type?: string;\n /** Value that configures or reports commands for this contract. */\n commands?: string[];\n /** Value that configures or reports description for this contract. */\n description?: string;\n /** Value that configures or reports cli flag for this contract. */\n cliFlag?: string;\n /** Value that configures or reports aliases for this contract. */\n aliases?: string[];\n /** Value that configures or reports required for this contract. */\n required?: boolean;\n /** Value that configures or reports required on create for this contract. */\n requiredOnCreate?: boolean;\n /** Value that configures or reports allow unset for this contract. */\n allowUnset?: boolean;\n /** Value that configures or reports required types for this contract. */\n requiredTypes?: string[];\n}\n\n/** Documents the normalized add field input payload exchanged by command, SDK, and package integrations. */\nexport interface NormalizedAddFieldInput {\n /** Value that configures or reports key for this contract. */\n key: string;\n /** Schema type that determines the shape and validation rules for this value. */\n type: RuntimeFieldType;\n /** Value that configures or reports commands for this contract. */\n commands: RuntimeFieldCommand[];\n /** Value that configures or reports description for this contract. */\n description?: string;\n /** Value that configures or reports cli flag for this contract. */\n cliFlag?: string;\n /** Value that configures or reports cli aliases for this contract. */\n cliAliases: string[];\n /** Value that configures or reports required for this contract. */\n required: boolean;\n /** Value that configures or reports required on create for this contract. */\n requiredOnCreate: boolean;\n /** Value that configures or reports allow unset for this contract. */\n allowUnset: boolean;\n /** Value that configures or reports required types for this contract. */\n requiredTypes: string[];\n}\n\n/** Documents the upsert field result payload exchanged by command, SDK, and package integrations. */\nexport interface UpsertFieldResult {\n /** Value that configures or reports file for this contract. */\n file: FieldsFile;\n /** The definition as stored after the upsert. */\n definition: RuntimeFieldDefinition;\n /** True when an existing definition with the same (normalized) key was replaced. */\n replaced: boolean;\n}\n\n/** Documents the remove field result payload exchanged by command, SDK, and package integrations. */\nexport interface RemoveFieldResult {\n /** Value that configures or reports file for this contract. */\n file: FieldsFile;\n /** True when a matching definition existed and was dropped from the file. */\n removed: boolean;\n /** The removed definition, when one matched the requested key. */\n definition?: RuntimeFieldDefinition;\n}\n\n/** Normalizes a field key using the same rule as runtime-schema.ts: lowercase and collapse any run of whitespace/hyphens into a single underscore. */\nexport function normalizeFieldKey(value: unknown): string {\n return typeof value === \"string\"\n ? value\n .trim()\n .toLowerCase()\n .replaceAll(/[\\s-]+/g, \"_\")\n : \"\";\n}\n\n/** Normalizes a CLI flag token: strip a leading `--`, lowercase, and collapse whitespace/underscore runs to a single hyphen (matches normalizeCliToken in runtime-schema.ts). */\nfunction normalizeCliToken(value: unknown): string {\n if (typeof value !== \"string\") {\n return \"\";\n }\n const collapsed = value\n .trim()\n .toLowerCase()\n .replaceAll(/[\\s_]+/g, \"-\");\n return collapsed.startsWith(\"--\") ? collapsed.slice(2) : collapsed;\n}\n\nfunction keyToDefaultCliFlag(key: string): string {\n return key.replaceAll(\"_\", \"-\");\n}\n\nfunction dedupeCliTokens(values: Iterable<string>, exclude: string): string[] {\n const seen = new Set<string>();\n for (const value of values) {\n const token = normalizeCliToken(value);\n if (token.length > 0 && token !== exclude) {\n seen.add(token);\n }\n }\n return [...seen].sort((left, right) => left.localeCompare(right));\n}\n\nfunction dedupeStringList(values: string[] | undefined): string[] {\n const seen = new Set<string>();\n for (const value of values ?? []) {\n const trimmed = value.trim();\n if (trimmed.length > 0) {\n seen.add(trimmed);\n }\n }\n return [...seen].sort((left, right) => left.localeCompare(right));\n}\n\n/** Normalizes the command allow-list stored for a custom field definition. */\nfunction normalizeFieldCommands(\n rawCommands: string[] | undefined,\n): RuntimeFieldCommand[] {\n const seen = new Set<string>();\n const normalized: RuntimeFieldCommand[] = [];\n for (const rawCommand of rawCommands ?? []) {\n const command = rawCommand.trim().toLowerCase();\n if (command.length === 0) {\n continue;\n }\n if (!RUNTIME_FIELD_COMMAND_SET.has(command)) {\n throw new Error(\n `Invalid field command \"${rawCommand}\". Allowed: ${RUNTIME_FIELD_COMMAND_VALUES.join(\", \")}.`,\n );\n }\n if (!seen.has(command)) {\n seen.add(command);\n normalized.push(command as RuntimeFieldCommand);\n }\n }\n return rawCommands === undefined || normalized.length === 0\n ? [...DEFAULT_FIELD_COMMANDS]\n : normalized;\n}\n\n/** Validates and normalizes raw add-field CLI input. Throws a plain Error with a stable message when the key is missing/empty, collides with a built-in field, or carries an invalid type/command; the CLI layer maps these to PmCliError exit codes. A `string_array` type implies a repeatable field downstream (runtime-schema.ts derives `repeatable`), so no separate repeatable flag is exposed. */\nexport function normalizeAddFieldInput(\n raw: RawAddFieldInput,\n): NormalizedAddFieldInput {\n const key = normalizeFieldKey(raw.key);\n if (key.length === 0) {\n throw new Error(\"Field key must not be empty.\");\n }\n if (BUILTIN_FIELD_KEYS.has(key)) {\n throw new Error(\n `Cannot define custom field \"${key}\": it shadows a built-in field. Built-in fields are reserved.`,\n );\n }\n\n const typeCandidate =\n typeof raw.type === \"string\" && raw.type.trim().length > 0\n ? raw.type.trim().toLowerCase()\n : \"string\";\n if (!RUNTIME_FIELD_TYPE_SET.has(typeCandidate)) {\n throw new Error(\n `Invalid field type \"${raw.type}\". Allowed: ${RUNTIME_FIELD_TYPE_VALUES.join(\", \")}.`,\n );\n }\n const type = typeCandidate as RuntimeFieldType;\n\n const commands = normalizeFieldCommands(raw.commands);\n\n const cliFlagToken = normalizeCliToken(raw.cliFlag);\n const cliFlag =\n cliFlagToken.length > 0 && cliFlagToken !== keyToDefaultCliFlag(key)\n ? cliFlagToken\n : undefined;\n const effectiveFlag = cliFlag ?? keyToDefaultCliFlag(key);\n const cliAliases = dedupeCliTokens(raw.aliases ?? [], effectiveFlag);\n\n const description = raw.description?.trim();\n return {\n key,\n type,\n commands,\n description:\n description && description.length > 0 ? description : undefined,\n cliFlag,\n cliAliases,\n required: raw.required === true,\n requiredOnCreate: raw.requiredOnCreate === true,\n // allow_unset defaults to true (omitted) and is only persisted when an\n // operator explicitly disables it with --no-allow-unset (allowUnset === false).\n allowUnset: raw.allowUnset !== false,\n requiredTypes: dedupeStringList(raw.requiredTypes),\n };\n}\n\nfunction selectFieldsArray(parsed: unknown): unknown[] | undefined {\n if (Array.isArray(parsed)) {\n return parsed;\n }\n if (typeof parsed !== \"object\" || parsed === null) {\n return undefined;\n }\n const record = parsed as Record<string, unknown>;\n if (Array.isArray(record.fields)) {\n return record.fields;\n }\n if (Array.isArray(record.definitions)) {\n return record.definitions;\n }\n return undefined;\n}\n\nfunction extractFieldDefinitions(parsed: unknown): RuntimeFieldDefinition[] {\n const candidate = selectFieldsArray(parsed);\n if (!candidate) {\n return [];\n }\n const definitions: RuntimeFieldDefinition[] = [];\n for (const entry of candidate) {\n if (typeof entry !== \"object\" || entry === null || Array.isArray(entry)) {\n continue;\n }\n const record = entry as Record<string, unknown>;\n if (typeof record.key !== \"string\" || record.key.trim().length === 0) {\n continue;\n }\n definitions.push(record as unknown as RuntimeFieldDefinition);\n }\n return definitions;\n}\n\n/** Coerces an arbitrary parsed value from fields.json into a FieldsFile. Accepts the canonical `{ fields: [...] }` shape, a bare array, or a `{ definitions: [...] }` form, and tolerates a missing/invalid file by returning an empty fields list. */\nexport function parseFieldsFile(raw: string | null | undefined): FieldsFile {\n if (raw === null || raw === undefined || raw.trim().length === 0) {\n return { fields: [] };\n }\n let parsed: unknown;\n try {\n parsed = JSON.parse(raw) as unknown;\n } catch {\n throw new Error(\"schema/fields.json contains invalid JSON.\");\n }\n return { fields: extractFieldDefinitions(parsed) };\n}\n\n/** Serializes the fields file with a trailing newline (matches the rest of the schema scaffold files written by pm). */\nexport function serializeFieldsFile(file: FieldsFile): string {\n return `${JSON.stringify({ fields: file.fields }, null, 2)}\\n`;\n}\n\n/** Idempotent UPSERT of a custom field into the parsed file. Matching is by normalized key. When a definition already exists, the supplied input fully replaces its add-field-managed attributes (type/commands/description/flags/ required flags) while preserving any unrelated keys the file may carry; any `metadata_key` already stored is preserved so existing item data keeps mapping to the same front-matter column. */\nexport function upsertField(\n file: FieldsFile,\n input: NormalizedAddFieldInput,\n): UpsertFieldResult {\n // Match by normalized key. A hand-authored file may carry more than one entry\n // for the same key, so drop ALL matches and re-insert a single merged result\n // (collapsing duplicates) rather than only rewriting the first occurrence. The\n // first existing match seeds preserved attributes (e.g. metadata_key).\n const existing = file.fields.find(\n (definition) => normalizeFieldKey(definition.key) === input.key,\n );\n const replaced = existing !== undefined;\n const fields = file.fields.filter(\n (definition) => normalizeFieldKey(definition.key) !== input.key,\n );\n\n const next: RuntimeFieldDefinition = {\n ...existing,\n key: input.key,\n type: input.type,\n commands: [...input.commands],\n };\n applyOptionalString(next, \"description\", input.description);\n applyOptionalString(next, \"cli_flag\", input.cliFlag);\n if (input.cliAliases.length > 0) {\n next.cli_aliases = [...input.cliAliases];\n } else {\n delete next.cli_aliases;\n }\n applyBooleanFlag(next, \"required\", input.required);\n applyBooleanFlag(next, \"required_on_create\", input.requiredOnCreate);\n // allow_unset defaults true; only persist the explicit false override.\n if (input.allowUnset === false) {\n next.allow_unset = false;\n } else {\n delete next.allow_unset;\n }\n if (input.requiredTypes.length > 0) {\n next.required_types = [...input.requiredTypes];\n } else {\n delete next.required_types;\n }\n\n fields.push(next);\n fields.sort((left, right) =>\n normalizeFieldKey(left.key).localeCompare(normalizeFieldKey(right.key)),\n );\n\n return {\n file: { fields },\n definition: next,\n replaced,\n };\n}\n\n/** Removes a custom field definition from the parsed file by key (normalized). Throws a plain Error when `key` is empty. Returns `removed: false` when no matching definition exists so the CLI layer can treat the call as an idempotent no-op. */\nexport function removeField(\n file: FieldsFile,\n key: string | undefined,\n): RemoveFieldResult {\n const normalizedKey = normalizeFieldKey(key);\n if (normalizedKey.length === 0) {\n throw new Error(\"Field key must not be empty.\");\n }\n // Remove ALL matches (a hand-authored file may carry duplicate entries for the\n // same normalized key) so no stale duplicate survives the removal.\n const removed: RuntimeFieldDefinition[] = [];\n const fields = file.fields.filter((definition) => {\n if (normalizeFieldKey(definition.key) === normalizedKey) {\n removed.push(definition);\n return false;\n }\n return true;\n });\n if (removed.length === 0) {\n return { file: { fields }, removed: false };\n }\n return { file: { fields }, removed: true, definition: removed[0] };\n}\n\nfunction applyOptionalString(\n definition: RuntimeFieldDefinition,\n key: string,\n value: string | undefined,\n): void {\n const record = definition as unknown as Record<string, unknown>;\n if (value !== undefined && value.length > 0) {\n record[key] = value;\n } else {\n delete record[key];\n }\n}\n\nfunction applyBooleanFlag(\n definition: RuntimeFieldDefinition,\n key: string,\n value: boolean,\n): void {\n const record = definition as unknown as Record<string, unknown>;\n if (value) {\n record[key] = true;\n } else {\n delete record[key];\n }\n}\n"],"names":[],"mappings":"AAAA;;;;GAIG;;;AACH,OAAO,EACL,4BAA4B,EAC5B,yBAAyB,GAC1B,MAAM,sBAAsB,CAAC;AAa9B;;;;;;;;;;;GAWG;AAEH,MAAM,sBAAsB,GAAG,IAAI,GAAG,CAAS,yBAAyB,CAAC,CAAC;AAC1E,MAAM,yBAAyB,GAAG,IAAI,GAAG,CAAS,4BAA4B,CAAC,CAAC;AAEhF,0RAA0R;AAC1R,MAAM,CAAC,MAAM,kBAAkB,GAAwB,IAAI,GAAG,CAAC;IAC7D,IAAI;IACJ,OAAO;IACP,MAAM;IACN,QAAQ;IACR,UAAU;IACV,MAAM;IACN,U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AC;QACV,MAAM,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC;IACrB,CAAC;SAAM,CAAC;QACN,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;IACrB,CAAC;AACH,CAAC","debugId":"d385bfd4-56bb-5b73-9769-b443473e139a"}
1
+ {"version":3,"file":"fields-file.js","sources":["core/schema/fields-file.ts"],"sourceRoot":"/","sourcesContent":["/**\n * @module core/schema/fields-file\n *\n * Resolves configurable schema, fields, statuses, and workflows for Fields File.\n */\nimport {\n RUNTIME_FIELD_COMMAND_VALUES,\n RUNTIME_FIELD_TYPE_VALUES,\n} from \"../../types/index.js\";\nimport type {\n RuntimeFieldCommand,\n RuntimeFieldDefinition,\n RuntimeFieldType,\n} from \"../../types/index.js\";\nimport { FRONT_MATTER_KEY_ORDER } from \"../shared/constants.js\";\n\nexport type {\n RuntimeFieldCommand,\n RuntimeFieldDefinition,\n RuntimeFieldType,\n} from \"../../types/index.js\";\n\n/**\n * Pure logic for the `pm schema add-field` / `pm schema remove-field` commands\n * and the `list-fields` / `show-field` inspectors. The CLI command file\n * (schema.ts) owns IO/governance; everything testable and side-effect-free lives\n * here so it can be coverage-gated to 100%.\n *\n * Custom fields persist at `.agents/pm/schema/fields.json` under the shape\n * `{ fields: RuntimeFieldDefinition[] }`. The runtime merge layer\n * (loadRuntimeSchemaFromOptionalFiles) reads that file and dynamically registers\n * a CLI flag per field on create/update/list/search/context, so this module only\n * has to manage the persisted entries; it never duplicates the registration.\n */\n\nconst RUNTIME_FIELD_TYPE_SET = new Set<string>(RUNTIME_FIELD_TYPE_VALUES);\nconst RUNTIME_FIELD_COMMAND_SET = new Set<string>(RUNTIME_FIELD_COMMAND_VALUES);\n\n/** Built-in front-matter field names a custom field key must never shadow. A custom key that collides with one of these would let `pm create --<key>` write over reserved metadata, so add-field rejects them up front (symmetric with the built-in-type guard in item-types-file.ts). */\nexport const BUILTIN_FIELD_KEYS: ReadonlySet<string> = new Set([\n ...FRONT_MATTER_KEY_ORDER.filter((key) => key !== \"severity\"),\n \"id\",\n \"title\",\n \"type\",\n \"status\",\n \"priority\",\n \"tags\",\n \"assignee\",\n \"parent\",\n \"description\",\n \"body\",\n \"created_at\",\n \"updated_at\",\n \"closed_at\",\n \"author\",\n \"deadline\",\n \"estimate\",\n \"sprint\",\n \"release\",\n \"risk\",\n \"confidence\",\n \"reviewer\",\n \"resolution\",\n \"expected\",\n \"actual\",\n]);\n\n/** The default commands a field is wired onto when `--commands` is omitted, matching the runtime default in runtime-schema.ts (normalizeRuntimeFieldDefinition). */\nconst DEFAULT_FIELD_COMMANDS: RuntimeFieldCommand[] = [\"create\", \"update\"];\n\n/** The shape persisted at `.agents/pm/schema/fields.json`. */\nexport interface FieldsFile {\n /** Value that configures or reports fields for this contract. */\n fields: RuntimeFieldDefinition[];\n}\n\n/** Documents the raw add field input payload exchanged by command, SDK, and package integrations. */\nexport interface RawAddFieldInput {\n /** Value that configures or reports key for this contract. */\n key: string | undefined;\n /** Schema type that determines the shape and validation rules for this value. */\n type?: string;\n /** Value that configures or reports commands for this contract. */\n commands?: string[];\n /** Value that configures or reports description for this contract. */\n description?: string;\n /** Value that configures or reports cli flag for this contract. */\n cliFlag?: string;\n /** Value that configures or reports aliases for this contract. */\n aliases?: string[];\n /** Value that configures or reports required for this contract. */\n required?: boolean;\n /** Value that configures or reports required on create for this contract. */\n requiredOnCreate?: boolean;\n /** Value that configures or reports allow unset for this contract. */\n allowUnset?: boolean;\n /** Value that configures or reports required types for this contract. */\n requiredTypes?: string[];\n}\n\n/** Documents the normalized add field input payload exchanged by command, SDK, and package integrations. */\nexport interface NormalizedAddFieldInput {\n /** Value that configures or reports key for this contract. */\n key: string;\n /** Schema type that determines the shape and validation rules for this value. */\n type: RuntimeFieldType;\n /** Value that configures or reports commands for this contract. */\n commands: RuntimeFieldCommand[];\n /** Value that configures or reports description for this contract. */\n description?: string;\n /** Value that configures or reports cli flag for this contract. */\n cliFlag?: string;\n /** Value that configures or reports cli aliases for this contract. */\n cliAliases: string[];\n /** Value that configures or reports required for this contract. */\n required: boolean;\n /** Value that configures or reports required on create for this contract. */\n requiredOnCreate: boolean;\n /** Value that configures or reports allow unset for this contract. */\n allowUnset: boolean;\n /** Value that configures or reports required types for this contract. */\n requiredTypes: string[];\n}\n\n/** Documents the upsert field result payload exchanged by command, SDK, and package integrations. */\nexport interface UpsertFieldResult {\n /** Value that configures or reports file for this contract. */\n file: FieldsFile;\n /** The definition as stored after the upsert. */\n definition: RuntimeFieldDefinition;\n /** True when an existing definition with the same (normalized) key was replaced. */\n replaced: boolean;\n}\n\n/** Documents the remove field result payload exchanged by command, SDK, and package integrations. */\nexport interface RemoveFieldResult {\n /** Value that configures or reports file for this contract. */\n file: FieldsFile;\n /** True when a matching definition existed and was dropped from the file. */\n removed: boolean;\n /** The removed definition, when one matched the requested key. */\n definition?: RuntimeFieldDefinition;\n}\n\n/** Normalizes a field key using the same rule as runtime-schema.ts: lowercase and collapse any run of whitespace/hyphens into a single underscore. */\nexport function normalizeFieldKey(value: unknown): string {\n return typeof value === \"string\"\n ? value\n .trim()\n .toLowerCase()\n .replaceAll(/[\\s-]+/g, \"_\")\n : \"\";\n}\n\n/** Normalizes a CLI flag token: strip a leading `--`, lowercase, and collapse whitespace/underscore runs to a single hyphen (matches normalizeCliToken in runtime-schema.ts). */\nfunction normalizeCliToken(value: unknown): string {\n if (typeof value !== \"string\") {\n return \"\";\n }\n const collapsed = value\n .trim()\n .toLowerCase()\n .replaceAll(/[\\s_]+/g, \"-\");\n return collapsed.startsWith(\"--\") ? collapsed.slice(2) : collapsed;\n}\n\nfunction keyToDefaultCliFlag(key: string): string {\n return key.replaceAll(\"_\", \"-\");\n}\n\nfunction dedupeCliTokens(values: Iterable<string>, exclude: string): string[] {\n const seen = new Set<string>();\n for (const value of values) {\n const token = normalizeCliToken(value);\n if (token.length > 0 && token !== exclude) {\n seen.add(token);\n }\n }\n return [...seen].sort((left, right) => left.localeCompare(right));\n}\n\nfunction dedupeStringList(values: string[] | undefined): string[] {\n const seen = new Set<string>();\n for (const value of values ?? []) {\n const trimmed = value.trim();\n if (trimmed.length > 0) {\n seen.add(trimmed);\n }\n }\n return [...seen].sort((left, right) => left.localeCompare(right));\n}\n\n/** Normalizes the command allow-list stored for a custom field definition. */\nfunction normalizeFieldCommands(\n rawCommands: string[] | undefined,\n): RuntimeFieldCommand[] {\n const seen = new Set<string>();\n const normalized: RuntimeFieldCommand[] = [];\n for (const rawCommand of rawCommands ?? []) {\n const command = rawCommand.trim().toLowerCase();\n if (command.length === 0) {\n continue;\n }\n if (!RUNTIME_FIELD_COMMAND_SET.has(command)) {\n throw new Error(\n `Invalid field command \"${rawCommand}\". Allowed: ${RUNTIME_FIELD_COMMAND_VALUES.join(\", \")}.`,\n );\n }\n if (!seen.has(command)) {\n seen.add(command);\n normalized.push(command as RuntimeFieldCommand);\n }\n }\n return rawCommands === undefined || normalized.length === 0\n ? [...DEFAULT_FIELD_COMMANDS]\n : normalized;\n}\n\n/** Validates and normalizes raw add-field CLI input. Throws a plain Error with a stable message when the key is missing/empty, collides with a built-in field, or carries an invalid type/command; the CLI layer maps these to PmCliError exit codes. A `string_array` type implies a repeatable field downstream (runtime-schema.ts derives `repeatable`), so no separate repeatable flag is exposed. */\nexport function normalizeAddFieldInput(\n raw: RawAddFieldInput,\n): NormalizedAddFieldInput {\n const key = normalizeFieldKey(raw.key);\n if (key.length === 0) {\n throw new Error(\"Field key must not be empty.\");\n }\n if (BUILTIN_FIELD_KEYS.has(key)) {\n throw new Error(\n `Cannot define custom field \"${key}\": custom schema field \"${key}\" collides with built-in item metadata \"${key}\". Rename the custom field with a project-specific prefix. Reserved fields: ${[...BUILTIN_FIELD_KEYS].sort((left, right) => left.localeCompare(right)).join(\", \")}.`,\n );\n }\n\n const typeCandidate =\n typeof raw.type === \"string\" && raw.type.trim().length > 0\n ? raw.type.trim().toLowerCase()\n : \"string\";\n if (!RUNTIME_FIELD_TYPE_SET.has(typeCandidate)) {\n throw new Error(\n `Invalid field type \"${raw.type}\". Allowed: ${RUNTIME_FIELD_TYPE_VALUES.join(\", \")}.`,\n );\n }\n const type = typeCandidate as RuntimeFieldType;\n\n const commands = normalizeFieldCommands(raw.commands);\n\n const cliFlagToken = normalizeCliToken(raw.cliFlag);\n const cliFlag =\n cliFlagToken.length > 0 && cliFlagToken !== keyToDefaultCliFlag(key)\n ? cliFlagToken\n : undefined;\n const effectiveFlag = cliFlag ?? keyToDefaultCliFlag(key);\n const cliAliases = dedupeCliTokens(raw.aliases ?? [], effectiveFlag);\n\n const description = raw.description?.trim();\n return {\n key,\n type,\n commands,\n description:\n description && description.length > 0 ? description : undefined,\n cliFlag,\n cliAliases,\n required: raw.required === true,\n requiredOnCreate: raw.requiredOnCreate === true,\n // allow_unset defaults to true (omitted) and is only persisted when an\n // operator explicitly disables it with --no-allow-unset (allowUnset === false).\n allowUnset: raw.allowUnset !== false,\n requiredTypes: dedupeStringList(raw.requiredTypes),\n };\n}\n\nfunction selectFieldsArray(parsed: unknown): unknown[] | undefined {\n if (Array.isArray(parsed)) {\n return parsed;\n }\n if (typeof parsed !== \"object\" || parsed === null) {\n return undefined;\n }\n const record = parsed as Record<string, unknown>;\n if (Array.isArray(record.fields)) {\n return record.fields;\n }\n if (Array.isArray(record.definitions)) {\n return record.definitions;\n }\n return undefined;\n}\n\nfunction extractFieldDefinitions(parsed: unknown): RuntimeFieldDefinition[] {\n const candidate = selectFieldsArray(parsed);\n if (!candidate) {\n return [];\n }\n const definitions: RuntimeFieldDefinition[] = [];\n for (const entry of candidate) {\n if (typeof entry !== \"object\" || entry === null || Array.isArray(entry)) {\n continue;\n }\n const record = entry as Record<string, unknown>;\n if (typeof record.key !== \"string\" || record.key.trim().length === 0) {\n continue;\n }\n definitions.push(record as unknown as RuntimeFieldDefinition);\n }\n return definitions;\n}\n\n/** Coerces an arbitrary parsed value from fields.json into a FieldsFile. Accepts the canonical `{ fields: [...] }` shape, a bare array, or a `{ definitions: [...] }` form, and tolerates a missing/invalid file by returning an empty fields list. */\nexport function parseFieldsFile(raw: string | null | undefined): FieldsFile {\n if (raw === null || raw === undefined || raw.trim().length === 0) {\n return { fields: [] };\n }\n let parsed: unknown;\n try {\n parsed = JSON.parse(raw) as unknown;\n } catch {\n throw new Error(\"schema/fields.json contains invalid JSON.\");\n }\n return { fields: extractFieldDefinitions(parsed) };\n}\n\n/** Serializes the fields file with a trailing newline (matches the rest of the schema scaffold files written by pm). */\nexport function serializeFieldsFile(file: FieldsFile): string {\n return `${JSON.stringify({ fields: file.fields }, null, 2)}\\n`;\n}\n\n/** Idempotent UPSERT of a custom field into the parsed file. Matching is by normalized key. When a definition already exists, the supplied input fully replaces its add-field-managed attributes (type/commands/description/flags/ required flags) while preserving any unrelated keys the file may carry; any `metadata_key` already stored is preserved so existing item data keeps mapping to the same front-matter column. */\nexport function upsertField(\n file: FieldsFile,\n input: NormalizedAddFieldInput,\n): UpsertFieldResult {\n // Match by normalized key. A hand-authored file may carry more than one entry\n // for the same key, so drop ALL matches and re-insert a single merged result\n // (collapsing duplicates) rather than only rewriting the first occurrence. The\n // first existing match seeds preserved attributes (e.g. metadata_key).\n const existing = file.fields.find(\n (definition) => normalizeFieldKey(definition.key) === input.key,\n );\n const replaced = existing !== undefined;\n const fields = file.fields.filter(\n (definition) => normalizeFieldKey(definition.key) !== input.key,\n );\n\n const next: RuntimeFieldDefinition = {\n ...existing,\n key: input.key,\n type: input.type,\n commands: [...input.commands],\n };\n applyOptionalString(next, \"description\", input.description);\n applyOptionalString(next, \"cli_flag\", input.cliFlag);\n if (input.cliAliases.length > 0) {\n next.cli_aliases = [...input.cliAliases];\n } else {\n delete next.cli_aliases;\n }\n applyBooleanFlag(next, \"required\", input.required);\n applyBooleanFlag(next, \"required_on_create\", input.requiredOnCreate);\n // allow_unset defaults true; only persist the explicit false override.\n if (input.allowUnset === false) {\n next.allow_unset = false;\n } else {\n delete next.allow_unset;\n }\n if (input.requiredTypes.length > 0) {\n next.required_types = [...input.requiredTypes];\n } else {\n delete next.required_types;\n }\n\n fields.push(next);\n fields.sort((left, right) =>\n normalizeFieldKey(left.key).localeCompare(normalizeFieldKey(right.key)),\n );\n\n return {\n file: { fields },\n definition: next,\n replaced,\n };\n}\n\n/** Removes a custom field definition from the parsed file by key (normalized). Throws a plain Error when `key` is empty. Returns `removed: false` when no matching definition exists so the CLI layer can treat the call as an idempotent no-op. */\nexport function removeField(\n file: FieldsFile,\n key: string | undefined,\n): RemoveFieldResult {\n const normalizedKey = normalizeFieldKey(key);\n if (normalizedKey.length === 0) {\n throw new Error(\"Field key must not be empty.\");\n }\n // Remove ALL matches (a hand-authored file may carry duplicate entries for the\n // same normalized key) so no stale duplicate survives the removal.\n const removed: RuntimeFieldDefinition[] = [];\n const fields = file.fields.filter((definition) => {\n if (normalizeFieldKey(definition.key) === normalizedKey) {\n removed.push(definition);\n return false;\n }\n return true;\n });\n if (removed.length === 0) {\n return { file: { fields }, removed: false };\n }\n return { file: { fields }, removed: true, definition: removed[0] };\n}\n\nfunction applyOptionalString(\n definition: RuntimeFieldDefinition,\n key: string,\n value: string | undefined,\n): void {\n const record = definition as unknown as Record<string, unknown>;\n if (value !== undefined && value.length > 0) {\n record[key] = value;\n } else {\n delete record[key];\n }\n}\n\nfunction applyBooleanFlag(\n definition: RuntimeFieldDefinition,\n key: string,\n value: boolean,\n): void {\n const record = definition as unknown as Record<string, unknown>;\n if (value) {\n record[key] = true;\n } else {\n delete record[key];\n }\n}\n"],"names":[],"mappings":"AAAA;;;;GAIG;;;AACH,OAAO,EACL,4BAA4B,EAC5B,yBAAyB,GAC1B,MAAM,sBAAsB,CAAC;AAM9B,OAAO,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAQhE;;;;;;;;;;;GAWG;AAEH,MAAM,sBAAsB,GAAG,IAAI,GAAG,CAAS,yBAAyB,CAAC,CAAC;AAC1E,MAAM,yBAAyB,GAAG,IAAI,GAAG,CAAS,4BAA4B,CAAC,CAAC;AAEhF,0RAA0R;AAC1R,MAAM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AC1B,UAAkC,EAClC,GAAW,EACX,KAAyB;IAEzB,MAAM,MAAM,GAAG,UAAgD,CAAC;IAChE,IAAI,KAAK,KAAK,SAAS,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAC5C,MAAM,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC;IACtB,CAAC;SAAM,CAAC;QACN,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;IACrB,CAAC;AACH,CAAC;AAED,SAAS,gBAAgB,CACvB,UAAkC,EAClC,GAAW,EACX,KAAc;IAEd,MAAM,MAAM,GAAG,UAAgD,CAAC;IAChE,IAAI,KAAK,EAAE,CAAC;QACV,MAAM,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC;IACrB,CAAC;SAAM,CAAC;QACN,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;IACrB,CAAC;AACH,CAAC","debugId":"5b67948f-d13c-52e4-8e6a-6ba23768d589"}
@@ -7,7 +7,7 @@
7
7
  * flag surface stays single-sourced across the CLI, SDK, and MCP boundaries.
8
8
  */
9
9
 
10
- !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]="74cc7aa4-edb9-57ae-88c3-f647aa0ea552")}catch(e){}}();
10
+ !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]="e26b7593-5802-5d28-9e65-f7437a3c6c65")}catch(e){}}();
11
11
  import { normalizeUniqueStringList } from "./string-lists.js";
12
12
  function normalizeFlagAliasKey(flag) {
13
13
  if (!flag.startsWith("--")) {
@@ -435,6 +435,7 @@ export const PLAN_FLAG_CONTRACTS = [
435
435
  { flag: "--validation-command", aliases: ["--validation_command"] },
436
436
  { flag: "--validation-expected", aliases: ["--validation_expected"] },
437
437
  { flag: "--depth" },
438
+ { flag: "--field" },
438
439
  { flag: "--fields", list: true },
439
440
  { flag: "--steps" },
440
441
  { flag: "--materialize-type", aliases: ["--materialize_type"] },
@@ -685,6 +686,15 @@ export const CLAIM_FLAG_CONTRACTS = [
685
686
  { flag: "--force" },
686
687
  { flag: "--if-available" },
687
688
  { flag: "--next" },
689
+ { flag: "--type" },
690
+ { flag: "--tag" },
691
+ { flag: "--priority" },
692
+ { flag: "--assignee-filter" },
693
+ { flag: "--parent" },
694
+ { flag: "--sprint" },
695
+ { flag: "--release" },
696
+ { flag: "--max-attempts" },
697
+ { flag: "--include-decisions" },
688
698
  ];
689
699
  /** Public contract for restore flag contracts, shared by SDK and presentation-layer consumers. */
690
700
  export const RESTORE_FLAG_CONTRACTS = [
@@ -1563,4 +1573,4 @@ export function toCompletionFlagString(flagContracts, includeGlobal = true) {
1563
1573
  return normalizeUniqueStringList(all).join(" ");
1564
1574
  }
1565
1575
  //# sourceMappingURL=flag-contracts.js.map
1566
- //# debugId=74cc7aa4-edb9-57ae-88c3-f647aa0ea552
1576
+ //# debugId=e26b7593-5802-5d28-9e65-f7437a3c6c65