@unbrained/pm-cli 2026.6.23 → 2026.6.30

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 (716) hide show
  1. package/CHANGELOG.md +120 -0
  2. package/CONTRIBUTING.md +30 -0
  3. package/README.md +16 -3
  4. package/dist/cli/commander-usage.js +3 -3
  5. package/dist/cli/commander-usage.js.map +1 -1
  6. package/dist/cli/commands/aggregate.js +8 -7
  7. package/dist/cli/commands/aggregate.js.map +1 -1
  8. package/dist/cli/commands/close.d.ts +2 -4
  9. package/dist/cli/commands/close.js +5 -17
  10. package/dist/cli/commands/close.js.map +1 -1
  11. package/dist/cli/commands/completion.js +158 -9
  12. package/dist/cli/commands/completion.js.map +1 -1
  13. package/dist/cli/commands/config.d.ts +1 -1
  14. package/dist/cli/commands/config.js +2 -2
  15. package/dist/cli/commands/config.js.map +1 -1
  16. package/dist/cli/commands/context.d.ts +31 -4
  17. package/dist/cli/commands/context.js +33 -10
  18. package/dist/cli/commands/context.js.map +1 -1
  19. package/dist/cli/commands/contracts.js +48 -8
  20. package/dist/cli/commands/contracts.js.map +1 -1
  21. package/dist/cli/commands/create.d.ts +1 -6
  22. package/dist/cli/commands/create.js +10 -155
  23. package/dist/cli/commands/create.js.map +1 -1
  24. package/dist/cli/commands/extension/describe.d.ts +15 -0
  25. package/dist/cli/commands/extension/describe.js +48 -2
  26. package/dist/cli/commands/extension/describe.js.map +1 -1
  27. package/dist/cli/commands/extension/doctor.js +5 -2
  28. package/dist/cli/commands/extension/doctor.js.map +1 -1
  29. package/dist/cli/commands/extension/install-sources.js +37 -7
  30. package/dist/cli/commands/extension/install-sources.js.map +1 -1
  31. package/dist/cli/commands/extension/scaffold.d.ts +31 -8
  32. package/dist/cli/commands/extension/scaffold.js +1956 -182
  33. package/dist/cli/commands/extension/scaffold.js.map +1 -1
  34. package/dist/cli/commands/extension.d.ts +22 -2
  35. package/dist/cli/commands/extension.js +189 -13
  36. package/dist/cli/commands/extension.js.map +1 -1
  37. package/dist/cli/commands/index.d.ts +3 -1
  38. package/dist/cli/commands/index.js +5 -3
  39. package/dist/cli/commands/index.js.map +1 -1
  40. package/dist/cli/commands/item-filter-options.d.ts +63 -0
  41. package/dist/cli/commands/item-filter-options.js +10 -0
  42. package/dist/cli/commands/item-filter-options.js.map +1 -0
  43. package/dist/cli/commands/legacy-none-tokens.d.ts +14 -0
  44. package/dist/cli/commands/legacy-none-tokens.js +31 -2
  45. package/dist/cli/commands/legacy-none-tokens.js.map +1 -1
  46. package/dist/cli/commands/linked-artifacts.d.ts +7 -0
  47. package/dist/cli/commands/linked-artifacts.js +12 -2
  48. package/dist/cli/commands/linked-artifacts.js.map +1 -1
  49. package/dist/cli/commands/list.d.ts +16 -39
  50. package/dist/cli/commands/list.js +127 -118
  51. package/dist/cli/commands/list.js.map +1 -1
  52. package/dist/cli/commands/next.d.ts +98 -0
  53. package/dist/cli/commands/next.js +304 -0
  54. package/dist/cli/commands/next.js.map +1 -0
  55. package/dist/cli/commands/profile.d.ts +208 -0
  56. package/dist/cli/commands/profile.js +418 -0
  57. package/dist/cli/commands/profile.js.map +1 -0
  58. package/dist/cli/commands/repeatable-metadata-parsers.js +12 -13
  59. package/dist/cli/commands/repeatable-metadata-parsers.js.map +1 -1
  60. package/dist/cli/commands/schema.d.ts +7 -0
  61. package/dist/cli/commands/schema.js +9 -3
  62. package/dist/cli/commands/schema.js.map +1 -1
  63. package/dist/cli/commands/search.d.ts +2 -39
  64. package/dist/cli/commands/search.js +104 -106
  65. package/dist/cli/commands/search.js.map +1 -1
  66. package/dist/cli/commands/shared-unset-fields.d.ts +30 -0
  67. package/dist/cli/commands/shared-unset-fields.js +161 -0
  68. package/dist/cli/commands/shared-unset-fields.js.map +1 -0
  69. package/dist/cli/commands/stats.js +15 -3
  70. package/dist/cli/commands/stats.js.map +1 -1
  71. package/dist/cli/commands/test.js +9 -5
  72. package/dist/cli/commands/test.js.map +1 -1
  73. package/dist/cli/commands/update.d.ts +1 -6
  74. package/dist/cli/commands/update.js +12 -157
  75. package/dist/cli/commands/update.js.map +1 -1
  76. package/dist/cli/commands/validate.js +20 -5
  77. package/dist/cli/commands/validate.js.map +1 -1
  78. package/dist/cli/help-content.js +26 -2
  79. package/dist/cli/help-content.js.map +1 -1
  80. package/dist/cli/help-json-payload.js +3 -3
  81. package/dist/cli/help-json-payload.js.map +1 -1
  82. package/dist/cli/main.js +27 -12
  83. package/dist/cli/main.js.map +1 -1
  84. package/dist/cli/register-list-query.js +42 -3
  85. package/dist/cli/register-list-query.js.map +1 -1
  86. package/dist/cli/register-mutation.js +86 -2
  87. package/dist/cli/register-mutation.js.map +1 -1
  88. package/dist/cli/register-setup.js +67 -6
  89. package/dist/cli/register-setup.js.map +1 -1
  90. package/dist/cli/registration-helpers.d.ts +9 -1
  91. package/dist/cli/registration-helpers.js +34 -3
  92. package/dist/cli/registration-helpers.js.map +1 -1
  93. package/dist/cli-bundle/chunks/activity-EJBMXUBH.js +16 -0
  94. package/dist/cli-bundle/chunks/{activity-H2LMOSSW.js → activity-MVSEND6D.js} +9 -11
  95. package/dist/cli-bundle/chunks/{aggregate-R725FC3S.js → aggregate-MOC4TR2G.js} +16 -17
  96. package/dist/cli-bundle/chunks/aggregate-MOC4TR2G.js.map +1 -0
  97. package/dist/cli-bundle/chunks/{aggregate-EGJLZQBI.js → aggregate-XJHLZQ5X.js} +15 -16
  98. package/dist/cli-bundle/chunks/aggregate-XJHLZQ5X.js.map +7 -0
  99. package/dist/cli-bundle/chunks/{append-5J345QGU.js → append-KDHT4GHI.js} +10 -12
  100. package/dist/cli-bundle/chunks/{append-5J345QGU.js.map → append-KDHT4GHI.js.map} +1 -1
  101. package/dist/cli-bundle/chunks/{append-O5HPBMRN.js → append-LEDBAM3K.js} +8 -10
  102. package/dist/cli-bundle/chunks/{append-O5HPBMRN.js.map → append-LEDBAM3K.js.map} +1 -1
  103. package/dist/cli-bundle/chunks/{chunk-IB3GYLQE.js → chunk-3JWQCLR5.js} +3 -3
  104. package/dist/cli-bundle/chunks/{chunk-2A34E3BA.js → chunk-4TXTVZL3.js} +2 -2
  105. package/dist/cli-bundle/chunks/{chunk-G6N5VEOK.js → chunk-4YIMPANT.js} +3 -3
  106. package/dist/cli-bundle/chunks/{chunk-7AUB5HNA.js → chunk-53ARXF2O.js} +9 -11
  107. package/dist/cli-bundle/chunks/{chunk-7AUB5HNA.js.map → chunk-53ARXF2O.js.map} +1 -1
  108. package/dist/cli-bundle/chunks/chunk-5ABGFWR4.js +116 -0
  109. package/dist/cli-bundle/chunks/chunk-5ABGFWR4.js.map +1 -0
  110. package/dist/cli-bundle/chunks/{chunk-2BFPAUAF.js → chunk-5IRVSKPS.js} +2990 -2890
  111. package/dist/cli-bundle/chunks/chunk-5IRVSKPS.js.map +1 -0
  112. package/dist/cli-bundle/chunks/{chunk-JR2LV3M4.js → chunk-5T6WPLRO.js} +233 -190
  113. package/dist/cli-bundle/chunks/chunk-5T6WPLRO.js.map +7 -0
  114. package/dist/cli-bundle/chunks/{chunk-CKGNPJAG.js → chunk-6T5ZIWBS.js} +3011 -2888
  115. package/dist/cli-bundle/chunks/chunk-6T5ZIWBS.js.map +7 -0
  116. package/dist/cli-bundle/chunks/{chunk-QH3PJYON.js → chunk-6YRAMXRS.js} +111 -114
  117. package/dist/cli-bundle/chunks/chunk-6YRAMXRS.js.map +1 -0
  118. package/dist/cli-bundle/chunks/{chunk-7XGQXHFB.js → chunk-73PTKMAE.js} +3 -3
  119. package/dist/cli-bundle/chunks/{chunk-Y4SUQQYH.js → chunk-74PUWBGN.js} +53 -54
  120. package/dist/cli-bundle/chunks/chunk-74PUWBGN.js.map +1 -0
  121. package/dist/cli-bundle/chunks/{chunk-T5472OMV.js → chunk-7L6TXOOC.js} +4 -6
  122. package/dist/cli-bundle/chunks/{chunk-T5472OMV.js.map → chunk-7L6TXOOC.js.map} +1 -1
  123. package/dist/cli-bundle/chunks/chunk-7M2HAZEB.js +17 -0
  124. package/dist/cli-bundle/chunks/chunk-7M2HAZEB.js.map +7 -0
  125. package/dist/cli-bundle/chunks/{chunk-3VY3YQO6.js → chunk-7RIJGN4R.js} +2 -2
  126. package/dist/cli-bundle/chunks/{chunk-G6PYHBBR.js → chunk-7WDETKGP.js} +192 -113
  127. package/dist/cli-bundle/chunks/chunk-7WDETKGP.js.map +7 -0
  128. package/dist/cli-bundle/chunks/{chunk-AONIHR2C.js → chunk-A3UNLXNJ.js} +40 -260
  129. package/dist/cli-bundle/chunks/chunk-A3UNLXNJ.js.map +7 -0
  130. package/dist/cli-bundle/chunks/{chunk-4KD54S3Z.js → chunk-AWN4PPH5.js} +10 -14
  131. package/dist/cli-bundle/chunks/{chunk-4KD54S3Z.js.map → chunk-AWN4PPH5.js.map} +1 -1
  132. package/dist/cli-bundle/chunks/{chunk-FXR67XVQ.js → chunk-BN3CWK6G.js} +2 -2
  133. package/dist/cli-bundle/chunks/{chunk-KFWBJPSG.js → chunk-BOWQWXLI.js} +12 -24
  134. package/dist/cli-bundle/chunks/chunk-BOWQWXLI.js.map +1 -0
  135. package/dist/cli-bundle/chunks/{chunk-4BHT5VDC.js → chunk-C2KCIZKZ.js} +2 -2
  136. package/dist/cli-bundle/chunks/{chunk-O6LLO73I.js → chunk-CHRNYKNI.js} +2 -2
  137. package/dist/cli-bundle/chunks/{chunk-UELRKQQU.js → chunk-CY5IJMUM.js} +1239 -495
  138. package/dist/cli-bundle/chunks/chunk-CY5IJMUM.js.map +1 -0
  139. package/dist/cli-bundle/chunks/chunk-CZVISY5A.js +87 -0
  140. package/dist/cli-bundle/chunks/chunk-CZVISY5A.js.map +7 -0
  141. package/dist/cli-bundle/chunks/{chunk-7K2XXO4I.js → chunk-D5LYZVGB.js} +7 -9
  142. package/dist/cli-bundle/chunks/{chunk-7K2XXO4I.js.map → chunk-D5LYZVGB.js.map} +1 -1
  143. package/dist/cli-bundle/chunks/{chunk-ZQ3ZVXX2.js → chunk-D6USKAMA.js} +2 -2
  144. package/dist/cli-bundle/chunks/{context-BLBD3PUB.js → chunk-DJDXAU74.js} +19 -21
  145. package/dist/cli-bundle/chunks/chunk-DJDXAU74.js.map +7 -0
  146. package/dist/cli-bundle/chunks/{chunk-WZQWHN4R.js → chunk-DLDCPF5X.js} +3 -3
  147. package/dist/cli-bundle/chunks/{chunk-HFFUQR73.js → chunk-DORJSBGJ.js} +35 -9
  148. package/dist/cli-bundle/chunks/chunk-DORJSBGJ.js.map +7 -0
  149. package/dist/cli-bundle/chunks/{chunk-XVF4YARA.js → chunk-DRPF274X.js} +5 -7
  150. package/dist/cli-bundle/chunks/{chunk-XVF4YARA.js.map → chunk-DRPF274X.js.map} +2 -2
  151. package/dist/cli-bundle/chunks/{chunk-QL5RVYOA.js → chunk-DU66JUGT.js} +16 -14
  152. package/dist/cli-bundle/chunks/chunk-DU66JUGT.js.map +7 -0
  153. package/dist/cli-bundle/chunks/{chunk-UVC5LOR7.js → chunk-E2Q2ULMR.js} +4 -4
  154. package/dist/cli-bundle/chunks/{chunk-U2Z5YUSO.js → chunk-EVWYAG46.js} +9 -11
  155. package/dist/cli-bundle/chunks/{chunk-U2Z5YUSO.js.map → chunk-EVWYAG46.js.map} +1 -1
  156. package/dist/cli-bundle/chunks/{chunk-5VOINNKT.js → chunk-F6VH3LFC.js} +2 -2
  157. package/dist/cli-bundle/chunks/{chunk-VFAQ4LMN.js → chunk-F7G53BOA.js} +18 -11
  158. package/dist/cli-bundle/chunks/chunk-F7G53BOA.js.map +7 -0
  159. package/dist/cli-bundle/chunks/{chunk-Q2KNGP7C.js → chunk-FBZ5XAAF.js} +9 -11
  160. package/dist/cli-bundle/chunks/{chunk-Q2KNGP7C.js.map → chunk-FBZ5XAAF.js.map} +1 -1
  161. package/dist/cli-bundle/chunks/{chunk-H4IIJDE4.js → chunk-FDEVKXC4.js} +2 -2
  162. package/dist/cli-bundle/chunks/{chunk-7UGEAPRY.js → chunk-GF7EAR22.js} +10 -14
  163. package/dist/cli-bundle/chunks/{chunk-7UGEAPRY.js.map → chunk-GF7EAR22.js.map} +1 -1
  164. package/dist/cli-bundle/chunks/{context-DHLVPXN3.js → chunk-HIBK6H4S.js} +20 -22
  165. package/dist/cli-bundle/chunks/chunk-HIBK6H4S.js.map +1 -0
  166. package/dist/cli-bundle/chunks/{chunk-34EONI5F.js → chunk-HUYYMTGW.js} +2 -2
  167. package/dist/cli-bundle/chunks/chunk-IBMFIKVS.js +14 -0
  168. package/dist/cli-bundle/chunks/chunk-IBMFIKVS.js.map +1 -0
  169. package/dist/cli-bundle/chunks/{chunk-BB6MDVNQ.js → chunk-IBU2LLWM.js} +8 -12
  170. package/dist/cli-bundle/chunks/{chunk-BB6MDVNQ.js.map → chunk-IBU2LLWM.js.map} +1 -1
  171. package/dist/cli-bundle/chunks/{chunk-55ISXAQH.js → chunk-IDYCAK35.js} +53 -54
  172. package/dist/cli-bundle/chunks/chunk-IDYCAK35.js.map +7 -0
  173. package/dist/cli-bundle/chunks/{chunk-M4T5DXD5.js → chunk-IF4ERU6A.js} +7 -9
  174. package/dist/cli-bundle/chunks/{chunk-M4T5DXD5.js.map → chunk-IF4ERU6A.js.map} +1 -1
  175. package/dist/cli-bundle/chunks/{chunk-CIIK67GW.js → chunk-IHXXUIXS.js} +4 -4
  176. package/dist/cli-bundle/chunks/chunk-IZQOJR2B.js +2459 -0
  177. package/dist/cli-bundle/chunks/chunk-IZQOJR2B.js.map +7 -0
  178. package/dist/cli-bundle/chunks/{chunk-SBQTAVJZ.js → chunk-JIP67N2K.js} +3 -3
  179. package/dist/cli-bundle/chunks/chunk-JJ4SG243.js +119 -0
  180. package/dist/cli-bundle/chunks/chunk-JJ4SG243.js.map +7 -0
  181. package/dist/cli-bundle/chunks/{chunk-TQZH6OD6.js → chunk-JTRKME24.js} +11 -13
  182. package/dist/cli-bundle/chunks/{chunk-TQZH6OD6.js.map → chunk-JTRKME24.js.map} +1 -1
  183. package/dist/cli-bundle/chunks/{chunk-WBRKK5QR.js → chunk-JVQ7UOYC.js} +6 -8
  184. package/dist/cli-bundle/chunks/{chunk-WBRKK5QR.js.map → chunk-JVQ7UOYC.js.map} +1 -1
  185. package/dist/cli-bundle/chunks/{chunk-KQMUV6LX.js → chunk-JZG5ADVE.js} +191 -98
  186. package/dist/cli-bundle/chunks/chunk-JZG5ADVE.js.map +1 -0
  187. package/dist/cli-bundle/chunks/{chunk-46G6RSB6.js → chunk-K46GQ265.js} +17 -15
  188. package/dist/cli-bundle/chunks/chunk-K46GQ265.js.map +1 -0
  189. package/dist/cli-bundle/chunks/{chunk-5UVVASSA.js → chunk-KGQ3W65B.js} +100 -35
  190. package/dist/cli-bundle/chunks/chunk-KGQ3W65B.js.map +1 -0
  191. package/dist/cli-bundle/chunks/{chunk-2T3JG6V4.js → chunk-KRASIL6M.js} +2 -2
  192. package/dist/cli-bundle/chunks/{chunk-SR3EKWZG.js → chunk-KTMMTOIP.js} +127 -127
  193. package/dist/cli-bundle/chunks/chunk-KTMMTOIP.js.map +7 -0
  194. package/dist/cli-bundle/chunks/{chunk-DT5LPYOD.js → chunk-KYDYQMNW.js} +5 -7
  195. package/dist/cli-bundle/chunks/{chunk-DT5LPYOD.js.map → chunk-KYDYQMNW.js.map} +1 -1
  196. package/dist/cli-bundle/chunks/{chunk-IPKJ6B36.js → chunk-LBH7UYKY.js} +106 -34
  197. package/dist/cli-bundle/chunks/chunk-LBH7UYKY.js.map +7 -0
  198. package/dist/cli-bundle/chunks/{chunk-P77P2ILI.js → chunk-MLHX6DN5.js} +2 -2
  199. package/dist/cli-bundle/chunks/{chunk-YUDJD3XO.js → chunk-NIBP3I7A.js} +36 -10
  200. package/dist/cli-bundle/chunks/chunk-NIBP3I7A.js.map +1 -0
  201. package/dist/cli-bundle/chunks/{schema-RBTJ2YXW.js → chunk-NO6Y6FB2.js} +144 -67
  202. package/dist/cli-bundle/chunks/chunk-NO6Y6FB2.js.map +7 -0
  203. package/dist/cli-bundle/chunks/{chunk-2CKH2LMV.js → chunk-OB3RJV5F.js} +2 -2
  204. package/dist/cli-bundle/chunks/chunk-OKQ22KTH.js +379 -0
  205. package/dist/cli-bundle/chunks/chunk-OKQ22KTH.js.map +1 -0
  206. package/dist/cli-bundle/chunks/{chunk-FIGAZ4Y7.js → chunk-OUQ5JEFM.js} +3 -3
  207. package/dist/cli-bundle/chunks/{chunk-NK3UPBVG.js → chunk-QE5UFCCO.js} +2 -2
  208. package/dist/cli-bundle/chunks/{chunk-MJTINN54.js → chunk-RM6MHL6A.js} +110 -113
  209. package/dist/cli-bundle/chunks/chunk-RM6MHL6A.js.map +7 -0
  210. package/dist/cli-bundle/chunks/{chunk-LRKKONT2.js → chunk-RPRW26NG.js} +12 -16
  211. package/dist/cli-bundle/chunks/{chunk-LRKKONT2.js.map → chunk-RPRW26NG.js.map} +1 -1
  212. package/dist/cli-bundle/chunks/{chunk-WM5ZVBPE.js → chunk-SJZTPVFT.js} +4 -4
  213. package/dist/cli-bundle/chunks/{chunk-MJTSZKK5.js → chunk-SNUK7H5J.js} +1363 -605
  214. package/dist/cli-bundle/chunks/chunk-SNUK7H5J.js.map +7 -0
  215. package/dist/cli-bundle/chunks/chunk-T7ZMQI4J.js +2435 -0
  216. package/dist/cli-bundle/chunks/chunk-T7ZMQI4J.js.map +1 -0
  217. package/dist/cli-bundle/chunks/{chunk-W72GHSJE.js → chunk-TQ6E76BE.js} +11 -13
  218. package/dist/cli-bundle/chunks/{chunk-W72GHSJE.js.map → chunk-TQ6E76BE.js.map} +1 -1
  219. package/dist/cli-bundle/chunks/{chunk-ZRK4O56R.js → chunk-UB3V5WUI.js} +225 -189
  220. package/dist/cli-bundle/chunks/chunk-UB3V5WUI.js.map +1 -0
  221. package/dist/cli-bundle/chunks/{chunk-SKN7LC5W.js → chunk-UFKNF23C.js} +11 -23
  222. package/dist/cli-bundle/chunks/chunk-UFKNF23C.js.map +7 -0
  223. package/dist/cli-bundle/chunks/{chunk-VAYA4XFX.js → chunk-V3KLX7U7.js} +3 -3
  224. package/dist/cli-bundle/chunks/{chunk-GAJVRGGA.js → chunk-VD3LKZFX.js} +41 -254
  225. package/dist/cli-bundle/chunks/chunk-VD3LKZFX.js.map +1 -0
  226. package/dist/cli-bundle/chunks/{chunk-AD3A7ZD6.js → chunk-VMY7MZEM.js} +10 -14
  227. package/dist/cli-bundle/chunks/{chunk-AD3A7ZD6.js.map → chunk-VMY7MZEM.js.map} +1 -1
  228. package/dist/cli-bundle/chunks/chunk-VZDBVEZR.js +382 -0
  229. package/dist/cli-bundle/chunks/chunk-VZDBVEZR.js.map +7 -0
  230. package/dist/cli-bundle/chunks/{chunk-CE5P2NQR.js → chunk-WFJZDUM7.js} +19 -12
  231. package/dist/cli-bundle/chunks/chunk-WFJZDUM7.js.map +1 -0
  232. package/dist/cli-bundle/chunks/{schema-MNTAVQCY.js → chunk-WTRUDJ3R.js} +136 -66
  233. package/dist/cli-bundle/chunks/chunk-WTRUDJ3R.js.map +1 -0
  234. package/dist/cli-bundle/chunks/{chunk-T72AZDBA.js → chunk-YEDFE4DC.js} +6 -8
  235. package/dist/cli-bundle/chunks/{chunk-T72AZDBA.js.map → chunk-YEDFE4DC.js.map} +1 -1
  236. package/dist/cli-bundle/chunks/chunk-YJIEJRZB.js +84 -0
  237. package/dist/cli-bundle/chunks/chunk-YJIEJRZB.js.map +1 -0
  238. package/dist/cli-bundle/chunks/{chunk-H2IP4QLJ.js → chunk-Z55WX4IQ.js} +12 -16
  239. package/dist/cli-bundle/chunks/{chunk-H2IP4QLJ.js.map → chunk-Z55WX4IQ.js.map} +1 -1
  240. package/dist/cli-bundle/chunks/{chunk-2RDVQEWV.js → chunk-Z5BM2FKQ.js} +4 -4
  241. package/dist/cli-bundle/chunks/{chunk-66MEDTUD.js → chunk-ZEATCVAC.js} +2 -2
  242. package/dist/cli-bundle/chunks/{chunk-NCVCO3NZ.js → chunk-ZFIEEDTJ.js} +3 -3
  243. package/dist/cli-bundle/chunks/{chunk-7SV63ZHD.js → chunk-ZIE6WXJ2.js} +128 -128
  244. package/dist/cli-bundle/chunks/chunk-ZIE6WXJ2.js.map +1 -0
  245. package/dist/cli-bundle/chunks/{claim-4KHAA2RN.js → claim-6NINZYB3.js} +10 -12
  246. package/dist/cli-bundle/chunks/{claim-4KHAA2RN.js.map → claim-6NINZYB3.js.map} +1 -1
  247. package/dist/cli-bundle/chunks/{claim-CSPJFLNH.js → claim-HMCLSLUE.js} +8 -10
  248. package/dist/cli-bundle/chunks/{claim-CSPJFLNH.js.map → claim-HMCLSLUE.js.map} +1 -1
  249. package/dist/cli-bundle/chunks/close-37KEHLYM.js +14 -0
  250. package/dist/cli-bundle/chunks/{close-W56IOGYG.js → close-OP3LK7Z2.js} +7 -8
  251. package/dist/cli-bundle/chunks/{close-many-BX5DCSVV.js → close-many-BFMP6HHK.js} +15 -17
  252. package/dist/cli-bundle/chunks/{close-many-BX5DCSVV.js.map → close-many-BFMP6HHK.js.map} +1 -1
  253. package/dist/cli-bundle/chunks/{close-many-TQU5F4E4.js → close-many-CXJBOWWY.js} +17 -19
  254. package/dist/cli-bundle/chunks/{close-many-TQU5F4E4.js.map → close-many-CXJBOWWY.js.map} +1 -1
  255. package/dist/cli-bundle/chunks/{comments-VRECH75R.js → comments-ETHABIY6.js} +9 -11
  256. package/dist/cli-bundle/chunks/{comments-VRECH75R.js.map → comments-ETHABIY6.js.map} +1 -1
  257. package/dist/cli-bundle/chunks/{comments-U5KUC4EU.js → comments-MU2WMBUY.js} +11 -13
  258. package/dist/cli-bundle/chunks/{comments-U5KUC4EU.js.map → comments-MU2WMBUY.js.map} +1 -1
  259. package/dist/cli-bundle/chunks/{config-D3OKQO52.js → config-FIXJZEQK.js} +18 -387
  260. package/dist/cli-bundle/chunks/config-FIXJZEQK.js.map +7 -0
  261. package/dist/cli-bundle/chunks/{config-MMJA4LLK.js → config-X3ZVCUUG.js} +18 -380
  262. package/dist/cli-bundle/chunks/config-X3ZVCUUG.js.map +1 -0
  263. package/dist/cli-bundle/chunks/context-7ZEZV3BV.js +42 -0
  264. package/dist/cli-bundle/chunks/context-XDI4DKKT.js +46 -0
  265. package/dist/cli-bundle/chunks/{contracts-XGVMMPC5.js → contracts-KP4QAGVW.js} +72 -15
  266. package/dist/cli-bundle/chunks/contracts-KP4QAGVW.js.map +1 -0
  267. package/dist/cli-bundle/chunks/{contracts-C3SZCXXG.js → contracts-SMOAN5NF.js} +72 -15
  268. package/dist/cli-bundle/chunks/contracts-SMOAN5NF.js.map +7 -0
  269. package/dist/cli-bundle/chunks/{copy-HHL3K4QP.js → copy-CWM6SBY6.js} +7 -11
  270. package/dist/cli-bundle/chunks/{copy-HHL3K4QP.js.map → copy-CWM6SBY6.js.map} +1 -1
  271. package/dist/cli-bundle/chunks/{copy-5D5DX3VK.js → copy-JJ3KOQW2.js} +9 -13
  272. package/dist/cli-bundle/chunks/{copy-5D5DX3VK.js.map → copy-JJ3KOQW2.js.map} +1 -1
  273. package/dist/cli-bundle/chunks/create-DFMNBKBS.js +28 -0
  274. package/dist/cli-bundle/chunks/{create-IXY43O4H.js → create-J5Q2ELZT.js} +12 -14
  275. package/dist/cli-bundle/chunks/{delete-IBUR3M42.js → delete-2GZLQEUQ.js} +7 -9
  276. package/dist/cli-bundle/chunks/{delete-IBUR3M42.js.map → delete-2GZLQEUQ.js.map} +1 -1
  277. package/dist/cli-bundle/chunks/{delete-QQC2FGUH.js → delete-OOQS4KVD.js} +5 -7
  278. package/dist/cli-bundle/chunks/{delete-QQC2FGUH.js.map → delete-OOQS4KVD.js.map} +1 -1
  279. package/dist/cli-bundle/chunks/{deps-KWKRHXIN.js → deps-IF4IGL4R.js} +6 -9
  280. package/dist/cli-bundle/chunks/{deps-KWKRHXIN.js.map → deps-IF4IGL4R.js.map} +1 -1
  281. package/dist/cli-bundle/chunks/{deps-VTPO4BSE.js → deps-ZVGGCRR6.js} +8 -11
  282. package/dist/cli-bundle/chunks/{deps-VTPO4BSE.js.map → deps-ZVGGCRR6.js.map} +1 -1
  283. package/dist/cli-bundle/chunks/{docs-IIO3FEUO.js → docs-2TIFR62T.js} +8 -9
  284. package/dist/cli-bundle/chunks/{docs-IIO3FEUO.js.map → docs-2TIFR62T.js.map} +1 -1
  285. package/dist/cli-bundle/chunks/{docs-7CHFHXLN.js → docs-NFTBCQQC.js} +10 -11
  286. package/dist/cli-bundle/chunks/{docs-7CHFHXLN.js.map → docs-NFTBCQQC.js.map} +1 -1
  287. package/dist/cli-bundle/chunks/{eval-IO7LREOL.js → eval-2F6EH4XN.js} +12 -14
  288. package/dist/cli-bundle/chunks/{eval-IO7LREOL.js.map → eval-2F6EH4XN.js.map} +1 -1
  289. package/dist/cli-bundle/chunks/{eval-CEYYEPSX.js → eval-PFKXQR3B.js} +10 -12
  290. package/dist/cli-bundle/chunks/{eval-CEYYEPSX.js.map → eval-PFKXQR3B.js.map} +1 -1
  291. package/dist/cli-bundle/chunks/{extension-KCPUWSY2.js → extension-3LRYX7SW.js} +11 -7
  292. package/dist/cli-bundle/chunks/{extension-UTTQDUYI.js → extension-GMVOIP4O.js} +11 -7
  293. package/dist/cli-bundle/chunks/{files-Z2HHEFGP.js → files-DF3HO6XK.js} +11 -13
  294. package/dist/cli-bundle/chunks/{files-Z2HHEFGP.js.map → files-DF3HO6XK.js.map} +1 -1
  295. package/dist/cli-bundle/chunks/{files-TPUL6KWB.js → files-T5ODMETM.js} +9 -11
  296. package/dist/cli-bundle/chunks/{files-TPUL6KWB.js.map → files-T5ODMETM.js.map} +1 -1
  297. package/dist/cli-bundle/chunks/{focus-YRNNH7IP.js → focus-DLXKK4AH.js} +10 -14
  298. package/dist/cli-bundle/chunks/{focus-YRNNH7IP.js.map → focus-DLXKK4AH.js.map} +1 -1
  299. package/dist/cli-bundle/chunks/{focus-JVJCGC2D.js → focus-MY5ARIEK.js} +8 -12
  300. package/dist/cli-bundle/chunks/{focus-JVJCGC2D.js.map → focus-MY5ARIEK.js.map} +1 -1
  301. package/dist/cli-bundle/chunks/{gc-O5GUO3SU.js → gc-FULIVYR4.js} +3 -3
  302. package/dist/cli-bundle/chunks/{gc-PYVVEELM.js → gc-MDGRR2SU.js} +3 -3
  303. package/dist/cli-bundle/chunks/{get-X4O3HBEY.js → get-AWK324RS.js} +10 -13
  304. package/dist/cli-bundle/chunks/{get-X4O3HBEY.js.map → get-AWK324RS.js.map} +1 -1
  305. package/dist/cli-bundle/chunks/{get-ENLTEGTX.js → get-VYPIICPC.js} +12 -15
  306. package/dist/cli-bundle/chunks/{get-ENLTEGTX.js.map → get-VYPIICPC.js.map} +1 -1
  307. package/dist/cli-bundle/chunks/{health-5EXTY44Q.js → health-FBCVZGSX.js} +16 -17
  308. package/dist/cli-bundle/chunks/{health-5EXTY44Q.js.map → health-FBCVZGSX.js.map} +1 -1
  309. package/dist/cli-bundle/chunks/{health-BOTB7YSU.js → health-Q66C43GN.js} +18 -19
  310. package/dist/cli-bundle/chunks/{health-BOTB7YSU.js.map → health-Q66C43GN.js.map} +1 -1
  311. package/dist/cli-bundle/chunks/history-5XUSLAJA.js +18 -0
  312. package/dist/cli-bundle/chunks/{history-AJTXLT6S.js → history-X4OSES6K.js} +8 -10
  313. package/dist/cli-bundle/chunks/{history-compact-46MRHW3I.js → history-compact-2GHT32UX.js} +13 -16
  314. package/dist/cli-bundle/chunks/{history-compact-46MRHW3I.js.map → history-compact-2GHT32UX.js.map} +1 -1
  315. package/dist/cli-bundle/chunks/{history-compact-43OOUAWD.js → history-compact-WLCQEKXS.js} +11 -14
  316. package/dist/cli-bundle/chunks/{history-compact-43OOUAWD.js.map → history-compact-WLCQEKXS.js.map} +1 -1
  317. package/dist/cli-bundle/chunks/{history-redact-KUUUVUFM.js → history-redact-45YW65BK.js} +9 -11
  318. package/dist/cli-bundle/chunks/history-redact-BVHWDXPR.js +19 -0
  319. package/dist/cli-bundle/chunks/{history-repair-B5PZBOPU.js → history-repair-FY75IC26.js} +13 -16
  320. package/dist/cli-bundle/chunks/{history-repair-B5PZBOPU.js.map → history-repair-FY75IC26.js.map} +1 -1
  321. package/dist/cli-bundle/chunks/{history-repair-VQTYOSRS.js → history-repair-GABSDSVD.js} +11 -14
  322. package/dist/cli-bundle/chunks/{history-repair-VQTYOSRS.js.map → history-repair-GABSDSVD.js.map} +1 -1
  323. package/dist/cli-bundle/chunks/{init-BNLVFPRG.js → init-KO7CGIRQ.js} +11 -11
  324. package/dist/cli-bundle/chunks/init-TRYJELH4.js +21 -0
  325. package/dist/cli-bundle/chunks/{learnings-MUUU5KMC.js → learnings-3F7YLI45.js} +9 -11
  326. package/dist/cli-bundle/chunks/{learnings-MUUU5KMC.js.map → learnings-3F7YLI45.js.map} +1 -1
  327. package/dist/cli-bundle/chunks/{learnings-XSGX52S7.js → learnings-LHZT5BHW.js} +11 -13
  328. package/dist/cli-bundle/chunks/{learnings-XSGX52S7.js.map → learnings-LHZT5BHW.js.map} +1 -1
  329. package/dist/cli-bundle/chunks/{list-32U7BSKE.js → list-ROT7JF62.js} +10 -10
  330. package/dist/cli-bundle/chunks/{list-ZEEOHLTQ.js → list-Y6AU5BJS.js} +10 -10
  331. package/dist/cli-bundle/chunks/next-66BJB4N2.js +277 -0
  332. package/dist/cli-bundle/chunks/next-66BJB4N2.js.map +7 -0
  333. package/dist/cli-bundle/chunks/next-N5MWJTBY.js +274 -0
  334. package/dist/cli-bundle/chunks/next-N5MWJTBY.js.map +1 -0
  335. package/dist/cli-bundle/chunks/{notes-OHU25L3M.js → notes-EVJZ3VAB.js} +11 -13
  336. package/dist/cli-bundle/chunks/{notes-OHU25L3M.js.map → notes-EVJZ3VAB.js.map} +1 -1
  337. package/dist/cli-bundle/chunks/{notes-NJ45OZGF.js → notes-FW6YFLND.js} +9 -11
  338. package/dist/cli-bundle/chunks/{notes-NJ45OZGF.js.map → notes-FW6YFLND.js.map} +1 -1
  339. package/dist/cli-bundle/chunks/{plan-LWWAEV5Y.js → plan-DQ7G4EDC.js} +15 -18
  340. package/dist/cli-bundle/chunks/{plan-LWWAEV5Y.js.map → plan-DQ7G4EDC.js.map} +1 -1
  341. package/dist/cli-bundle/chunks/{plan-KQA7CAKI.js → plan-ZHKZ7JVF.js} +17 -20
  342. package/dist/cli-bundle/chunks/{plan-KQA7CAKI.js.map → plan-ZHKZ7JVF.js.map} +1 -1
  343. package/dist/cli-bundle/chunks/profile-CHAW6SEA.js +1197 -0
  344. package/dist/cli-bundle/chunks/profile-CHAW6SEA.js.map +1 -0
  345. package/dist/cli-bundle/chunks/profile-UPZGCDOG.js +1235 -0
  346. package/dist/cli-bundle/chunks/profile-UPZGCDOG.js.map +7 -0
  347. package/dist/cli-bundle/chunks/{register-list-query-DDCHPONM.js → register-list-query-KY6Z6WV7.js} +44 -20
  348. package/dist/cli-bundle/chunks/register-list-query-KY6Z6WV7.js.map +7 -0
  349. package/dist/cli-bundle/chunks/{register-list-query-YNPBVIKM.js → register-list-query-Y2VRHPCL.js} +45 -21
  350. package/dist/cli-bundle/chunks/register-list-query-Y2VRHPCL.js.map +1 -0
  351. package/dist/cli-bundle/chunks/{register-mutation-LAVKYY63.js → register-mutation-N6AYSKPM.js} +103 -37
  352. package/dist/cli-bundle/chunks/register-mutation-N6AYSKPM.js.map +7 -0
  353. package/dist/cli-bundle/chunks/{register-mutation-7ALWDDAX.js → register-mutation-PCARIGZS.js} +104 -38
  354. package/dist/cli-bundle/chunks/register-mutation-PCARIGZS.js.map +1 -0
  355. package/dist/cli-bundle/chunks/{register-operations-U5JAW3WE.js → register-operations-L6CYTOIH.js} +30 -32
  356. package/dist/cli-bundle/chunks/{register-operations-U5JAW3WE.js.map → register-operations-L6CYTOIH.js.map} +1 -1
  357. package/dist/cli-bundle/chunks/{register-operations-R4VOQ6EF.js → register-operations-YAT6FUUB.js} +32 -34
  358. package/dist/cli-bundle/chunks/{register-operations-R4VOQ6EF.js.map → register-operations-YAT6FUUB.js.map} +1 -1
  359. package/dist/cli-bundle/chunks/{register-setup-KBXQDCXE.js → register-setup-MPANILQF.js} +67 -24
  360. package/dist/cli-bundle/chunks/register-setup-MPANILQF.js.map +7 -0
  361. package/dist/cli-bundle/chunks/{register-setup-RCRUHMSZ.js → register-setup-N7UGXYJC.js} +68 -25
  362. package/dist/cli-bundle/chunks/register-setup-N7UGXYJC.js.map +1 -0
  363. package/dist/cli-bundle/chunks/{restore-6K53WOWO.js → restore-DKMCLPI5.js} +9 -11
  364. package/dist/cli-bundle/chunks/restore-IRAKSWIW.js +17 -0
  365. package/dist/cli-bundle/chunks/{scheduling-shortcuts-NJ5UVJFB.js → scheduling-shortcuts-3F4QUEDH.js} +14 -16
  366. package/dist/cli-bundle/chunks/{scheduling-shortcuts-NJ5UVJFB.js.map → scheduling-shortcuts-3F4QUEDH.js.map} +1 -1
  367. package/dist/cli-bundle/chunks/{scheduling-shortcuts-OQVJXG3M.js → scheduling-shortcuts-BNZLQK36.js} +12 -14
  368. package/dist/cli-bundle/chunks/{scheduling-shortcuts-OQVJXG3M.js.map → scheduling-shortcuts-BNZLQK36.js.map} +1 -1
  369. package/dist/cli-bundle/chunks/schema-OLT6LVKH.js +75 -0
  370. package/dist/cli-bundle/chunks/schema-XJXKJQF5.js +71 -0
  371. package/dist/cli-bundle/chunks/{search-6HOIVZDU.js → search-CX5UMV4H.js} +10 -12
  372. package/dist/cli-bundle/chunks/{search-ZWYEMASC.js → search-KP6H7COV.js} +10 -12
  373. package/dist/cli-bundle/chunks/{stats-R5OAJVZK.js → stats-7XW4OEMK.js} +20 -12
  374. package/dist/cli-bundle/chunks/stats-7XW4OEMK.js.map +7 -0
  375. package/dist/cli-bundle/chunks/{stats-FS742AMA.js → stats-QZUG6MX5.js} +21 -13
  376. package/dist/cli-bundle/chunks/stats-QZUG6MX5.js.map +1 -0
  377. package/dist/cli-bundle/chunks/{telemetry-7DIGDQUO.js → telemetry-DIFPXCAT.js} +4 -4
  378. package/dist/cli-bundle/chunks/{telemetry-FWEXSJLQ.js → telemetry-WTYFUPRL.js} +4 -4
  379. package/dist/cli-bundle/chunks/{test-NZF7OT2F.js → test-HU2BS7EY.js} +14 -16
  380. package/dist/cli-bundle/chunks/test-HU2BS7EY.js.map +1 -0
  381. package/dist/cli-bundle/chunks/test-QNDXZQCW.js +34 -0
  382. package/dist/cli-bundle/chunks/test-QNDXZQCW.js.map +7 -0
  383. package/dist/cli-bundle/chunks/{test-all-DPN62TX7.js → test-all-PZTBLLQ6.js} +17 -20
  384. package/dist/cli-bundle/chunks/{test-all-DPN62TX7.js.map → test-all-PZTBLLQ6.js.map} +1 -1
  385. package/dist/cli-bundle/chunks/{test-all-KL7TLMJF.js → test-all-XLPI4USF.js} +19 -22
  386. package/dist/cli-bundle/chunks/{test-all-KL7TLMJF.js.map → test-all-XLPI4USF.js.map} +1 -1
  387. package/dist/cli-bundle/chunks/{test-runs-C6CFIVOS.js → test-runs-CA6K32RD.js} +6 -7
  388. package/dist/cli-bundle/chunks/test-runs-CA6K32RD.js.map +1 -0
  389. package/dist/cli-bundle/chunks/{test-runs-IAJDL6CA.js → test-runs-LANLLPVO.js} +5 -6
  390. package/dist/cli-bundle/chunks/test-runs-LANLLPVO.js.map +7 -0
  391. package/dist/cli-bundle/chunks/update-DJKWLBWJ.js +28 -0
  392. package/dist/cli-bundle/chunks/update-DJKWLBWJ.js.map +1 -0
  393. package/dist/cli-bundle/chunks/update-UXDLTEOZ.js +24 -0
  394. package/dist/cli-bundle/chunks/update-UXDLTEOZ.js.map +7 -0
  395. package/dist/cli-bundle/chunks/{update-many-YEH2DQL6.js → update-many-LU3SCNK5.js} +32 -33
  396. package/dist/cli-bundle/chunks/{update-many-YEH2DQL6.js.map → update-many-LU3SCNK5.js.map} +1 -1
  397. package/dist/cli-bundle/chunks/{update-many-MUTIOAP3.js → update-many-VW5DGF3S.js} +34 -35
  398. package/dist/cli-bundle/chunks/{update-many-MUTIOAP3.js.map → update-many-VW5DGF3S.js.map} +1 -1
  399. package/dist/cli-bundle/chunks/{upgrade-HYJ3SWWU.js → upgrade-77FRUAXN.js} +12 -8
  400. package/dist/cli-bundle/chunks/{upgrade-HYJ3SWWU.js.map → upgrade-77FRUAXN.js.map} +1 -1
  401. package/dist/cli-bundle/chunks/{upgrade-UBNLBZNR.js → upgrade-ICXY244R.js} +10 -6
  402. package/dist/cli-bundle/chunks/{upgrade-UBNLBZNR.js.map → upgrade-ICXY244R.js.map} +1 -1
  403. package/dist/cli-bundle/chunks/{validate-6QWQVCX2.js → validate-2G566PKQ.js} +37 -28
  404. package/dist/cli-bundle/chunks/validate-2G566PKQ.js.map +7 -0
  405. package/dist/cli-bundle/chunks/{validate-W5V5ZGQX.js → validate-BDPVXHHH.js} +38 -29
  406. package/dist/cli-bundle/chunks/validate-BDPVXHHH.js.map +1 -0
  407. package/dist/cli-bundle/main.js +56 -38
  408. package/dist/cli-bundle/main.js.map +2 -2
  409. package/dist/core/config/positional-value.d.ts +2 -0
  410. package/dist/core/config/positional-value.js +2 -2
  411. package/dist/core/config/positional-value.js.map +1 -1
  412. package/dist/core/extensions/activation-summary-markdown.d.ts +71 -0
  413. package/dist/core/extensions/activation-summary-markdown.js +140 -0
  414. package/dist/core/extensions/activation-summary-markdown.js.map +1 -0
  415. package/dist/core/extensions/activation-summary.d.ts +2 -0
  416. package/dist/core/extensions/activation-summary.js +3 -2
  417. package/dist/core/extensions/activation-summary.js.map +1 -1
  418. package/dist/core/extensions/capability-usage.d.ts +1 -1
  419. package/dist/core/extensions/capability-usage.js +4 -3
  420. package/dist/core/extensions/capability-usage.js.map +1 -1
  421. package/dist/core/extensions/extension-registries.js +3 -2
  422. package/dist/core/extensions/extension-registries.js.map +1 -1
  423. package/dist/core/extensions/extension-types.d.ts +21 -1
  424. package/dist/core/extensions/extension-types.js +3 -2
  425. package/dist/core/extensions/extension-types.js.map +1 -1
  426. package/dist/core/extensions/loader.d.ts +1 -2
  427. package/dist/core/extensions/loader.js +169 -103
  428. package/dist/core/extensions/loader.js.map +1 -1
  429. package/dist/core/extensions/version-compat.d.ts +107 -0
  430. package/dist/core/extensions/version-compat.js +130 -0
  431. package/dist/core/extensions/version-compat.js.map +1 -0
  432. package/dist/core/fs/fs-utils.js +27 -2
  433. package/dist/core/fs/fs-utils.js.map +1 -1
  434. package/dist/core/item/actionability.d.ts +57 -0
  435. package/dist/core/item/actionability.js +178 -0
  436. package/dist/core/item/actionability.js.map +1 -0
  437. package/dist/core/item/type-registry.js +18 -45
  438. package/dist/core/item/type-registry.js.map +1 -1
  439. package/dist/core/profile/profile-describe.d.ts +64 -0
  440. package/dist/core/profile/profile-describe.js +83 -0
  441. package/dist/core/profile/profile-describe.js.map +1 -0
  442. package/dist/core/profile/profile-lint.d.ts +53 -0
  443. package/dist/core/profile/profile-lint.js +422 -0
  444. package/dist/core/profile/profile-lint.js.map +1 -0
  445. package/dist/core/profile/profile-plan.d.ts +145 -0
  446. package/dist/core/profile/profile-plan.js +0 -0
  447. package/dist/core/profile/profile-plan.js.map +1 -0
  448. package/dist/core/profile/profile-presets.d.ts +218 -0
  449. package/dist/core/profile/profile-presets.js +325 -0
  450. package/dist/core/profile/profile-presets.js.map +1 -0
  451. package/dist/core/schema/fields-file.js +25 -25
  452. package/dist/core/schema/fields-file.js.map +1 -1
  453. package/dist/core/schema/item-types-file.js +3 -3
  454. package/dist/core/schema/item-types-file.js.map +1 -1
  455. package/dist/core/schema/runtime-schema.js +4 -4
  456. package/dist/core/schema/runtime-schema.js.map +1 -1
  457. package/dist/core/schema/status-defs-file.js +3 -3
  458. package/dist/core/schema/status-defs-file.js.map +1 -1
  459. package/dist/core/shared/serialization.js +83 -62
  460. package/dist/core/shared/serialization.js.map +1 -1
  461. package/dist/core/store/item-store.d.ts +1 -0
  462. package/dist/core/store/item-store.js +16 -8
  463. package/dist/core/store/item-store.js.map +1 -1
  464. package/dist/core/store/paths.js +4 -32
  465. package/dist/core/store/paths.js.map +1 -1
  466. package/dist/core/store/settings.js +14 -14
  467. package/dist/core/store/settings.js.map +1 -1
  468. package/dist/core/telemetry/observability.js +50 -54
  469. package/dist/core/telemetry/observability.js.map +1 -1
  470. package/dist/core/telemetry/runtime.js +11 -2
  471. package/dist/core/telemetry/runtime.js.map +1 -1
  472. package/dist/core/test/background-runs.js +3 -2
  473. package/dist/core/test/background-runs.js.map +1 -1
  474. package/dist/core/validate/linked-artifact-reference.d.ts +24 -0
  475. package/dist/core/validate/linked-artifact-reference.js +41 -0
  476. package/dist/core/validate/linked-artifact-reference.js.map +1 -0
  477. package/dist/mcp/server.js +183 -83
  478. package/dist/mcp/server.js.map +1 -1
  479. package/dist/mcp/tool-definitions.js +33 -2
  480. package/dist/mcp/tool-definitions.js.map +1 -1
  481. package/dist/sdk/cli-contracts/commander-types.d.ts +1 -0
  482. package/dist/sdk/cli-contracts/commander-types.js +15 -2
  483. package/dist/sdk/cli-contracts/commander-types.js.map +1 -1
  484. package/dist/sdk/cli-contracts/enum-contracts.d.ts +3 -3
  485. package/dist/sdk/cli-contracts/enum-contracts.js +6 -2
  486. package/dist/sdk/cli-contracts/enum-contracts.js.map +1 -1
  487. package/dist/sdk/cli-contracts/flag-contracts.d.ts +149 -0
  488. package/dist/sdk/cli-contracts/flag-contracts.js +1583 -0
  489. package/dist/sdk/cli-contracts/flag-contracts.js.map +1 -0
  490. package/dist/sdk/cli-contracts/string-lists.d.ts +14 -0
  491. package/dist/sdk/cli-contracts/string-lists.js +20 -0
  492. package/dist/sdk/cli-contracts/string-lists.js.map +1 -0
  493. package/dist/sdk/cli-contracts/tool-option-contracts.d.ts +1 -1
  494. package/dist/sdk/cli-contracts/tool-option-contracts.js +51 -109
  495. package/dist/sdk/cli-contracts/tool-option-contracts.js.map +1 -1
  496. package/dist/sdk/cli-contracts/tool-parameter-tables.d.ts +17 -0
  497. package/dist/sdk/cli-contracts/tool-parameter-tables.js +54 -5
  498. package/dist/sdk/cli-contracts/tool-parameter-tables.js.map +1 -1
  499. package/dist/sdk/cli-contracts/tool-schema.d.ts +74 -0
  500. package/dist/sdk/cli-contracts/tool-schema.js +840 -0
  501. package/dist/sdk/cli-contracts/tool-schema.js.map +1 -0
  502. package/dist/sdk/cli-contracts.d.ts +13 -193
  503. package/dist/sdk/cli-contracts.js +5 -2277
  504. package/dist/sdk/cli-contracts.js.map +1 -1
  505. package/dist/sdk/compose.d.ts +346 -4
  506. package/dist/sdk/compose.js +486 -15
  507. package/dist/sdk/compose.js.map +1 -1
  508. package/dist/sdk/define.d.ts +29 -14
  509. package/dist/sdk/define.js +21 -7
  510. package/dist/sdk/define.js.map +1 -1
  511. package/dist/sdk/index.d.ts +14 -3
  512. package/dist/sdk/index.js +14 -3
  513. package/dist/sdk/index.js.map +1 -1
  514. package/dist/sdk/testing.d.ts +156 -3
  515. package/dist/sdk/testing.js +172 -4
  516. package/dist/sdk/testing.js.map +1 -1
  517. package/docs/AGENT_GUIDE.md +2 -0
  518. package/docs/CLAUDE_CODE_PLUGIN.md +2 -2
  519. package/docs/COMMANDS.md +37 -0
  520. package/docs/EXTENSIONS.md +20 -20
  521. package/docs/RELEASING.md +6 -1
  522. package/docs/SDK.md +387 -20
  523. package/docs/TESTING.md +12 -0
  524. package/docs/examples/policy-restricted-extension/README.md +6 -0
  525. package/docs/examples/policy-restricted-extension/index.ts +40 -0
  526. package/docs/examples/policy-restricted-extension/manifest.json +2 -2
  527. package/docs/examples/starter-extension/README.md +14 -2
  528. package/docs/examples/starter-extension/{index.js → index.ts} +51 -6
  529. package/docs/examples/starter-extension/manifest.json +2 -2
  530. package/package.json +20 -7
  531. package/packages/pm-beads/extensions/beads/index.ts +3 -3
  532. package/packages/pm-beads/extensions/beads/manifest.json +2 -2
  533. package/packages/pm-beads/extensions/beads/runtime-loader.ts +19 -7
  534. package/packages/pm-beads/extensions/beads/runtime.ts +155 -37
  535. package/packages/pm-calendar/extensions/calendar/index.ts +3 -3
  536. package/packages/pm-calendar/extensions/calendar/manifest.json +2 -2
  537. package/packages/pm-calendar/extensions/calendar/runtime.ts +2 -2
  538. package/packages/pm-command-kit/extensions/command-kit/index.ts +1 -1
  539. package/packages/pm-command-kit/extensions/command-kit/manifest.json +2 -2
  540. package/packages/pm-governance-audit/extensions/governance-audit/index.ts +2 -2
  541. package/packages/pm-governance-audit/extensions/governance-audit/manifest.json +2 -2
  542. package/packages/pm-governance-audit/extensions/governance-audit/runtime.ts +1 -1
  543. package/packages/pm-guide-shell/extensions/guide-shell/index.ts +2 -2
  544. package/packages/pm-guide-shell/extensions/guide-shell/manifest.json +2 -2
  545. package/packages/pm-guide-shell/extensions/guide-shell/runtime.ts +1 -1
  546. package/packages/pm-kanban/README.md +97 -0
  547. package/packages/pm-kanban/extensions/kanban/index.ts +191 -0
  548. package/packages/pm-kanban/extensions/kanban/manifest.json +19 -0
  549. package/packages/pm-kanban/package.json +57 -0
  550. package/packages/pm-lifecycle-hooks/extensions/lifecycle-hooks/index.ts +1 -1
  551. package/packages/pm-lifecycle-hooks/extensions/lifecycle-hooks/manifest.json +2 -2
  552. package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/index.ts +2 -2
  553. package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/manifest.json +2 -2
  554. package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/runtime.ts +1 -1
  555. package/packages/pm-search-advanced/extensions/search-advanced/index.ts +2 -2
  556. package/packages/pm-search-advanced/extensions/search-advanced/manifest.json +2 -2
  557. package/packages/pm-search-advanced/extensions/search-advanced/runtime.ts +1 -1
  558. package/packages/pm-templates/extensions/templates/index.ts +2 -2
  559. package/packages/pm-templates/extensions/templates/manifest.json +2 -2
  560. package/packages/pm-templates/extensions/templates/runtime.ts +1 -1
  561. package/packages/pm-todos/extensions/todos/index.ts +3 -3
  562. package/packages/pm-todos/extensions/todos/manifest.json +2 -2
  563. package/packages/pm-todos/extensions/todos/runtime-loader.ts +19 -7
  564. package/packages/pm-todos/extensions/todos/runtime.ts +177 -43
  565. package/plugins/pm-claude/scripts/pm-mcp-server.mjs +2 -2
  566. package/plugins/pm-codex/scripts/pm-mcp-server.mjs +2 -2
  567. package/scripts/bundle-cli.mjs +1 -1
  568. package/dist/cli-bundle/chunks/activity-XUZ2AHCW.js +0 -18
  569. package/dist/cli-bundle/chunks/aggregate-EGJLZQBI.js.map +0 -7
  570. package/dist/cli-bundle/chunks/aggregate-R725FC3S.js.map +0 -1
  571. package/dist/cli-bundle/chunks/chunk-2BFPAUAF.js.map +0 -1
  572. package/dist/cli-bundle/chunks/chunk-46G6RSB6.js.map +0 -1
  573. package/dist/cli-bundle/chunks/chunk-55ISXAQH.js.map +0 -7
  574. package/dist/cli-bundle/chunks/chunk-5UVVASSA.js.map +0 -1
  575. package/dist/cli-bundle/chunks/chunk-7MRQ4HMK.js +0 -78
  576. package/dist/cli-bundle/chunks/chunk-7MRQ4HMK.js.map +0 -7
  577. package/dist/cli-bundle/chunks/chunk-7SV63ZHD.js.map +0 -1
  578. package/dist/cli-bundle/chunks/chunk-AONIHR2C.js.map +0 -7
  579. package/dist/cli-bundle/chunks/chunk-C5AOG6D2.js +0 -691
  580. package/dist/cli-bundle/chunks/chunk-C5AOG6D2.js.map +0 -1
  581. package/dist/cli-bundle/chunks/chunk-CE5P2NQR.js.map +0 -1
  582. package/dist/cli-bundle/chunks/chunk-CKGNPJAG.js.map +0 -7
  583. package/dist/cli-bundle/chunks/chunk-G6PYHBBR.js.map +0 -7
  584. package/dist/cli-bundle/chunks/chunk-GAJVRGGA.js.map +0 -1
  585. package/dist/cli-bundle/chunks/chunk-HFFUQR73.js.map +0 -7
  586. package/dist/cli-bundle/chunks/chunk-IPKJ6B36.js.map +0 -7
  587. package/dist/cli-bundle/chunks/chunk-JR2LV3M4.js.map +0 -7
  588. package/dist/cli-bundle/chunks/chunk-KFWBJPSG.js.map +0 -1
  589. package/dist/cli-bundle/chunks/chunk-KQMUV6LX.js.map +0 -1
  590. package/dist/cli-bundle/chunks/chunk-MJTINN54.js.map +0 -7
  591. package/dist/cli-bundle/chunks/chunk-MJTSZKK5.js.map +0 -7
  592. package/dist/cli-bundle/chunks/chunk-MVKFOLLM.js +0 -694
  593. package/dist/cli-bundle/chunks/chunk-MVKFOLLM.js.map +0 -7
  594. package/dist/cli-bundle/chunks/chunk-QH3PJYON.js.map +0 -1
  595. package/dist/cli-bundle/chunks/chunk-QL5RVYOA.js.map +0 -7
  596. package/dist/cli-bundle/chunks/chunk-S26C36QC.js +0 -83
  597. package/dist/cli-bundle/chunks/chunk-S26C36QC.js.map +0 -1
  598. package/dist/cli-bundle/chunks/chunk-S2RUQSX2.js +0 -75
  599. package/dist/cli-bundle/chunks/chunk-S2RUQSX2.js.map +0 -1
  600. package/dist/cli-bundle/chunks/chunk-SKH7OGE5.js +0 -86
  601. package/dist/cli-bundle/chunks/chunk-SKH7OGE5.js.map +0 -7
  602. package/dist/cli-bundle/chunks/chunk-SKN7LC5W.js.map +0 -7
  603. package/dist/cli-bundle/chunks/chunk-SR3EKWZG.js.map +0 -7
  604. package/dist/cli-bundle/chunks/chunk-UELRKQQU.js.map +0 -1
  605. package/dist/cli-bundle/chunks/chunk-VFAQ4LMN.js.map +0 -7
  606. package/dist/cli-bundle/chunks/chunk-Y4SUQQYH.js.map +0 -1
  607. package/dist/cli-bundle/chunks/chunk-YDEXO24S.js +0 -654
  608. package/dist/cli-bundle/chunks/chunk-YDEXO24S.js.map +0 -1
  609. package/dist/cli-bundle/chunks/chunk-YJ3SUEPD.js +0 -657
  610. package/dist/cli-bundle/chunks/chunk-YJ3SUEPD.js.map +0 -7
  611. package/dist/cli-bundle/chunks/chunk-YUDJD3XO.js.map +0 -1
  612. package/dist/cli-bundle/chunks/chunk-ZRK4O56R.js.map +0 -1
  613. package/dist/cli-bundle/chunks/close-A3EMKBBY.js +0 -15
  614. package/dist/cli-bundle/chunks/config-D3OKQO52.js.map +0 -7
  615. package/dist/cli-bundle/chunks/config-MMJA4LLK.js.map +0 -1
  616. package/dist/cli-bundle/chunks/context-BLBD3PUB.js.map +0 -7
  617. package/dist/cli-bundle/chunks/context-DHLVPXN3.js.map +0 -1
  618. package/dist/cli-bundle/chunks/contracts-C3SZCXXG.js.map +0 -7
  619. package/dist/cli-bundle/chunks/contracts-XGVMMPC5.js.map +0 -1
  620. package/dist/cli-bundle/chunks/create-QVGFYA2X.js +0 -30
  621. package/dist/cli-bundle/chunks/history-AK3E5Z3C.js +0 -20
  622. package/dist/cli-bundle/chunks/history-redact-TWIYQV5J.js +0 -21
  623. package/dist/cli-bundle/chunks/init-RCRKW5PL.js +0 -21
  624. package/dist/cli-bundle/chunks/register-list-query-DDCHPONM.js.map +0 -7
  625. package/dist/cli-bundle/chunks/register-list-query-YNPBVIKM.js.map +0 -1
  626. package/dist/cli-bundle/chunks/register-mutation-7ALWDDAX.js.map +0 -1
  627. package/dist/cli-bundle/chunks/register-mutation-LAVKYY63.js.map +0 -7
  628. package/dist/cli-bundle/chunks/register-setup-KBXQDCXE.js.map +0 -7
  629. package/dist/cli-bundle/chunks/register-setup-RCRUHMSZ.js.map +0 -1
  630. package/dist/cli-bundle/chunks/restore-2ZKT6UDC.js +0 -19
  631. package/dist/cli-bundle/chunks/schema-MNTAVQCY.js.map +0 -1
  632. package/dist/cli-bundle/chunks/schema-RBTJ2YXW.js.map +0 -7
  633. package/dist/cli-bundle/chunks/stats-FS742AMA.js.map +0 -1
  634. package/dist/cli-bundle/chunks/stats-R5OAJVZK.js.map +0 -7
  635. package/dist/cli-bundle/chunks/test-QJXLKV26.js +0 -36
  636. package/dist/cli-bundle/chunks/test-runs-C6CFIVOS.js.map +0 -1
  637. package/dist/cli-bundle/chunks/test-runs-IAJDL6CA.js.map +0 -7
  638. package/dist/cli-bundle/chunks/update-2XCQNOD6.js +0 -28
  639. package/dist/cli-bundle/chunks/update-IWUCXVH2.js +0 -24
  640. package/dist/cli-bundle/chunks/validate-6QWQVCX2.js.map +0 -7
  641. package/dist/cli-bundle/chunks/validate-W5V5ZGQX.js.map +0 -1
  642. package/docs/examples/policy-restricted-extension/index.js +0 -21
  643. package/packages/pm-beads/extensions/beads/index.js +0 -64
  644. package/packages/pm-beads/extensions/beads/runtime-loader.js +0 -86
  645. package/packages/pm-beads/extensions/beads/runtime.js +0 -482
  646. package/packages/pm-calendar/extensions/calendar/index.js +0 -150
  647. package/packages/pm-calendar/extensions/calendar/runtime.js +0 -126
  648. package/packages/pm-command-kit/extensions/command-kit/index.js +0 -181
  649. package/packages/pm-governance-audit/extensions/governance-audit/index.js +0 -177
  650. package/packages/pm-governance-audit/extensions/governance-audit/runtime.js +0 -153
  651. package/packages/pm-guide-shell/extensions/guide-shell/index.js +0 -98
  652. package/packages/pm-guide-shell/extensions/guide-shell/runtime.js +0 -294
  653. package/packages/pm-lifecycle-hooks/extensions/lifecycle-hooks/index.js +0 -18
  654. package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/index.js +0 -124
  655. package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/runtime.js +0 -110
  656. package/packages/pm-search-advanced/extensions/search-advanced/index.js +0 -258
  657. package/packages/pm-search-advanced/extensions/search-advanced/runtime.js +0 -361
  658. package/packages/pm-templates/extensions/templates/index.js +0 -132
  659. package/packages/pm-templates/extensions/templates/runtime.js +0 -35
  660. package/packages/pm-todos/extensions/todos/index.js +0 -81
  661. package/packages/pm-todos/extensions/todos/runtime-loader.js +0 -86
  662. package/packages/pm-todos/extensions/todos/runtime.js +0 -545
  663. /package/dist/cli-bundle/chunks/{activity-XUZ2AHCW.js.map → activity-EJBMXUBH.js.map} +0 -0
  664. /package/dist/cli-bundle/chunks/{activity-H2LMOSSW.js.map → activity-MVSEND6D.js.map} +0 -0
  665. /package/dist/cli-bundle/chunks/{chunk-IB3GYLQE.js.map → chunk-3JWQCLR5.js.map} +0 -0
  666. /package/dist/cli-bundle/chunks/{chunk-2A34E3BA.js.map → chunk-4TXTVZL3.js.map} +0 -0
  667. /package/dist/cli-bundle/chunks/{chunk-G6N5VEOK.js.map → chunk-4YIMPANT.js.map} +0 -0
  668. /package/dist/cli-bundle/chunks/{chunk-7XGQXHFB.js.map → chunk-73PTKMAE.js.map} +0 -0
  669. /package/dist/cli-bundle/chunks/{chunk-3VY3YQO6.js.map → chunk-7RIJGN4R.js.map} +0 -0
  670. /package/dist/cli-bundle/chunks/{chunk-FXR67XVQ.js.map → chunk-BN3CWK6G.js.map} +0 -0
  671. /package/dist/cli-bundle/chunks/{chunk-4BHT5VDC.js.map → chunk-C2KCIZKZ.js.map} +0 -0
  672. /package/dist/cli-bundle/chunks/{chunk-O6LLO73I.js.map → chunk-CHRNYKNI.js.map} +0 -0
  673. /package/dist/cli-bundle/chunks/{chunk-ZQ3ZVXX2.js.map → chunk-D6USKAMA.js.map} +0 -0
  674. /package/dist/cli-bundle/chunks/{chunk-WZQWHN4R.js.map → chunk-DLDCPF5X.js.map} +0 -0
  675. /package/dist/cli-bundle/chunks/{chunk-UVC5LOR7.js.map → chunk-E2Q2ULMR.js.map} +0 -0
  676. /package/dist/cli-bundle/chunks/{chunk-5VOINNKT.js.map → chunk-F6VH3LFC.js.map} +0 -0
  677. /package/dist/cli-bundle/chunks/{chunk-H4IIJDE4.js.map → chunk-FDEVKXC4.js.map} +0 -0
  678. /package/dist/cli-bundle/chunks/{chunk-34EONI5F.js.map → chunk-HUYYMTGW.js.map} +0 -0
  679. /package/dist/cli-bundle/chunks/{chunk-CIIK67GW.js.map → chunk-IHXXUIXS.js.map} +0 -0
  680. /package/dist/cli-bundle/chunks/{chunk-SBQTAVJZ.js.map → chunk-JIP67N2K.js.map} +0 -0
  681. /package/dist/cli-bundle/chunks/{chunk-2T3JG6V4.js.map → chunk-KRASIL6M.js.map} +0 -0
  682. /package/dist/cli-bundle/chunks/{chunk-P77P2ILI.js.map → chunk-MLHX6DN5.js.map} +0 -0
  683. /package/dist/cli-bundle/chunks/{chunk-2CKH2LMV.js.map → chunk-OB3RJV5F.js.map} +0 -0
  684. /package/dist/cli-bundle/chunks/{chunk-FIGAZ4Y7.js.map → chunk-OUQ5JEFM.js.map} +0 -0
  685. /package/dist/cli-bundle/chunks/{chunk-NK3UPBVG.js.map → chunk-QE5UFCCO.js.map} +0 -0
  686. /package/dist/cli-bundle/chunks/{chunk-WM5ZVBPE.js.map → chunk-SJZTPVFT.js.map} +0 -0
  687. /package/dist/cli-bundle/chunks/{chunk-VAYA4XFX.js.map → chunk-V3KLX7U7.js.map} +0 -0
  688. /package/dist/cli-bundle/chunks/{chunk-2RDVQEWV.js.map → chunk-Z5BM2FKQ.js.map} +0 -0
  689. /package/dist/cli-bundle/chunks/{chunk-66MEDTUD.js.map → chunk-ZEATCVAC.js.map} +0 -0
  690. /package/dist/cli-bundle/chunks/{chunk-NCVCO3NZ.js.map → chunk-ZFIEEDTJ.js.map} +0 -0
  691. /package/dist/cli-bundle/chunks/{close-A3EMKBBY.js.map → close-37KEHLYM.js.map} +0 -0
  692. /package/dist/cli-bundle/chunks/{close-W56IOGYG.js.map → close-OP3LK7Z2.js.map} +0 -0
  693. /package/dist/cli-bundle/chunks/{create-QVGFYA2X.js.map → context-7ZEZV3BV.js.map} +0 -0
  694. /package/dist/cli-bundle/chunks/{create-IXY43O4H.js.map → context-XDI4DKKT.js.map} +0 -0
  695. /package/dist/cli-bundle/chunks/{extension-UTTQDUYI.js.map → create-DFMNBKBS.js.map} +0 -0
  696. /package/dist/cli-bundle/chunks/{extension-KCPUWSY2.js.map → create-J5Q2ELZT.js.map} +0 -0
  697. /package/dist/cli-bundle/chunks/{history-AJTXLT6S.js.map → extension-3LRYX7SW.js.map} +0 -0
  698. /package/dist/cli-bundle/chunks/{history-AK3E5Z3C.js.map → extension-GMVOIP4O.js.map} +0 -0
  699. /package/dist/cli-bundle/chunks/{gc-O5GUO3SU.js.map → gc-FULIVYR4.js.map} +0 -0
  700. /package/dist/cli-bundle/chunks/{gc-PYVVEELM.js.map → gc-MDGRR2SU.js.map} +0 -0
  701. /package/dist/cli-bundle/chunks/{history-redact-TWIYQV5J.js.map → history-5XUSLAJA.js.map} +0 -0
  702. /package/dist/cli-bundle/chunks/{history-redact-KUUUVUFM.js.map → history-X4OSES6K.js.map} +0 -0
  703. /package/dist/cli-bundle/chunks/{init-BNLVFPRG.js.map → history-redact-45YW65BK.js.map} +0 -0
  704. /package/dist/cli-bundle/chunks/{init-RCRKW5PL.js.map → history-redact-BVHWDXPR.js.map} +0 -0
  705. /package/dist/cli-bundle/chunks/{list-32U7BSKE.js.map → init-KO7CGIRQ.js.map} +0 -0
  706. /package/dist/cli-bundle/chunks/{list-ZEEOHLTQ.js.map → init-TRYJELH4.js.map} +0 -0
  707. /package/dist/cli-bundle/chunks/{restore-6K53WOWO.js.map → list-ROT7JF62.js.map} +0 -0
  708. /package/dist/cli-bundle/chunks/{restore-2ZKT6UDC.js.map → list-Y6AU5BJS.js.map} +0 -0
  709. /package/dist/cli-bundle/chunks/{search-6HOIVZDU.js.map → restore-DKMCLPI5.js.map} +0 -0
  710. /package/dist/cli-bundle/chunks/{search-ZWYEMASC.js.map → restore-IRAKSWIW.js.map} +0 -0
  711. /package/dist/cli-bundle/chunks/{test-NZF7OT2F.js.map → schema-OLT6LVKH.js.map} +0 -0
  712. /package/dist/cli-bundle/chunks/{test-QJXLKV26.js.map → schema-XJXKJQF5.js.map} +0 -0
  713. /package/dist/cli-bundle/chunks/{update-2XCQNOD6.js.map → search-CX5UMV4H.js.map} +0 -0
  714. /package/dist/cli-bundle/chunks/{update-IWUCXVH2.js.map → search-KP6H7COV.js.map} +0 -0
  715. /package/dist/cli-bundle/chunks/{telemetry-7DIGDQUO.js.map → telemetry-DIFPXCAT.js.map} +0 -0
  716. /package/dist/cli-bundle/chunks/{telemetry-FWEXSJLQ.js.map → telemetry-WTYFUPRL.js.map} +0 -0
@@ -1,9 +1,10 @@
1
1
  // dist/core/fs/fs-utils.js
2
2
 
3
- !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]="94fb806d-f79e-5000-8d03-0667229930c5")}catch(e){}}();
3
+ !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]="b452df4b-661b-5f08-9d20-dff37c4bfb2f")}catch(e){}}();
4
4
  import * as fs from "node:fs/promises";
5
5
  import path from "node:path";
6
6
  import crypto from "node:crypto";
7
+ var WINDOWS_RENAME_RETRY_DELAYS_MS = [10, 25, 50, 100];
7
8
  async function ensureDir(dirPath) {
8
9
  await fs.mkdir(dirPath, { recursive: true });
9
10
  }
@@ -33,6 +34,26 @@ async function writeFileAtomic(targetPath, contents) {
33
34
  try {
34
35
  await fs.rename(tempPath, targetPath);
35
36
  } catch (error) {
37
+ if (process.platform === "win32" && (isErrno(error, "EPERM") || isErrno(error, "EBUSY"))) {
38
+ let lastError = error;
39
+ for (const delayMs of WINDOWS_RENAME_RETRY_DELAYS_MS) {
40
+ await new Promise((resolve) => setTimeout(resolve, delayMs));
41
+ try {
42
+ await fs.rename(tempPath, targetPath);
43
+ return;
44
+ } catch (retryError) {
45
+ lastError = retryError;
46
+ if (!isErrno(retryError, "EPERM") && !isErrno(retryError, "EBUSY")) {
47
+ break;
48
+ }
49
+ }
50
+ }
51
+ try {
52
+ await fs.unlink(tempPath);
53
+ } catch {
54
+ }
55
+ throw lastError;
56
+ }
36
57
  if (isErrno(error, "EXDEV")) {
37
58
  try {
38
59
  await fs.copyFile(tempPath, targetPath);
@@ -171,6 +192,7 @@ var KNOWN_EXTENSION_POLICY_SURFACES = [
171
192
  "schema.itemfields",
172
193
  "schema.itemtypes",
173
194
  "schema.migrations",
195
+ "schema.profiles",
174
196
  "parser.override",
175
197
  "preflight.override",
176
198
  "services.override",
@@ -608,6 +630,794 @@ function resolveTelemetryErrorCategory(errorCode) {
608
630
  return "unknown";
609
631
  }
610
632
 
633
+ // dist/types.js
634
+ var BUILTIN_ITEM_TYPE_VALUES = [
635
+ "Epic",
636
+ "Feature",
637
+ "Task",
638
+ "Chore",
639
+ "Issue",
640
+ "Decision",
641
+ "Event",
642
+ "Reminder",
643
+ "Milestone",
644
+ "Meeting",
645
+ "Plan"
646
+ ];
647
+ var ITEM_TYPE_VALUES = BUILTIN_ITEM_TYPE_VALUES;
648
+ var STATUS_VALUES = [
649
+ "draft",
650
+ "open",
651
+ "in_progress",
652
+ "blocked",
653
+ "closed",
654
+ "canceled"
655
+ ];
656
+ var RUNTIME_STATUS_ROLE_VALUES = [
657
+ "draft",
658
+ "active",
659
+ "blocked",
660
+ "terminal",
661
+ "terminal_done",
662
+ "terminal_canceled",
663
+ "default_open",
664
+ "default_close",
665
+ "default_cancel"
666
+ ];
667
+ var RUNTIME_FIELD_TYPE_VALUES = ["string", "number", "boolean", "string_array"];
668
+ var RUNTIME_FIELD_COMMAND_VALUES = ["create", "update", "update_many", "list", "search", "calendar", "context"];
669
+ var RUNTIME_UNKNOWN_FIELD_POLICY_VALUES = ["allow", "warn", "reject"];
670
+ var DEPENDENCY_KIND_VALUES = [
671
+ "blocks",
672
+ "parent",
673
+ "child",
674
+ "parent_child",
675
+ "child_of",
676
+ "related",
677
+ "related_to",
678
+ "discovered_from",
679
+ "blocked_by",
680
+ "incident_from",
681
+ "epic",
682
+ "supersedes",
683
+ "task"
684
+ ];
685
+ var SCOPE_VALUES = ["project", "global"];
686
+ var RISK_VALUES = ["low", "medium", "high", "critical"];
687
+ var ISSUE_SEVERITY_VALUES = ["low", "medium", "high", "critical"];
688
+ var CONFIDENCE_TEXT_VALUES = ["low", "medium", "high"];
689
+ var GOVERNANCE_PRESET_VALUES = ["minimal", "default", "strict", "custom"];
690
+ var RECURRENCE_FREQUENCY_VALUES = ["daily", "weekly", "monthly", "yearly"];
691
+ var RECURRENCE_WEEKDAY_VALUES = ["mon", "tue", "wed", "thu", "fri", "sat", "sun"];
692
+ function weekdayOrderIndex(value) {
693
+ return RECURRENCE_WEEKDAY_VALUES.indexOf(value);
694
+ }
695
+ var PLAN_MODE_VALUES = [
696
+ "draft",
697
+ "research",
698
+ "review",
699
+ "approved",
700
+ "executing",
701
+ "paused",
702
+ "completed",
703
+ "superseded"
704
+ ];
705
+ var PLAN_STEP_STATUS_VALUES = [
706
+ "pending",
707
+ "in_progress",
708
+ "completed",
709
+ "blocked",
710
+ "skipped",
711
+ "superseded"
712
+ ];
713
+ var PLAN_HARNESS_VALUES = ["codex", "claude-code", "cursor", "generic"];
714
+ var PLAN_STEP_LINK_KIND_VALUES = [
715
+ "related",
716
+ "blocks",
717
+ "blocked_by",
718
+ "depends_on",
719
+ "discovered_from",
720
+ "implements",
721
+ "verifies",
722
+ "supersedes"
723
+ ];
724
+ var CONTEXT_DEPTH_VALUES = ["brief", "standard", "deep", "full"];
725
+ var CONTEXT_SECTION_VALUES = [
726
+ "hierarchy",
727
+ "activity",
728
+ "progress",
729
+ "recently_created",
730
+ "unparented",
731
+ "blockers",
732
+ "files",
733
+ "workload",
734
+ "staleness",
735
+ "tests"
736
+ ];
737
+
738
+ // dist/core/item/item-type-definition.js
739
+ function normalizeItemTypeStringList(values) {
740
+ return [...new Set((values ?? []).map((value) => value.trim()).filter((value) => value.length > 0))].sort((left, right) => left.localeCompare(right));
741
+ }
742
+ function normalizeItemTypeOption(option) {
743
+ const key = option.key.trim();
744
+ if (key.length === 0) {
745
+ return null;
746
+ }
747
+ const aliases = normalizeItemTypeStringList(option.aliases);
748
+ const description = option.description?.trim();
749
+ return {
750
+ key,
751
+ values: normalizeItemTypeStringList(option.values),
752
+ required: option.required === true ? true : void 0,
753
+ aliases: aliases.length > 0 ? aliases : void 0,
754
+ description: description && description.length > 0 ? description : void 0
755
+ };
756
+ }
757
+ var keepPolicyCommand = (command) => command;
758
+ var strictPolicyCommand = (command) => {
759
+ const normalized = command.trim().toLowerCase();
760
+ return normalized === "create" || normalized === "update" ? normalized : null;
761
+ };
762
+ function normalizeItemTypeCommandOptionPolicy(policy, resolvePolicyCommand) {
763
+ const command = resolvePolicyCommand(policy.command);
764
+ if (command === null) {
765
+ return null;
766
+ }
767
+ const option = policy.option.trim();
768
+ if (option.length === 0) {
769
+ return null;
770
+ }
771
+ return {
772
+ command,
773
+ option,
774
+ required: policy.required,
775
+ visible: policy.visible,
776
+ enabled: policy.enabled
777
+ };
778
+ }
779
+ function normalizeItemTypeCommandOptionPolicies(policies, resolvePolicyCommand) {
780
+ const dedupedByKey = /* @__PURE__ */ new Map();
781
+ for (const policy of policies ?? []) {
782
+ const normalized = normalizeItemTypeCommandOptionPolicy(policy, resolvePolicyCommand);
783
+ if (!normalized) {
784
+ continue;
785
+ }
786
+ dedupedByKey.set(`${normalized.command}:${normalized.option.toLowerCase()}`, normalized);
787
+ }
788
+ return [...dedupedByKey.values()].sort((left, right) => left.command === right.command ? left.option.localeCompare(right.option) : left.command.localeCompare(right.command));
789
+ }
790
+ function normalizeItemTypeDefinition(definition, options = {}) {
791
+ const resolvePolicyCommand = options.resolvePolicyCommand ?? keepPolicyCommand;
792
+ const name = definition.name.trim();
793
+ if (name.length === 0) {
794
+ return null;
795
+ }
796
+ const hasRequiredCreateFields = definition.required_create_fields !== void 0;
797
+ const hasRequiredCreateRepeatables = definition.required_create_repeatables !== void 0;
798
+ const hasOptions = definition.options !== void 0;
799
+ const hasCommandOptionPolicies = definition.command_option_policies !== void 0;
800
+ const folder = definition.folder?.trim();
801
+ const description = definition.description?.trim();
802
+ const defaultStatus = definition.default_status?.trim();
803
+ const aliases = normalizeItemTypeStringList(definition.aliases);
804
+ const normalizedOptions = (definition.options ?? []).map((option) => normalizeItemTypeOption(option)).filter((option) => option !== null).sort((left, right) => left.key.localeCompare(right.key));
805
+ const commandOptionPolicies = normalizeItemTypeCommandOptionPolicies(definition.command_option_policies, resolvePolicyCommand);
806
+ return {
807
+ name,
808
+ description: description && description.length > 0 ? description : void 0,
809
+ default_status: defaultStatus && defaultStatus.length > 0 ? defaultStatus : void 0,
810
+ folder: folder && folder.length > 0 ? folder : void 0,
811
+ aliases: aliases.length > 0 ? aliases : void 0,
812
+ required_create_fields: hasRequiredCreateFields ? normalizeItemTypeStringList(definition.required_create_fields) : void 0,
813
+ required_create_repeatables: hasRequiredCreateRepeatables ? normalizeItemTypeStringList(definition.required_create_repeatables) : void 0,
814
+ options: hasOptions ? normalizedOptions : void 0,
815
+ command_option_policies: hasCommandOptionPolicies ? commandOptionPolicies : void 0
816
+ };
817
+ }
818
+
819
+ // dist/core/item/type-registry.js
820
+ var DEFAULT_REQUIRED_CREATE_FIELDS = [
821
+ "title",
822
+ "description",
823
+ "status",
824
+ "priority",
825
+ "tags",
826
+ "body",
827
+ "deadline",
828
+ "estimatedMinutes",
829
+ "acceptanceCriteria",
830
+ "author",
831
+ "message",
832
+ "assignee"
833
+ ];
834
+ var DEFAULT_REQUIRED_CREATE_REPEATABLES = ["dep", "comment", "note", "learning", "file", "test", "doc"];
835
+ var COMMON_MUTATION_COMMAND_OPTION_KEYS = [
836
+ "deadline",
837
+ "estimatedMinutes",
838
+ "acceptanceCriteria",
839
+ "definitionOfReady",
840
+ "order",
841
+ "goal",
842
+ "objective",
843
+ "value",
844
+ "impact",
845
+ "outcome",
846
+ "whyNow",
847
+ "assignee",
848
+ "parent",
849
+ "reviewer",
850
+ "risk",
851
+ "confidence",
852
+ "sprint",
853
+ "release",
854
+ "blockedBy",
855
+ "blockedReason",
856
+ "unblockNote",
857
+ "reporter",
858
+ "severity",
859
+ "environment",
860
+ "reproSteps",
861
+ "resolution",
862
+ "expectedResult",
863
+ "actualResult",
864
+ "affectedVersion",
865
+ "fixedVersion",
866
+ "component",
867
+ "regression",
868
+ "customerImpact"
869
+ ];
870
+ var CREATE_COMMAND_OPTION_KEYS = [
871
+ "title",
872
+ "description",
873
+ "type",
874
+ "status",
875
+ "priority",
876
+ "tags",
877
+ "body",
878
+ ...COMMON_MUTATION_COMMAND_OPTION_KEYS,
879
+ "author",
880
+ "message",
881
+ "dep",
882
+ "comment",
883
+ "note",
884
+ "learning",
885
+ "file",
886
+ "test",
887
+ "doc",
888
+ "reminder",
889
+ "event",
890
+ "typeOption",
891
+ "field"
892
+ ];
893
+ var UPDATE_COMMAND_OPTION_KEYS = [
894
+ "title",
895
+ "description",
896
+ "body",
897
+ "status",
898
+ "closeReason",
899
+ "priority",
900
+ "type",
901
+ "tags",
902
+ ...COMMON_MUTATION_COMMAND_OPTION_KEYS,
903
+ "author",
904
+ "message",
905
+ "comment",
906
+ "note",
907
+ "learning",
908
+ "file",
909
+ "test",
910
+ "doc",
911
+ "reminder",
912
+ "event",
913
+ "typeOption",
914
+ "field",
915
+ "allowAuditUpdate",
916
+ "force"
917
+ ];
918
+ var SHARED_COMMAND_OPTION_ALIASES = {
919
+ "close-reason": "closeReason",
920
+ close_reason: "closeReason",
921
+ "estimated-minutes": "estimatedMinutes",
922
+ estimated_minutes: "estimatedMinutes",
923
+ estimate: "estimatedMinutes",
924
+ "acceptance-criteria": "acceptanceCriteria",
925
+ acceptance_criteria: "acceptanceCriteria",
926
+ ac: "acceptanceCriteria",
927
+ "definition-of-ready": "definitionOfReady",
928
+ definition_of_ready: "definitionOfReady",
929
+ rank: "order",
930
+ "why-now": "whyNow",
931
+ why_now: "whyNow",
932
+ "blocked-by": "blockedBy",
933
+ blocked_by: "blockedBy",
934
+ "blocked-reason": "blockedReason",
935
+ blocked_reason: "blockedReason",
936
+ "unblock-note": "unblockNote",
937
+ unblock_note: "unblockNote",
938
+ "repro-steps": "reproSteps",
939
+ repro_steps: "reproSteps",
940
+ "expected-result": "expectedResult",
941
+ expected_result: "expectedResult",
942
+ "actual-result": "actualResult",
943
+ actual_result: "actualResult",
944
+ "affected-version": "affectedVersion",
945
+ affected_version: "affectedVersion",
946
+ "fixed-version": "fixedVersion",
947
+ fixed_version: "fixedVersion",
948
+ "customer-impact": "customerImpact",
949
+ customer_impact: "customerImpact",
950
+ "type-option": "typeOption",
951
+ type_option: "typeOption",
952
+ type_options: "typeOption"
953
+ };
954
+ var CREATE_COMMAND_OPTION_ALIASES = {
955
+ ...SHARED_COMMAND_OPTION_ALIASES
956
+ };
957
+ var UPDATE_COMMAND_OPTION_ALIASES = {
958
+ ...SHARED_COMMAND_OPTION_ALIASES,
959
+ "allow-audit-update": "allowAuditUpdate",
960
+ allow_audit_update: "allowAuditUpdate"
961
+ };
962
+ var CREATE_COMMAND_OPTION_FLAG_LABELS = {
963
+ title: "--title",
964
+ description: "--description",
965
+ type: "--type",
966
+ status: "--status",
967
+ priority: "--priority",
968
+ tags: "--tags",
969
+ body: "--body",
970
+ deadline: "--deadline",
971
+ estimatedMinutes: "--estimate/--estimated-minutes",
972
+ acceptanceCriteria: "--acceptance-criteria/--ac",
973
+ definitionOfReady: "--definition-of-ready",
974
+ order: "--order/--rank",
975
+ goal: "--goal",
976
+ objective: "--objective",
977
+ value: "--value",
978
+ impact: "--impact",
979
+ outcome: "--outcome",
980
+ whyNow: "--why-now",
981
+ author: "--author",
982
+ message: "--message",
983
+ assignee: "--assignee",
984
+ parent: "--parent",
985
+ reviewer: "--reviewer",
986
+ risk: "--risk",
987
+ confidence: "--confidence",
988
+ sprint: "--sprint",
989
+ release: "--release",
990
+ blockedBy: "--blocked-by",
991
+ blockedReason: "--blocked-reason",
992
+ unblockNote: "--unblock-note",
993
+ reporter: "--reporter",
994
+ severity: "--severity",
995
+ environment: "--environment",
996
+ reproSteps: "--repro-steps",
997
+ resolution: "--resolution",
998
+ expectedResult: "--expected-result",
999
+ actualResult: "--actual-result",
1000
+ affectedVersion: "--affected-version",
1001
+ fixedVersion: "--fixed-version",
1002
+ component: "--component",
1003
+ regression: "--regression",
1004
+ customerImpact: "--customer-impact",
1005
+ dep: "--dep",
1006
+ comment: "--comment",
1007
+ note: "--note",
1008
+ learning: "--learning",
1009
+ file: "--file",
1010
+ test: "--test",
1011
+ doc: "--doc",
1012
+ reminder: "--reminder",
1013
+ event: "--event",
1014
+ typeOption: "--type-option"
1015
+ };
1016
+ var UPDATE_COMMAND_OPTION_FLAG_LABELS = {
1017
+ title: "--title",
1018
+ description: "--description",
1019
+ body: "--body",
1020
+ status: "--status",
1021
+ closeReason: "--close-reason",
1022
+ priority: "--priority",
1023
+ type: "--type",
1024
+ tags: "--tags",
1025
+ deadline: "--deadline",
1026
+ estimatedMinutes: "--estimate/--estimated-minutes",
1027
+ acceptanceCriteria: "--acceptance-criteria/--ac",
1028
+ definitionOfReady: "--definition-of-ready",
1029
+ order: "--order/--rank",
1030
+ goal: "--goal",
1031
+ objective: "--objective",
1032
+ value: "--value",
1033
+ impact: "--impact",
1034
+ outcome: "--outcome",
1035
+ whyNow: "--why-now",
1036
+ assignee: "--assignee",
1037
+ parent: "--parent",
1038
+ reviewer: "--reviewer",
1039
+ risk: "--risk",
1040
+ confidence: "--confidence",
1041
+ sprint: "--sprint",
1042
+ release: "--release",
1043
+ blockedBy: "--blocked-by",
1044
+ blockedReason: "--blocked-reason",
1045
+ unblockNote: "--unblock-note",
1046
+ reporter: "--reporter",
1047
+ severity: "--severity",
1048
+ environment: "--environment",
1049
+ reproSteps: "--repro-steps",
1050
+ resolution: "--resolution",
1051
+ expectedResult: "--expected-result",
1052
+ actualResult: "--actual-result",
1053
+ affectedVersion: "--affected-version",
1054
+ fixedVersion: "--fixed-version",
1055
+ component: "--component",
1056
+ regression: "--regression",
1057
+ customerImpact: "--customer-impact",
1058
+ comment: "--comment",
1059
+ note: "--note",
1060
+ learning: "--learning",
1061
+ file: "--file",
1062
+ test: "--test",
1063
+ doc: "--doc",
1064
+ reminder: "--reminder",
1065
+ event: "--event",
1066
+ typeOption: "--type-option",
1067
+ allowAuditUpdate: "--allow-audit-update",
1068
+ author: "--author",
1069
+ message: "--message",
1070
+ force: "--force"
1071
+ };
1072
+ function normalizeCommandOptionToken(value) {
1073
+ return value.trim().replace(/^--+/, "").toLowerCase();
1074
+ }
1075
+ function commandOptionKeys(command) {
1076
+ return command === "create" ? CREATE_COMMAND_OPTION_KEYS : UPDATE_COMMAND_OPTION_KEYS;
1077
+ }
1078
+ function commandOptionAliases(command) {
1079
+ return command === "create" ? CREATE_COMMAND_OPTION_ALIASES : UPDATE_COMMAND_OPTION_ALIASES;
1080
+ }
1081
+ function canonicalizeCommandOptionKey(command, rawOption) {
1082
+ const normalizedToken = normalizeCommandOptionToken(rawOption);
1083
+ if (normalizedToken.length === 0) {
1084
+ return void 0;
1085
+ }
1086
+ const aliased = commandOptionAliases(command)[normalizedToken];
1087
+ if (aliased) {
1088
+ return aliased;
1089
+ }
1090
+ return commandOptionKeys(command).find((candidate) => candidate.toLowerCase() === normalizedToken);
1091
+ }
1092
+ function commandOptionFlagLabel(command, optionKey) {
1093
+ const labels = command === "create" ? CREATE_COMMAND_OPTION_FLAG_LABELS : UPDATE_COMMAND_OPTION_FLAG_LABELS;
1094
+ return labels[optionKey] ?? `--${optionKey.replace(/([A-Z])/g, "-$1").toLowerCase()}`;
1095
+ }
1096
+ function toDefaultFolder(name) {
1097
+ const normalized = toSlugToken(name);
1098
+ if (normalized.length === 0) {
1099
+ return "items";
1100
+ }
1101
+ return normalized.endsWith("s") ? normalized : `${normalized}s`;
1102
+ }
1103
+ function toSlugToken(value) {
1104
+ const trimmed = value.trim().toLowerCase();
1105
+ let slug = "";
1106
+ let pendingDash = false;
1107
+ for (const character of trimmed) {
1108
+ const code = character.charCodeAt(0);
1109
+ const isAlpha = code >= 97 && code <= 122;
1110
+ const isDigit = code >= 48 && code <= 57;
1111
+ if (isAlpha || isDigit) {
1112
+ if (pendingDash && slug.length > 0) {
1113
+ slug += "-";
1114
+ }
1115
+ slug += character;
1116
+ pendingDash = false;
1117
+ continue;
1118
+ }
1119
+ if (slug.length > 0) {
1120
+ pendingDash = true;
1121
+ }
1122
+ }
1123
+ return slug;
1124
+ }
1125
+ function normalizeTypeDefinition(definition) {
1126
+ return normalizeItemTypeDefinition(definition, { resolvePolicyCommand: strictPolicyCommand });
1127
+ }
1128
+ function coerceTypeDefinitionFromUnknown(raw) {
1129
+ if (typeof raw !== "object" || raw === null || Array.isArray(raw)) {
1130
+ return null;
1131
+ }
1132
+ const record = raw;
1133
+ const name = typeof record.name === "string" ? record.name : "";
1134
+ if (name.trim().length === 0) {
1135
+ return null;
1136
+ }
1137
+ const folder = typeof record.folder === "string" ? record.folder : void 0;
1138
+ const description = typeof record.description === "string" ? record.description : void 0;
1139
+ const defaultStatus = typeof record.default_status === "string" ? record.default_status : void 0;
1140
+ const aliases = Array.isArray(record.aliases) ? record.aliases.filter((value) => typeof value === "string") : void 0;
1141
+ const requiredCreateFields = Array.isArray(record.required_create_fields) ? record.required_create_fields.filter((value) => typeof value === "string") : void 0;
1142
+ const requiredCreateRepeatables = Array.isArray(record.required_create_repeatables) ? record.required_create_repeatables.filter((value) => typeof value === "string") : void 0;
1143
+ let options;
1144
+ if (Array.isArray(record.options)) {
1145
+ options = [];
1146
+ for (const entry of record.options) {
1147
+ if (typeof entry !== "object" || entry === null || Array.isArray(entry)) {
1148
+ continue;
1149
+ }
1150
+ const optionRecord = entry;
1151
+ if (typeof optionRecord.key !== "string") {
1152
+ continue;
1153
+ }
1154
+ options.push({
1155
+ key: optionRecord.key,
1156
+ values: Array.isArray(optionRecord.values) ? optionRecord.values.filter((value) => typeof value === "string") : [],
1157
+ required: optionRecord.required === void 0 ? void 0 : Boolean(optionRecord.required),
1158
+ aliases: Array.isArray(optionRecord.aliases) ? optionRecord.aliases.filter((value) => typeof value === "string") : void 0,
1159
+ description: typeof optionRecord.description === "string" ? optionRecord.description : void 0
1160
+ });
1161
+ }
1162
+ }
1163
+ let commandOptionPolicies;
1164
+ if (Array.isArray(record.command_option_policies)) {
1165
+ commandOptionPolicies = [];
1166
+ for (const entry of record.command_option_policies) {
1167
+ if (typeof entry !== "object" || entry === null || Array.isArray(entry)) {
1168
+ continue;
1169
+ }
1170
+ const policyRecord = entry;
1171
+ if (typeof policyRecord.command !== "string" || typeof policyRecord.option !== "string") {
1172
+ continue;
1173
+ }
1174
+ const normalizedCommand = policyRecord.command.trim().toLowerCase();
1175
+ if (normalizedCommand !== "create" && normalizedCommand !== "update") {
1176
+ continue;
1177
+ }
1178
+ commandOptionPolicies.push({
1179
+ command: normalizedCommand,
1180
+ option: policyRecord.option,
1181
+ required: policyRecord.required === void 0 ? void 0 : Boolean(policyRecord.required),
1182
+ visible: policyRecord.visible === void 0 ? void 0 : Boolean(policyRecord.visible),
1183
+ enabled: policyRecord.enabled === void 0 ? void 0 : Boolean(policyRecord.enabled)
1184
+ });
1185
+ }
1186
+ }
1187
+ return {
1188
+ name,
1189
+ description,
1190
+ default_status: defaultStatus,
1191
+ folder,
1192
+ aliases,
1193
+ required_create_fields: requiredCreateFields,
1194
+ required_create_repeatables: requiredCreateRepeatables,
1195
+ options,
1196
+ command_option_policies: commandOptionPolicies
1197
+ };
1198
+ }
1199
+ function applyTypeDefinitions(source, target) {
1200
+ for (const rawDefinition of source) {
1201
+ const normalizedDefinition = normalizeTypeDefinition(rawDefinition);
1202
+ if (!normalizedDefinition) {
1203
+ continue;
1204
+ }
1205
+ const lowerName = normalizedDefinition.name.toLowerCase();
1206
+ const existing = target.get(lowerName);
1207
+ const keepName = existing?.name ?? normalizedDefinition.name;
1208
+ const folder = normalizedDefinition.folder ?? existing?.folder ?? toDefaultFolder(keepName);
1209
+ const aliases = normalizeItemTypeStringList([
1210
+ ...existing?.aliases ?? [],
1211
+ ...normalizedDefinition.aliases ?? []
1212
+ ]);
1213
+ const requiredCreateFields = normalizedDefinition.required_create_fields ? normalizeItemTypeStringList(normalizedDefinition.required_create_fields) : existing?.required_create_fields ?? [];
1214
+ const requiredCreateRepeatables = normalizedDefinition.required_create_repeatables ? normalizeItemTypeStringList(normalizedDefinition.required_create_repeatables) : existing?.required_create_repeatables ?? [];
1215
+ const options = normalizedDefinition.options ? normalizedDefinition.options : existing?.options ? [...existing.options] : [];
1216
+ const commandOptionPolicies = normalizedDefinition.command_option_policies ? normalizedDefinition.command_option_policies : existing?.command_option_policies ? [...existing.command_option_policies] : [];
1217
+ const defaultStatus = normalizedDefinition.default_status ?? existing?.default_status;
1218
+ const description = normalizedDefinition.description ?? existing?.description;
1219
+ target.set(lowerName, {
1220
+ name: keepName,
1221
+ ...description ? { description } : {},
1222
+ ...defaultStatus ? { default_status: defaultStatus } : {},
1223
+ folder,
1224
+ aliases,
1225
+ required_create_fields: requiredCreateFields,
1226
+ required_create_repeatables: requiredCreateRepeatables,
1227
+ options,
1228
+ command_option_policies: commandOptionPolicies
1229
+ });
1230
+ }
1231
+ }
1232
+ function collectExtensionTypeDefinitions(registrations) {
1233
+ if (!registrations) {
1234
+ return [];
1235
+ }
1236
+ const definitions = [];
1237
+ for (const registration of registrations.item_types ?? []) {
1238
+ const typeDefinitionsRaw = registration.types;
1239
+ if (!Array.isArray(typeDefinitionsRaw)) {
1240
+ continue;
1241
+ }
1242
+ for (const rawDefinition of typeDefinitionsRaw) {
1243
+ const normalized = coerceTypeDefinitionFromUnknown(rawDefinition);
1244
+ if (normalized) {
1245
+ definitions.push(normalized);
1246
+ }
1247
+ }
1248
+ }
1249
+ return definitions;
1250
+ }
1251
+ function resolveItemTypeRegistry(settings, extensionRegistrations = null) {
1252
+ const byLowerName = /* @__PURE__ */ new Map();
1253
+ for (const builtin of ITEM_TYPE_VALUES) {
1254
+ byLowerName.set(builtin.toLowerCase(), {
1255
+ name: builtin,
1256
+ folder: TYPE_TO_FOLDER[builtin],
1257
+ aliases: [],
1258
+ required_create_fields: [...DEFAULT_REQUIRED_CREATE_FIELDS],
1259
+ required_create_repeatables: [...DEFAULT_REQUIRED_CREATE_REPEATABLES],
1260
+ options: [],
1261
+ command_option_policies: []
1262
+ });
1263
+ }
1264
+ applyTypeDefinitions(settings.item_types?.definitions ?? [], byLowerName);
1265
+ applyTypeDefinitions(collectExtensionTypeDefinitions(extensionRegistrations), byLowerName);
1266
+ const definitions = [...byLowerName.values()].sort((left, right) => left.name.localeCompare(right.name));
1267
+ const byType = {};
1268
+ const aliasToType = {};
1269
+ const typeToFolder = {};
1270
+ for (const definition of definitions) {
1271
+ byType[definition.name] = definition;
1272
+ typeToFolder[definition.name] = definition.folder;
1273
+ aliasToType[definition.name.toLowerCase()] = definition.name;
1274
+ for (const alias of definition.aliases) {
1275
+ aliasToType[alias.toLowerCase()] = definition.name;
1276
+ }
1277
+ }
1278
+ const folders = [...new Set(definitions.map((definition) => definition.folder))].sort((left, right) => left.localeCompare(right));
1279
+ return {
1280
+ types: definitions.map((definition) => definition.name),
1281
+ folders,
1282
+ type_to_folder: typeToFolder,
1283
+ by_type: byType,
1284
+ alias_to_type: aliasToType
1285
+ };
1286
+ }
1287
+ function resolveTypeName(rawType, registry) {
1288
+ if (rawType === void 0) {
1289
+ return void 0;
1290
+ }
1291
+ return registry.alias_to_type[rawType.trim().toLowerCase()];
1292
+ }
1293
+ function resolveTypeDefinition(typeName, registry) {
1294
+ const resolvedName = resolveTypeName(typeName, registry);
1295
+ if (!resolvedName) {
1296
+ return void 0;
1297
+ }
1298
+ return registry.by_type[resolvedName];
1299
+ }
1300
+ function resolveCommandOptionPolicyState(typeDefinition, command, baseRequiredOptions) {
1301
+ const errors = [];
1302
+ const required = /* @__PURE__ */ new Set();
1303
+ const hidden = /* @__PURE__ */ new Set();
1304
+ const disabled = /* @__PURE__ */ new Set();
1305
+ for (const rawBase of baseRequiredOptions) {
1306
+ const canonical = canonicalizeCommandOptionKey(command, rawBase);
1307
+ if (!canonical) {
1308
+ errors.push(`Unsupported base required option "${rawBase}" for command "${command}" on type "${typeDefinition.name}"`);
1309
+ continue;
1310
+ }
1311
+ required.add(canonical);
1312
+ }
1313
+ for (const policy of typeDefinition.command_option_policies) {
1314
+ if (policy.command !== command) {
1315
+ continue;
1316
+ }
1317
+ const canonical = canonicalizeCommandOptionKey(command, policy.option);
1318
+ if (!canonical) {
1319
+ errors.push(`Unsupported command_option_policies option "${policy.option}" for command "${command}" on type "${typeDefinition.name}"`);
1320
+ continue;
1321
+ }
1322
+ if (policy.required !== void 0) {
1323
+ if (policy.required) {
1324
+ required.add(canonical);
1325
+ } else {
1326
+ required.delete(canonical);
1327
+ }
1328
+ }
1329
+ if (policy.visible !== void 0) {
1330
+ if (policy.visible) {
1331
+ hidden.delete(canonical);
1332
+ } else {
1333
+ hidden.add(canonical);
1334
+ }
1335
+ }
1336
+ if (policy.enabled !== void 0) {
1337
+ if (policy.enabled) {
1338
+ disabled.delete(canonical);
1339
+ } else {
1340
+ disabled.add(canonical);
1341
+ }
1342
+ }
1343
+ }
1344
+ for (const option of required) {
1345
+ if (disabled.has(option)) {
1346
+ errors.push(`Option "${option}" cannot be both required and disabled for command "${command}" on type "${typeDefinition.name}"`);
1347
+ }
1348
+ }
1349
+ return {
1350
+ required: [...required],
1351
+ hidden: [...hidden].sort((left, right) => left.localeCompare(right)),
1352
+ disabled: [...disabled].sort((left, right) => left.localeCompare(right)),
1353
+ errors
1354
+ };
1355
+ }
1356
+ function validateTypeOptions(typeName, rawTypeOptions, registry) {
1357
+ const typeDefinition = resolveTypeDefinition(typeName, registry);
1358
+ if (!typeDefinition) {
1359
+ return {
1360
+ normalized: void 0,
1361
+ errors: [`Unknown type "${typeName}"`]
1362
+ };
1363
+ }
1364
+ const errors = [];
1365
+ const optionByAlias = /* @__PURE__ */ new Map();
1366
+ for (const option of typeDefinition.options) {
1367
+ optionByAlias.set(option.key.toLowerCase(), option);
1368
+ for (const alias of option.aliases ?? []) {
1369
+ optionByAlias.set(alias.toLowerCase(), option);
1370
+ }
1371
+ }
1372
+ const normalized = {};
1373
+ for (const [rawKey, rawValue] of Object.entries(rawTypeOptions ?? {})) {
1374
+ const trimmedKey = rawKey.trim();
1375
+ const trimmedValue = rawValue.trim();
1376
+ if (trimmedKey.length === 0) {
1377
+ errors.push("type option keys must not be empty");
1378
+ continue;
1379
+ }
1380
+ if (trimmedValue.length === 0) {
1381
+ errors.push(`type option "${trimmedKey}" must not be empty`);
1382
+ continue;
1383
+ }
1384
+ const optionDefinition = optionByAlias.get(trimmedKey.toLowerCase());
1385
+ if (!optionDefinition) {
1386
+ const allowed = typeDefinition.options.map((option) => option.key).join(", ");
1387
+ errors.push(typeDefinition.options.length > 0 ? `Unknown type option "${trimmedKey}" for type "${typeDefinition.name}". Allowed: ${allowed}` : `Type "${typeDefinition.name}" does not define any configurable type options`);
1388
+ continue;
1389
+ }
1390
+ const allowedValues = optionDefinition.values;
1391
+ let resolvedValue = trimmedValue;
1392
+ if (allowedValues.length > 0) {
1393
+ const valueLookup = new Map(allowedValues.map((value) => [value.toLowerCase(), value]));
1394
+ const canonical = valueLookup.get(trimmedValue.toLowerCase());
1395
+ if (!canonical) {
1396
+ errors.push(`Invalid value "${trimmedValue}" for type option "${optionDefinition.key}". Allowed: ${allowedValues.join(", ")}`);
1397
+ continue;
1398
+ }
1399
+ resolvedValue = canonical;
1400
+ }
1401
+ normalized[optionDefinition.key] = resolvedValue;
1402
+ }
1403
+ for (const option of typeDefinition.options) {
1404
+ if (option.required && !(option.key in normalized)) {
1405
+ errors.push(`Missing required type option "${option.key}" for type "${typeDefinition.name}"`);
1406
+ }
1407
+ }
1408
+ const sortedKeys = Object.keys(normalized).sort((left, right) => left.localeCompare(right));
1409
+ if (sortedKeys.length === 0) {
1410
+ return {
1411
+ normalized: void 0,
1412
+ errors
1413
+ };
1414
+ }
1415
+ return {
1416
+ normalized: Object.fromEntries(sortedKeys.map((key) => [key, normalized[key]])),
1417
+ errors
1418
+ };
1419
+ }
1420
+
611
1421
  // dist/core/store/paths.js
612
1422
  import { statSync } from "node:fs";
613
1423
  import os from "node:os";
@@ -672,37 +1482,8 @@ function resolveGlobalPmRoot(cwd) {
672
1482
  function getSettingsPath(pmRoot) {
673
1483
  return path4.join(pmRoot, SETTINGS_FILENAME);
674
1484
  }
675
- function deriveDefaultTypeFolder(type) {
676
- const normalized = toSlugToken(type);
677
- if (normalized.length === 0) {
678
- return "items";
679
- }
680
- return normalized.endsWith("s") ? normalized : `${normalized}s`;
681
- }
682
- function toSlugToken(value) {
683
- const trimmed = value.trim().toLowerCase();
684
- let slug = "";
685
- let pendingDash = false;
686
- for (const character of trimmed) {
687
- const code = character.charCodeAt(0);
688
- const isAlpha = code >= 97 && code <= 122;
689
- const isDigit = code >= 48 && code <= 57;
690
- if (isAlpha || isDigit) {
691
- if (pendingDash && slug.length > 0) {
692
- slug += "-";
693
- }
694
- slug += character;
695
- pendingDash = false;
696
- continue;
697
- }
698
- if (slug.length > 0) {
699
- pendingDash = true;
700
- }
701
- }
702
- return slug;
703
- }
704
1485
  function getTypeDirPath(pmRoot, type, typeToFolder = TYPE_TO_FOLDER) {
705
- const folder = typeToFolder[type] ?? deriveDefaultTypeFolder(type);
1486
+ const folder = typeToFolder[type] ?? toDefaultFolder(type);
706
1487
  return path4.join(pmRoot, folder);
707
1488
  }
708
1489
  function getItemPath(pmRoot, type, id, itemFormat = "toon", typeToFolder = TYPE_TO_FOLDER) {
@@ -806,6 +1587,51 @@ function asRecordLoose(value) {
806
1587
  return value;
807
1588
  }
808
1589
 
1590
+ // dist/core/shared/levenshtein.js
1591
+ function levenshteinDistanceWithinLimit(left, right, limit) {
1592
+ if (left === right) {
1593
+ return 0;
1594
+ }
1595
+ if (Math.abs(left.length - right.length) > limit) {
1596
+ return null;
1597
+ }
1598
+ const width = right.length + 1;
1599
+ const beforePrevious = new Array(width);
1600
+ const previous = new Array(width);
1601
+ const current = new Array(width);
1602
+ for (let column = 0; column < width; column += 1) {
1603
+ beforePrevious[column] = 0;
1604
+ previous[column] = column;
1605
+ }
1606
+ for (let row = 1; row <= left.length; row += 1) {
1607
+ current[0] = row;
1608
+ let rowMin = current[0];
1609
+ for (let column = 1; column <= right.length; column += 1) {
1610
+ const cost = left[row - 1] === right[column - 1] ? 0 : 1;
1611
+ const substitution = previous[column - 1] + cost;
1612
+ const insertion = current[column - 1] + 1;
1613
+ const deletion = previous[column] + 1;
1614
+ let candidate = Math.min(substitution, insertion, deletion);
1615
+ if (row > 1 && column > 1 && left[row - 1] === right[column - 2] && left[row - 2] === right[column - 1]) {
1616
+ candidate = Math.min(candidate, beforePrevious[column - 2] + 1);
1617
+ }
1618
+ current[column] = candidate;
1619
+ if (candidate < rowMin) {
1620
+ rowMin = candidate;
1621
+ }
1622
+ }
1623
+ if (rowMin > limit) {
1624
+ return null;
1625
+ }
1626
+ for (let column = 0; column < width; column += 1) {
1627
+ beforePrevious[column] = previous[column];
1628
+ previous[column] = current[column];
1629
+ }
1630
+ }
1631
+ const result = previous[right.length];
1632
+ return result <= limit ? result : null;
1633
+ }
1634
+
809
1635
  // dist/core/extensions/extension-registries.js
810
1636
  function createEmptyExtensionHookRegistry() {
811
1637
  return {
@@ -849,6 +1675,7 @@ function createEmptyExtensionRegistrationRegistry() {
849
1675
  item_fields: [],
850
1676
  item_types: [],
851
1677
  migrations: [],
1678
+ profiles: [],
852
1679
  importers: [],
853
1680
  exporters: [],
854
1681
  search_providers: [],
@@ -1329,51 +2156,6 @@ function isFlagDefaultValueCoercible(value, kind) {
1329
2156
  return typeof value === "string" && ["true", "false", "1", "0"].includes(value.trim().toLowerCase());
1330
2157
  }
1331
2158
 
1332
- // dist/core/shared/levenshtein.js
1333
- function levenshteinDistanceWithinLimit(left, right, limit) {
1334
- if (left === right) {
1335
- return 0;
1336
- }
1337
- if (Math.abs(left.length - right.length) > limit) {
1338
- return null;
1339
- }
1340
- const width = right.length + 1;
1341
- const beforePrevious = new Array(width);
1342
- const previous = new Array(width);
1343
- const current = new Array(width);
1344
- for (let column = 0; column < width; column += 1) {
1345
- beforePrevious[column] = 0;
1346
- previous[column] = column;
1347
- }
1348
- for (let row = 1; row <= left.length; row += 1) {
1349
- current[0] = row;
1350
- let rowMin = current[0];
1351
- for (let column = 1; column <= right.length; column += 1) {
1352
- const cost = left[row - 1] === right[column - 1] ? 0 : 1;
1353
- const substitution = previous[column - 1] + cost;
1354
- const insertion = current[column - 1] + 1;
1355
- const deletion = previous[column] + 1;
1356
- let candidate = Math.min(substitution, insertion, deletion);
1357
- if (row > 1 && column > 1 && left[row - 1] === right[column - 2] && left[row - 2] === right[column - 1]) {
1358
- candidate = Math.min(candidate, beforePrevious[column - 2] + 1);
1359
- }
1360
- current[column] = candidate;
1361
- if (candidate < rowMin) {
1362
- rowMin = candidate;
1363
- }
1364
- }
1365
- if (rowMin > limit) {
1366
- return null;
1367
- }
1368
- for (let column = 0; column < width; column += 1) {
1369
- beforePrevious[column] = previous[column];
1370
- previous[column] = current[column];
1371
- }
1372
- }
1373
- const result = previous[right.length];
1374
- return result <= limit ? result : null;
1375
- }
1376
-
1377
2159
  // dist/core/extensions/item-field-types.js
1378
2160
  var KNOWN_ITEM_FIELD_TYPES = ["string", "number", "boolean", "array", "object"];
1379
2161
  function normalizeItemFieldType(value) {
@@ -1394,6 +2176,93 @@ function suggestKnownItemFieldType(value) {
1394
2176
  return null;
1395
2177
  }
1396
2178
 
2179
+ // dist/core/extensions/version-compat.js
2180
+ function formatVersionBoundValue(value) {
2181
+ return typeof value === "string" ? value : String(value);
2182
+ }
2183
+ function parseComparableVersion(value) {
2184
+ const normalized = value.trim().replace(/^>=\s*/, "").replace(/^v/i, "");
2185
+ const release = normalized.split(/[+-]/, 1)[0];
2186
+ if (!/^\d+(?:[.-]\d+)*$/.test(release)) {
2187
+ return null;
2188
+ }
2189
+ return release.split(/[.-]/).map((part) => Number(part));
2190
+ }
2191
+ function compareComparableVersions(currentVersion, otherVersion) {
2192
+ const currentParts = parseComparableVersion(currentVersion);
2193
+ const otherParts = parseComparableVersion(otherVersion);
2194
+ if (!currentParts || !otherParts) {
2195
+ return null;
2196
+ }
2197
+ const width = Math.max(currentParts.length, otherParts.length);
2198
+ for (let index = 0; index < width; index += 1) {
2199
+ const current = currentParts[index] ?? 0;
2200
+ const other = otherParts[index] ?? 0;
2201
+ if (current > other) {
2202
+ return 1;
2203
+ }
2204
+ if (current < other) {
2205
+ return -1;
2206
+ }
2207
+ }
2208
+ return 0;
2209
+ }
2210
+ function evaluatePmMinVersionBound(required, currentVersion) {
2211
+ if (required === void 0 || required === null) {
2212
+ return { kind: "pm_min_version", status: "absent", allowed: true, required: "", current: currentVersion };
2213
+ }
2214
+ const declared = formatVersionBoundValue(required);
2215
+ if (typeof required !== "string" || declared.trim().length === 0) {
2216
+ return { kind: "pm_min_version", status: "invalid", allowed: false, required: declared, current: currentVersion };
2217
+ }
2218
+ if (!parseComparableVersion(declared)) {
2219
+ return { kind: "pm_min_version", status: "invalid", allowed: false, required: declared, current: currentVersion };
2220
+ }
2221
+ if (currentVersion === null) {
2222
+ return { kind: "pm_min_version", status: "unchecked", allowed: true, required: declared, current: null };
2223
+ }
2224
+ const comparison = compareComparableVersions(currentVersion, declared);
2225
+ if (comparison === null) {
2226
+ return { kind: "pm_min_version", status: "unchecked", allowed: true, required: declared, current: currentVersion };
2227
+ }
2228
+ if (comparison < 0) {
2229
+ return { kind: "pm_min_version", status: "unmet", allowed: false, required: declared, current: currentVersion };
2230
+ }
2231
+ return { kind: "pm_min_version", status: "ok", allowed: true, required: declared, current: currentVersion };
2232
+ }
2233
+ function evaluatePmMaxVersionBound(required, currentVersion, exceededMode) {
2234
+ if (required === void 0 || required === null) {
2235
+ return { kind: "pm_max_version", status: "absent", allowed: true, required: "", current: currentVersion };
2236
+ }
2237
+ const declared = formatVersionBoundValue(required);
2238
+ if (typeof required !== "string" || declared.trim().length === 0) {
2239
+ return { kind: "pm_max_version", status: "invalid", allowed: false, required: declared, current: currentVersion };
2240
+ }
2241
+ if (/^[<>=~^]/.test(declared.trim()) || !parseComparableVersion(declared)) {
2242
+ return { kind: "pm_max_version", status: "invalid", allowed: false, required: declared, current: currentVersion };
2243
+ }
2244
+ if (currentVersion === null) {
2245
+ return { kind: "pm_max_version", status: "unchecked", allowed: true, required: declared, current: null };
2246
+ }
2247
+ const comparison = compareComparableVersions(currentVersion, declared);
2248
+ if (comparison === null) {
2249
+ return { kind: "pm_max_version", status: "unchecked", allowed: true, required: declared, current: currentVersion };
2250
+ }
2251
+ if (comparison > 0) {
2252
+ if (exceededMode === "warn") {
2253
+ return {
2254
+ kind: "pm_max_version",
2255
+ status: "exceeded_warn",
2256
+ allowed: true,
2257
+ required: declared,
2258
+ current: currentVersion
2259
+ };
2260
+ }
2261
+ return { kind: "pm_max_version", status: "exceeded", allowed: false, required: declared, current: currentVersion };
2262
+ }
2263
+ return { kind: "pm_max_version", status: "ok", allowed: true, required: declared, current: currentVersion };
2264
+ }
2265
+
1397
2266
  // dist/core/extensions/extension-capability-aliases.js
1398
2267
  function normalizeNames(values) {
1399
2268
  return [...new Set(values.map((value) => value.trim()).filter((value) => value.length > 0))].sort((a, b) => a.localeCompare(b));
@@ -2503,33 +3372,6 @@ function formatUnknownError(error) {
2503
3372
  }
2504
3373
  return String(error);
2505
3374
  }
2506
- function parseComparableVersion(value) {
2507
- const normalized = value.trim().replace(/^>=\s*/, "").replace(/^v/i, "");
2508
- const release = normalized.split(/[+-]/, 1)[0];
2509
- if (!/^\d+(?:[.-]\d+)*$/.test(release)) {
2510
- return null;
2511
- }
2512
- return release.split(/[.-]/).map((part) => Number(part));
2513
- }
2514
- function compareComparableVersions(currentVersion, minimumVersion) {
2515
- const currentParts = parseComparableVersion(currentVersion);
2516
- const minimumParts = parseComparableVersion(minimumVersion);
2517
- if (!currentParts || !minimumParts) {
2518
- return null;
2519
- }
2520
- const width = Math.max(currentParts.length, minimumParts.length);
2521
- for (let index = 0; index < width; index += 1) {
2522
- const current = currentParts[index] ?? 0;
2523
- const minimum = minimumParts[index] ?? 0;
2524
- if (current > minimum) {
2525
- return 1;
2526
- }
2527
- if (current < minimum) {
2528
- return -1;
2529
- }
2530
- }
2531
- return 0;
2532
- }
2533
3375
  async function readCurrentPmCliVersion() {
2534
3376
  try {
2535
3377
  const packageRoot = resolvePmPackageRootFromModule(import.meta.url, ["../../.."]);
@@ -2544,81 +3386,48 @@ function resolveCurrentPmCliVersion() {
2544
3386
  currentPmCliVersionPromise ??= readCurrentPmCliVersion();
2545
3387
  return currentPmCliVersionPromise;
2546
3388
  }
2547
- async function evaluatePmMinVersionCompatibility(layer, manifest) {
2548
- if (typeof manifest.pm_min_version !== "string" || manifest.pm_min_version.trim().length === 0) {
2549
- return { allowed: true };
2550
- }
2551
- if (!parseComparableVersion(manifest.pm_min_version)) {
2552
- return {
2553
- allowed: false,
2554
- warning: `extension_pm_min_version_invalid:${layer}:${manifest.name}:required=${manifest.pm_min_version}`
2555
- };
2556
- }
2557
- const currentVersion = await resolveCurrentPmCliVersion();
2558
- if (!currentVersion) {
2559
- return {
2560
- allowed: true,
2561
- warning: `extension_pm_min_version_unchecked:${layer}:${manifest.name}:required=${manifest.pm_min_version}:current=unknown`
2562
- };
3389
+ function formatPmVersionCompatibilityWarning(layer, manifest, evaluation) {
3390
+ const current = evaluation.current ?? "unknown";
3391
+ if (evaluation.kind === "pm_min_version") {
3392
+ switch (evaluation.status) {
3393
+ case "invalid":
3394
+ return `extension_pm_min_version_invalid:${layer}:${manifest.name}:required=${evaluation.required}`;
3395
+ case "unchecked":
3396
+ return `extension_pm_min_version_unchecked:${layer}:${manifest.name}:required=${evaluation.required}:current=${current}`;
3397
+ case "unmet":
3398
+ return `extension_pm_min_version_unmet:${layer}:${manifest.name}:required=${evaluation.required}:current=${current}`;
3399
+ default:
3400
+ return void 0;
3401
+ }
2563
3402
  }
2564
- const comparison = compareComparableVersions(currentVersion, manifest.pm_min_version);
2565
- if (comparison === null) {
2566
- return {
2567
- allowed: true,
2568
- warning: `extension_pm_min_version_unchecked:${layer}:${manifest.name}:required=${manifest.pm_min_version}:current=${currentVersion}`
2569
- };
3403
+ switch (evaluation.status) {
3404
+ case "invalid":
3405
+ return `extension_pm_max_version_invalid:${layer}:${manifest.name}:allowed=${evaluation.required}`;
3406
+ case "unchecked":
3407
+ return `extension_pm_max_version_unchecked:${layer}:${manifest.name}:allowed=${evaluation.required}:current=${current}`;
3408
+ case "exceeded_warn":
3409
+ return `extension_pm_max_version_exceeded_warn:${layer}:${manifest.name}:allowed=${evaluation.required}:current=${current}`;
3410
+ case "exceeded":
3411
+ return `extension_pm_max_version_exceeded:${layer}:${manifest.name}:allowed=${evaluation.required}:current=${current}`;
3412
+ default:
3413
+ return void 0;
2570
3414
  }
2571
- if (comparison < 0) {
2572
- return {
2573
- allowed: false,
2574
- warning: `extension_pm_min_version_unmet:${layer}:${manifest.name}:required=${manifest.pm_min_version}:current=${currentVersion}`
2575
- };
3415
+ }
3416
+ async function evaluatePmMinVersionCompatibility(layer, manifest) {
3417
+ if (manifest.pm_min_version === void 0) {
3418
+ return { allowed: true };
2576
3419
  }
2577
- return { allowed: true };
3420
+ const evaluation = evaluatePmMinVersionBound(manifest.pm_min_version, await resolveCurrentPmCliVersion());
3421
+ const warning = formatPmVersionCompatibilityWarning(layer, manifest, evaluation);
3422
+ return warning ? { allowed: evaluation.allowed, warning } : { allowed: evaluation.allowed };
2578
3423
  }
2579
3424
  async function evaluatePmMaxVersionCompatibility(layer, manifest, exceededMode) {
2580
- if (typeof manifest.pm_max_version !== "string" || manifest.pm_max_version.trim().length === 0) {
3425
+ if (manifest.pm_max_version === void 0) {
2581
3426
  return { allowed: true };
2582
3427
  }
2583
- if (/^[<>=~^]/.test(manifest.pm_max_version.trim())) {
2584
- return {
2585
- allowed: false,
2586
- warning: `extension_pm_max_version_invalid:${layer}:${manifest.name}:allowed=${manifest.pm_max_version}`
2587
- };
2588
- }
2589
- if (!parseComparableVersion(manifest.pm_max_version)) {
2590
- return {
2591
- allowed: false,
2592
- warning: `extension_pm_max_version_invalid:${layer}:${manifest.name}:allowed=${manifest.pm_max_version}`
2593
- };
2594
- }
2595
- const currentVersion = await resolveCurrentPmCliVersion();
2596
- if (!currentVersion) {
2597
- return {
2598
- allowed: true,
2599
- warning: `extension_pm_max_version_unchecked:${layer}:${manifest.name}:allowed=${manifest.pm_max_version}:current=unknown`
2600
- };
2601
- }
2602
- const comparison = compareComparableVersions(currentVersion, manifest.pm_max_version);
2603
- if (comparison === null) {
2604
- return {
2605
- allowed: true,
2606
- warning: `extension_pm_max_version_unchecked:${layer}:${manifest.name}:allowed=${manifest.pm_max_version}:current=${currentVersion}`
2607
- };
2608
- }
2609
- if (comparison > 0) {
2610
- if (exceededMode === "warn") {
2611
- return {
2612
- allowed: true,
2613
- warning: `extension_pm_max_version_exceeded_warn:${layer}:${manifest.name}:allowed=${manifest.pm_max_version}:current=${currentVersion}`
2614
- };
2615
- }
2616
- return {
2617
- allowed: false,
2618
- warning: `extension_pm_max_version_exceeded:${layer}:${manifest.name}:allowed=${manifest.pm_max_version}:current=${currentVersion}`
2619
- };
2620
- }
2621
- return { allowed: true };
3428
+ const evaluation = evaluatePmMaxVersionBound(manifest.pm_max_version, await resolveCurrentPmCliVersion(), exceededMode);
3429
+ const warning = formatPmVersionCompatibilityWarning(layer, manifest, evaluation);
3430
+ return warning ? { allowed: evaluation.allowed, warning } : { allowed: evaluation.allowed };
2622
3431
  }
2623
3432
  async function fingerprintPath(pathToInspect) {
2624
3433
  try {
@@ -3051,6 +3860,86 @@ function validateMigrationDefinition(definition) {
3051
3860
  throw new TypeError("registerMigration definition.run must be a function when provided");
3052
3861
  }
3053
3862
  }
3863
+ var PROJECT_PROFILE_DIMENSIONS = [
3864
+ "types",
3865
+ "statuses",
3866
+ "fields",
3867
+ "workflows",
3868
+ "config",
3869
+ "templates",
3870
+ "packages"
3871
+ ];
3872
+ function validateProjectProfileEntryShape(dimension, index, entry) {
3873
+ const at = `registerProfile profile.${dimension}[${index}]`;
3874
+ if (dimension === "types") {
3875
+ if (entry.name !== void 0 && typeof entry.name !== "string") {
3876
+ throw new TypeError(`${at}.name must be a string when provided`);
3877
+ }
3878
+ return;
3879
+ }
3880
+ if (dimension === "workflows") {
3881
+ if (typeof entry.type !== "string") {
3882
+ throw new TypeError(`${at}.type must be a string`);
3883
+ }
3884
+ if (!Array.isArray(entry.allowed_transitions)) {
3885
+ throw new TypeError(`${at}.allowed_transitions must be an array`);
3886
+ }
3887
+ for (const [pairIndex, pair] of entry.allowed_transitions.entries()) {
3888
+ if (!Array.isArray(pair)) {
3889
+ throw new TypeError(`${at}.allowed_transitions[${pairIndex}] must be a [from, to] array`);
3890
+ }
3891
+ }
3892
+ return;
3893
+ }
3894
+ if (dimension === "templates") {
3895
+ if (typeof entry.name !== "string") {
3896
+ throw new TypeError(`${at}.name must be a string`);
3897
+ }
3898
+ if (typeof entry.options !== "object" || entry.options === null || Array.isArray(entry.options)) {
3899
+ throw new TypeError(`${at}.options must be an object`);
3900
+ }
3901
+ return;
3902
+ }
3903
+ if (dimension === "packages") {
3904
+ if (typeof entry.spec !== "string") {
3905
+ throw new TypeError(`${at}.spec must be a string`);
3906
+ }
3907
+ }
3908
+ }
3909
+ function validateProjectProfileDefinition(profile) {
3910
+ const record = asRegistrationRecord("registerProfile profile", profile);
3911
+ assertNonEmptyString("registerProfile profile.name", record.name);
3912
+ assertNonEmptyString("registerProfile profile.title", record.title);
3913
+ if (record.summary !== void 0 && typeof record.summary !== "string") {
3914
+ throw new TypeError("registerProfile profile.summary must be a string when provided");
3915
+ }
3916
+ for (const dimension of PROJECT_PROFILE_DIMENSIONS) {
3917
+ const value = record[dimension];
3918
+ if (value === void 0) {
3919
+ continue;
3920
+ }
3921
+ if (!Array.isArray(value)) {
3922
+ throw new TypeError(`registerProfile profile.${dimension} must be an array when provided`);
3923
+ }
3924
+ for (const [index, entry] of value.entries()) {
3925
+ if (typeof entry !== "object" || entry === null || Array.isArray(entry)) {
3926
+ throw new TypeError(`registerProfile profile.${dimension}[${index}] must be an object`);
3927
+ }
3928
+ validateProjectProfileEntryShape(dimension, index, entry);
3929
+ }
3930
+ }
3931
+ }
3932
+ function applyProjectProfileDefaults(profile) {
3933
+ if (profile.summary === void 0) {
3934
+ profile.summary = "";
3935
+ }
3936
+ for (const dimension of PROJECT_PROFILE_DIMENSIONS) {
3937
+ if (profile[dimension] === void 0) {
3938
+ profile[dimension] = [];
3939
+ }
3940
+ }
3941
+ return profile;
3942
+ }
3054
3943
  function attachRuntimeDefinition(entry, runtimeDefinition) {
3055
3944
  Object.defineProperty(entry, "runtime_definition", {
3056
3945
  value: runtimeDefinition,
@@ -3352,6 +4241,19 @@ function createExtensionApi(extension, hooks, commands, parsers, preflight, serv
3352
4241
  definition: normalizeRegistrationRecord("registerMigration definition", definition)
3353
4242
  }, runtimeDefinition));
3354
4243
  };
4244
+ const registerProfile = (profile) => {
4245
+ assertExtensionCapability(extension, "schema", "registerProfile");
4246
+ if (!allowRegistration("schema.profiles", "registerProfile", "schema")) {
4247
+ return;
4248
+ }
4249
+ const snapshot = cloneRuntimeRegistrationValue(profile);
4250
+ validateProjectProfileDefinition(snapshot);
4251
+ registrations.profiles.push({
4252
+ layer: extension.layer,
4253
+ name: extension.name,
4254
+ profile: applyProjectProfileDefaults(snapshot)
4255
+ });
4256
+ };
3355
4257
  const applyImportExportCommandMetadata = (method, commandPath, options) => {
3356
4258
  if (options === void 0) {
3357
4259
  return;
@@ -3550,6 +4452,7 @@ function createExtensionApi(extension, hooks, commands, parsers, preflight, serv
3550
4452
  registerItemFields,
3551
4453
  registerItemTypes,
3552
4454
  registerMigration,
4455
+ registerProfile,
3553
4456
  registerRenderer,
3554
4457
  registerImporter,
3555
4458
  registerExporter,
@@ -3575,6 +4478,7 @@ function getRegistrationCounts(registrations) {
3575
4478
  item_fields: itemFieldCount,
3576
4479
  item_types: itemTypeCount,
3577
4480
  migrations: registrations.migrations.length,
4481
+ profiles: registrations.profiles.length,
3578
4482
  importers: registrations.importers.length,
3579
4483
  exporters: registrations.exporters.length,
3580
4484
  search_providers: registrations.search_providers.length,
@@ -3800,6 +4704,7 @@ function attributeCapabilityUsage(activation) {
3800
4704
  record(registrations.item_fields, "schema");
3801
4705
  record(registrations.item_types, "schema");
3802
4706
  record(registrations.migrations, "schema");
4707
+ record(registrations.profiles, "schema");
3803
4708
  record(registrations.importers, "importers");
3804
4709
  record(registrations.exporters, "importers");
3805
4710
  record(registrations.search_providers, "search");
@@ -4042,154 +4947,49 @@ function runActiveRendererOverride(format, result) {
4042
4947
  overridden: false,
4043
4948
  rendered: null,
4044
4949
  warnings: []
4045
- };
4046
- }
4047
- return runRendererOverride(activeExtensionRenderers, {
4048
- format,
4049
- command: activeCommandContext?.command,
4050
- args: activeCommandContext ? [...activeCommandContext.args] : [],
4051
- options: activeCommandContext?.options ? { ...activeCommandContext.options } : {},
4052
- global: activeCommandContext?.global ? { ...activeCommandContext.global } : void 0,
4053
- pm_root: activeCommandContext?.pm_root,
4054
- result
4055
- });
4056
- }
4057
- function buildServiceContext(service, payload) {
4058
- return {
4059
- service,
4060
- command: activeCommandContext?.command,
4061
- args: activeCommandContext ? [...activeCommandContext.args] : [],
4062
- options: activeCommandContext?.options ? { ...activeCommandContext.options } : {},
4063
- global: activeCommandContext?.global ? { ...activeCommandContext.global } : void 0,
4064
- pm_root: activeCommandContext?.pm_root,
4065
- payload
4066
- };
4067
- }
4068
- async function runActiveServiceOverride(service, payload) {
4069
- if (!activeExtensionServices) {
4070
- return {
4071
- handled: false,
4072
- result: payload,
4073
- warnings: []
4074
- };
4075
- }
4076
- return runServiceOverride(activeExtensionServices, buildServiceContext(service, payload));
4077
- }
4078
- function runActiveServiceOverrideSync(service, payload) {
4079
- if (!activeExtensionServices) {
4080
- return {
4081
- handled: false,
4082
- result: payload,
4083
- warnings: []
4084
- };
4085
- }
4086
- return runServiceOverrideSync(activeExtensionServices, buildServiceContext(service, payload));
4087
- }
4088
-
4089
- // dist/types.js
4090
- var BUILTIN_ITEM_TYPE_VALUES = [
4091
- "Epic",
4092
- "Feature",
4093
- "Task",
4094
- "Chore",
4095
- "Issue",
4096
- "Decision",
4097
- "Event",
4098
- "Reminder",
4099
- "Milestone",
4100
- "Meeting",
4101
- "Plan"
4102
- ];
4103
- var ITEM_TYPE_VALUES = BUILTIN_ITEM_TYPE_VALUES;
4104
- var STATUS_VALUES = [
4105
- "draft",
4106
- "open",
4107
- "in_progress",
4108
- "blocked",
4109
- "closed",
4110
- "canceled"
4111
- ];
4112
- var RUNTIME_STATUS_ROLE_VALUES = [
4113
- "draft",
4114
- "active",
4115
- "blocked",
4116
- "terminal",
4117
- "terminal_done",
4118
- "terminal_canceled",
4119
- "default_open",
4120
- "default_close",
4121
- "default_cancel"
4122
- ];
4123
- var RUNTIME_FIELD_TYPE_VALUES = ["string", "number", "boolean", "string_array"];
4124
- var RUNTIME_FIELD_COMMAND_VALUES = ["create", "update", "update_many", "list", "search", "calendar", "context"];
4125
- var RUNTIME_UNKNOWN_FIELD_POLICY_VALUES = ["allow", "warn", "reject"];
4126
- var DEPENDENCY_KIND_VALUES = [
4127
- "blocks",
4128
- "parent",
4129
- "child",
4130
- "parent_child",
4131
- "child_of",
4132
- "related",
4133
- "related_to",
4134
- "discovered_from",
4135
- "blocked_by",
4136
- "incident_from",
4137
- "epic",
4138
- "supersedes",
4139
- "task"
4140
- ];
4141
- var SCOPE_VALUES = ["project", "global"];
4142
- var RISK_VALUES = ["low", "medium", "high", "critical"];
4143
- var ISSUE_SEVERITY_VALUES = ["low", "medium", "high", "critical"];
4144
- var CONFIDENCE_TEXT_VALUES = ["low", "medium", "high"];
4145
- var GOVERNANCE_PRESET_VALUES = ["minimal", "default", "strict", "custom"];
4146
- var RECURRENCE_FREQUENCY_VALUES = ["daily", "weekly", "monthly", "yearly"];
4147
- var RECURRENCE_WEEKDAY_VALUES = ["mon", "tue", "wed", "thu", "fri", "sat", "sun"];
4148
- function weekdayOrderIndex(value) {
4149
- return RECURRENCE_WEEKDAY_VALUES.indexOf(value);
4950
+ };
4951
+ }
4952
+ return runRendererOverride(activeExtensionRenderers, {
4953
+ format,
4954
+ command: activeCommandContext?.command,
4955
+ args: activeCommandContext ? [...activeCommandContext.args] : [],
4956
+ options: activeCommandContext?.options ? { ...activeCommandContext.options } : {},
4957
+ global: activeCommandContext?.global ? { ...activeCommandContext.global } : void 0,
4958
+ pm_root: activeCommandContext?.pm_root,
4959
+ result
4960
+ });
4961
+ }
4962
+ function buildServiceContext(service, payload) {
4963
+ return {
4964
+ service,
4965
+ command: activeCommandContext?.command,
4966
+ args: activeCommandContext ? [...activeCommandContext.args] : [],
4967
+ options: activeCommandContext?.options ? { ...activeCommandContext.options } : {},
4968
+ global: activeCommandContext?.global ? { ...activeCommandContext.global } : void 0,
4969
+ pm_root: activeCommandContext?.pm_root,
4970
+ payload
4971
+ };
4972
+ }
4973
+ async function runActiveServiceOverride(service, payload) {
4974
+ if (!activeExtensionServices) {
4975
+ return {
4976
+ handled: false,
4977
+ result: payload,
4978
+ warnings: []
4979
+ };
4980
+ }
4981
+ return runServiceOverride(activeExtensionServices, buildServiceContext(service, payload));
4982
+ }
4983
+ function runActiveServiceOverrideSync(service, payload) {
4984
+ if (!activeExtensionServices) {
4985
+ return {
4986
+ handled: false,
4987
+ result: payload,
4988
+ warnings: []
4989
+ };
4990
+ }
4991
+ return runServiceOverrideSync(activeExtensionServices, buildServiceContext(service, payload));
4150
4992
  }
4151
- var PLAN_MODE_VALUES = [
4152
- "draft",
4153
- "research",
4154
- "review",
4155
- "approved",
4156
- "executing",
4157
- "paused",
4158
- "completed",
4159
- "superseded"
4160
- ];
4161
- var PLAN_STEP_STATUS_VALUES = [
4162
- "pending",
4163
- "in_progress",
4164
- "completed",
4165
- "blocked",
4166
- "skipped",
4167
- "superseded"
4168
- ];
4169
- var PLAN_HARNESS_VALUES = ["codex", "claude-code", "cursor", "generic"];
4170
- var PLAN_STEP_LINK_KIND_VALUES = [
4171
- "related",
4172
- "blocks",
4173
- "blocked_by",
4174
- "depends_on",
4175
- "discovered_from",
4176
- "implements",
4177
- "verifies",
4178
- "supersedes"
4179
- ];
4180
- var CONTEXT_DEPTH_VALUES = ["brief", "standard", "deep", "full"];
4181
- var CONTEXT_SECTION_VALUES = [
4182
- "hierarchy",
4183
- "activity",
4184
- "progress",
4185
- "recently_created",
4186
- "unparented",
4187
- "blockers",
4188
- "files",
4189
- "workload",
4190
- "staleness",
4191
- "tests"
4192
- ];
4193
4993
 
4194
4994
  // dist/core/schema/runtime-schema.js
4195
4995
  import path6 from "node:path";
@@ -4348,7 +5148,7 @@ function normalizeRuntimeFieldDefinition(definition) {
4348
5148
  function normalizeRuntimeSchemaSettings(schema) {
4349
5149
  const files = {
4350
5150
  ...DEFAULT_RUNTIME_SCHEMA_FILE_PATHS,
4351
- ...schema?.files ?? {}
5151
+ ...schema?.files
4352
5152
  };
4353
5153
  const statusesSource = schema?.statuses && schema.statuses.length > 0 ? schema.statuses : DEFAULT_RUNTIME_STATUS_DEFINITIONS;
4354
5154
  const normalizedStatuses = (() => {
@@ -4613,7 +5413,7 @@ async function loadRuntimeSchemaFromOptionalFiles(pmRoot, schema) {
4613
5413
  fields: [...normalizedSchema.fields, ...loadedFields ?? []],
4614
5414
  workflow: {
4615
5415
  ...normalizedSchema.workflow,
4616
- ...loadedWorkflow ?? {}
5416
+ ...loadedWorkflow
4617
5417
  },
4618
5418
  type_workflows: [...normalizedSchema.type_workflows ?? [], ...loadedTypeWorkflows ?? []]
4619
5419
  });
@@ -4811,74 +5611,73 @@ function sortObjectKeys(value) {
4811
5611
  function stableStringify(value) {
4812
5612
  return JSON.stringify(sortObjectKeys(value));
4813
5613
  }
4814
- function stableValueEquals(left, right) {
4815
- if (Object.is(left, right)) {
4816
- return true;
5614
+ function hasUnmatchedEquivalent(leftValue, rightValues, matchedIndexes, equals) {
5615
+ for (let index = 0; index < rightValues.length; index += 1) {
5616
+ if (matchedIndexes.has(index)) {
5617
+ continue;
5618
+ }
5619
+ if (equals(leftValue, rightValues[index])) {
5620
+ matchedIndexes.add(index);
5621
+ return true;
5622
+ }
4817
5623
  }
4818
- if (left === null || right === null || typeof left !== "object" || typeof right !== "object") {
4819
- return false;
5624
+ return false;
5625
+ }
5626
+ function compareRegExpValues(left, right) {
5627
+ if (!(left instanceof RegExp || right instanceof RegExp)) {
5628
+ return void 0;
5629
+ }
5630
+ return left instanceof RegExp && right instanceof RegExp && left.toString() === right.toString();
5631
+ }
5632
+ function compareDateValues(left, right) {
5633
+ if (!(left instanceof Date || right instanceof Date)) {
5634
+ return void 0;
4820
5635
  }
4821
- if (left instanceof RegExp || right instanceof RegExp) {
4822
- return left instanceof RegExp && right instanceof RegExp && left.toString() === right.toString();
5636
+ return left instanceof Date && right instanceof Date && left.getTime() === right.getTime();
5637
+ }
5638
+ function compareSetValues(left, right) {
5639
+ if (!(left instanceof Set || right instanceof Set)) {
5640
+ return void 0;
4823
5641
  }
4824
- if (left instanceof Date || right instanceof Date) {
4825
- return left instanceof Date && right instanceof Date && left.getTime() === right.getTime();
5642
+ if (!(left instanceof Set && right instanceof Set) || left.size !== right.size) {
5643
+ return false;
4826
5644
  }
4827
- if (left instanceof Set || right instanceof Set) {
4828
- if (!(left instanceof Set && right instanceof Set) || left.size !== right.size) {
5645
+ const rightValues = [...right];
5646
+ const matched = /* @__PURE__ */ new Set();
5647
+ for (const leftValue of left) {
5648
+ if (!hasUnmatchedEquivalent(leftValue, rightValues, matched, stableValueEquals)) {
4829
5649
  return false;
4830
5650
  }
4831
- const rightValues = [...right];
4832
- const matched = /* @__PURE__ */ new Set();
4833
- for (const leftValue of left) {
4834
- let found = false;
4835
- for (let index = 0; index < rightValues.length; index += 1) {
4836
- if (matched.has(index)) {
4837
- continue;
4838
- }
4839
- if (stableValueEquals(leftValue, rightValues[index])) {
4840
- matched.add(index);
4841
- found = true;
4842
- break;
4843
- }
4844
- }
4845
- if (!found) {
4846
- return false;
4847
- }
4848
- }
4849
- return true;
4850
5651
  }
4851
- if (left instanceof Map || right instanceof Map) {
4852
- if (!(left instanceof Map && right instanceof Map) || left.size !== right.size) {
4853
- return false;
4854
- }
4855
- const rightEntries = [...right.entries()];
4856
- const matched = /* @__PURE__ */ new Set();
4857
- for (const [leftKey, leftValue] of left.entries()) {
4858
- let found = false;
4859
- for (let index = 0; index < rightEntries.length; index += 1) {
4860
- if (matched.has(index)) {
4861
- continue;
4862
- }
4863
- const [rightKey, rightValue] = rightEntries[index];
4864
- if (stableValueEquals(leftKey, rightKey) && stableValueEquals(leftValue, rightValue)) {
4865
- matched.add(index);
4866
- found = true;
4867
- break;
4868
- }
4869
- }
4870
- if (!found) {
4871
- return false;
4872
- }
4873
- }
4874
- return true;
5652
+ return true;
5653
+ }
5654
+ function compareMapValues(left, right) {
5655
+ if (!(left instanceof Map || right instanceof Map)) {
5656
+ return void 0;
5657
+ }
5658
+ if (!(left instanceof Map && right instanceof Map) || left.size !== right.size) {
5659
+ return false;
4875
5660
  }
4876
- if (Array.isArray(left) || Array.isArray(right)) {
4877
- if (!Array.isArray(left) || !Array.isArray(right) || left.length !== right.length) {
5661
+ const rightEntries = [...right.entries()];
5662
+ const matched = /* @__PURE__ */ new Set();
5663
+ for (const [leftKey, leftValue] of left.entries()) {
5664
+ const leftEntry = [leftKey, leftValue];
5665
+ if (!hasUnmatchedEquivalent(leftEntry, rightEntries, matched, ([candidateKey, candidateValue], [rightKey, rightValue]) => stableValueEquals(candidateKey, rightKey) && stableValueEquals(candidateValue, rightValue))) {
4878
5666
  return false;
4879
5667
  }
4880
- return left.every((value, index) => stableValueEquals(value, right[index]));
4881
5668
  }
5669
+ return true;
5670
+ }
5671
+ function compareArrayValues(left, right) {
5672
+ if (!(Array.isArray(left) || Array.isArray(right))) {
5673
+ return void 0;
5674
+ }
5675
+ if (!Array.isArray(left) || !Array.isArray(right) || left.length !== right.length) {
5676
+ return false;
5677
+ }
5678
+ return left.every((value, index) => stableValueEquals(value, right[index]));
5679
+ }
5680
+ function comparePlainObjectValues(left, right) {
4882
5681
  const leftKeys = Object.keys(left).sort((a, b) => a.localeCompare(b));
4883
5682
  const rightKeys = Object.keys(right).sort((a, b) => a.localeCompare(b));
4884
5683
  if (leftKeys.length !== rightKeys.length) {
@@ -4895,6 +5694,28 @@ function stableValueEquals(left, right) {
4895
5694
  }
4896
5695
  return true;
4897
5696
  }
5697
+ var SPECIALIZED_STABLE_VALUE_COMPARISONS = [
5698
+ compareRegExpValues,
5699
+ compareDateValues,
5700
+ compareSetValues,
5701
+ compareMapValues,
5702
+ compareArrayValues
5703
+ ];
5704
+ function stableValueEquals(left, right) {
5705
+ if (Object.is(left, right)) {
5706
+ return true;
5707
+ }
5708
+ if (left === null || right === null || typeof left !== "object" || typeof right !== "object") {
5709
+ return false;
5710
+ }
5711
+ for (const compare of SPECIALIZED_STABLE_VALUE_COMPARISONS) {
5712
+ const result = compare(left, right);
5713
+ if (result !== void 0) {
5714
+ return result;
5715
+ }
5716
+ }
5717
+ return comparePlainObjectValues(left, right);
5718
+ }
4898
5719
  function sha256Hex(value) {
4899
5720
  return crypto2.createHash("sha256").update(value, "utf8").digest("hex");
4900
5721
  }
@@ -5247,87 +6068,6 @@ function validateSettings(raw) {
5247
6068
  return { success: true, data: result.value };
5248
6069
  }
5249
6070
 
5250
- // dist/core/item/item-type-definition.js
5251
- function normalizeItemTypeStringList(values) {
5252
- return [...new Set((values ?? []).map((value) => value.trim()).filter((value) => value.length > 0))].sort((left, right) => left.localeCompare(right));
5253
- }
5254
- function normalizeItemTypeOption(option) {
5255
- const key = option.key.trim();
5256
- if (key.length === 0) {
5257
- return null;
5258
- }
5259
- const aliases = normalizeItemTypeStringList(option.aliases);
5260
- const description = option.description?.trim();
5261
- return {
5262
- key,
5263
- values: normalizeItemTypeStringList(option.values),
5264
- required: option.required === true ? true : void 0,
5265
- aliases: aliases.length > 0 ? aliases : void 0,
5266
- description: description && description.length > 0 ? description : void 0
5267
- };
5268
- }
5269
- var keepPolicyCommand = (command) => command;
5270
- var strictPolicyCommand = (command) => {
5271
- const normalized = command.trim().toLowerCase();
5272
- return normalized === "create" || normalized === "update" ? normalized : null;
5273
- };
5274
- function normalizeItemTypeCommandOptionPolicy(policy, resolvePolicyCommand) {
5275
- const command = resolvePolicyCommand(policy.command);
5276
- if (command === null) {
5277
- return null;
5278
- }
5279
- const option = policy.option.trim();
5280
- if (option.length === 0) {
5281
- return null;
5282
- }
5283
- return {
5284
- command,
5285
- option,
5286
- required: policy.required,
5287
- visible: policy.visible,
5288
- enabled: policy.enabled
5289
- };
5290
- }
5291
- function normalizeItemTypeCommandOptionPolicies(policies, resolvePolicyCommand) {
5292
- const dedupedByKey = /* @__PURE__ */ new Map();
5293
- for (const policy of policies ?? []) {
5294
- const normalized = normalizeItemTypeCommandOptionPolicy(policy, resolvePolicyCommand);
5295
- if (!normalized) {
5296
- continue;
5297
- }
5298
- dedupedByKey.set(`${normalized.command}:${normalized.option.toLowerCase()}`, normalized);
5299
- }
5300
- return [...dedupedByKey.values()].sort((left, right) => left.command === right.command ? left.option.localeCompare(right.option) : left.command.localeCompare(right.command));
5301
- }
5302
- function normalizeItemTypeDefinition(definition, options = {}) {
5303
- const resolvePolicyCommand = options.resolvePolicyCommand ?? keepPolicyCommand;
5304
- const name = definition.name.trim();
5305
- if (name.length === 0) {
5306
- return null;
5307
- }
5308
- const hasRequiredCreateFields = definition.required_create_fields !== void 0;
5309
- const hasRequiredCreateRepeatables = definition.required_create_repeatables !== void 0;
5310
- const hasOptions = definition.options !== void 0;
5311
- const hasCommandOptionPolicies = definition.command_option_policies !== void 0;
5312
- const folder = definition.folder?.trim();
5313
- const description = definition.description?.trim();
5314
- const defaultStatus = definition.default_status?.trim();
5315
- const aliases = normalizeItemTypeStringList(definition.aliases);
5316
- const normalizedOptions = (definition.options ?? []).map((option) => normalizeItemTypeOption(option)).filter((option) => option !== null).sort((left, right) => left.key.localeCompare(right.key));
5317
- const commandOptionPolicies = normalizeItemTypeCommandOptionPolicies(definition.command_option_policies, resolvePolicyCommand);
5318
- return {
5319
- name,
5320
- description: description && description.length > 0 ? description : void 0,
5321
- default_status: defaultStatus && defaultStatus.length > 0 ? defaultStatus : void 0,
5322
- folder: folder && folder.length > 0 ? folder : void 0,
5323
- aliases: aliases.length > 0 ? aliases : void 0,
5324
- required_create_fields: hasRequiredCreateFields ? normalizeItemTypeStringList(definition.required_create_fields) : void 0,
5325
- required_create_repeatables: hasRequiredCreateRepeatables ? normalizeItemTypeStringList(definition.required_create_repeatables) : void 0,
5326
- options: hasOptions ? normalizedOptions : void 0,
5327
- command_option_policies: hasCommandOptionPolicies ? commandOptionPolicies : void 0
5328
- };
5329
- }
5330
-
5331
6071
  // dist/core/validate/estimate-defaults.js
5332
6072
  var DEFAULT_ESTIMATE_MINUTES_BY_TYPE = {
5333
6073
  Epic: 2880,
@@ -5930,19 +6670,19 @@ function mergeSettings(settings) {
5930
6670
  ...settings,
5931
6671
  item_format: settings.item_format === "json_markdown" ? "toon" : settings.item_format ?? defaults.item_format,
5932
6672
  locks: { ...defaults.locks, ...settings.locks },
5933
- checkpoints: { ...defaults.checkpoints, ...settings.checkpoints ?? {} },
6673
+ checkpoints: { ...defaults.checkpoints, ...settings.checkpoints },
5934
6674
  output: { ...defaults.output, ...settings.output },
5935
6675
  history: {
5936
6676
  ...defaults.history,
5937
- ...settings.history ?? {},
6677
+ ...settings.history,
5938
6678
  compact_policy: {
5939
6679
  ...defaults.history.compact_policy,
5940
- ...settings.history?.compact_policy ?? {}
6680
+ ...settings.history?.compact_policy
5941
6681
  }
5942
6682
  },
5943
6683
  validation: {
5944
6684
  ...defaults.validation,
5945
- ...settings.validation ?? {},
6685
+ ...settings.validation,
5946
6686
  parent_reference: governance.parent_reference,
5947
6687
  metadata_profile: governance.metadata_profile,
5948
6688
  metadata_required_fields: normalizeValidationMetadataRequiredFields(settings.validation?.metadata_required_fields),
@@ -5978,7 +6718,7 @@ function mergeSettings(settings) {
5978
6718
  stale_threshold_days: settings.context?.stale_threshold_days ?? defaults.context.stale_threshold_days,
5979
6719
  sections: {
5980
6720
  ...defaults.context.sections,
5981
- ...settings.context?.sections ?? {}
6721
+ ...settings.context?.sections
5982
6722
  }
5983
6723
  },
5984
6724
  extensions: {
@@ -5992,13 +6732,13 @@ function mergeSettings(settings) {
5992
6732
  mutation_refresh_policy: normalizeSearchMutationRefreshPolicy(settings.search?.mutation_refresh_policy),
5993
6733
  query_expansion: {
5994
6734
  ...defaults.search.query_expansion,
5995
- ...settings.search?.query_expansion ?? {},
6735
+ ...settings.search?.query_expansion,
5996
6736
  enabled: normalizeSearchQueryExpansionEnabled(settings.search?.query_expansion?.enabled),
5997
6737
  provider: normalizeSearchQueryExpansionProvider(settings.search?.query_expansion?.provider)
5998
6738
  },
5999
6739
  rerank: {
6000
6740
  ...defaults.search.rerank,
6001
- ...settings.search?.rerank ?? {},
6741
+ ...settings.search?.rerank,
6002
6742
  enabled: normalizeSearchRerankEnabled(settings.search?.rerank?.enabled),
6003
6743
  model: normalizeSearchRerankModel(settings.search?.rerank?.model),
6004
6744
  top_k: normalizeSearchRerankTopK(settings.search?.rerank?.top_k)
@@ -6070,13 +6810,13 @@ function serializeSettings(settings, options = {}) {
6070
6810
  mutation_refresh_policy: normalizeSearchMutationRefreshPolicy(baseSettings.search?.mutation_refresh_policy),
6071
6811
  query_expansion: {
6072
6812
  ...SETTINGS_DEFAULTS.search.query_expansion,
6073
- ...baseSettings.search?.query_expansion ?? {},
6813
+ ...baseSettings.search?.query_expansion,
6074
6814
  enabled: normalizeSearchQueryExpansionEnabled(baseSettings.search?.query_expansion?.enabled),
6075
6815
  provider: normalizeSearchQueryExpansionProvider(baseSettings.search?.query_expansion?.provider)
6076
6816
  },
6077
6817
  rerank: {
6078
6818
  ...SETTINGS_DEFAULTS.search.rerank,
6079
- ...baseSettings.search?.rerank ?? {},
6819
+ ...baseSettings.search?.rerank,
6080
6820
  enabled: normalizeSearchRerankEnabled(baseSettings.search?.rerank?.enabled),
6081
6821
  model: normalizeSearchRerankModel(baseSettings.search?.rerank?.model),
6082
6822
  top_k: normalizeSearchRerankTopK(baseSettings.search?.rerank?.top_k)
@@ -6088,7 +6828,7 @@ function serializeSettings(settings, options = {}) {
6088
6828
  stale_threshold_days: baseSettings.context?.stale_threshold_days ?? SETTINGS_DEFAULTS.context.stale_threshold_days,
6089
6829
  sections: {
6090
6830
  ...SETTINGS_DEFAULTS.context.sections,
6091
- ...baseSettings.context?.sections ?? {}
6831
+ ...baseSettings.context?.sections
6092
6832
  }
6093
6833
  },
6094
6834
  extensions: {
@@ -6100,8 +6840,8 @@ function serializeSettings(settings, options = {}) {
6100
6840
  ...baseSettings.vector_store,
6101
6841
  adapter: baseSettings.vector_store?.adapter ?? SETTINGS_DEFAULTS.vector_store.adapter,
6102
6842
  collection_name: normalizeVectorStoreCollectionName(baseSettings.vector_store?.collection_name),
6103
- qdrant: { ...baseSettings.vector_store?.qdrant ?? {} },
6104
- lancedb: { ...baseSettings.vector_store?.lancedb ?? {} }
6843
+ qdrant: { ...baseSettings.vector_store?.qdrant },
6844
+ lancedb: { ...baseSettings.vector_store?.lancedb }
6105
6845
  }
6106
6846
  };
6107
6847
  const ordered = orderObject({
@@ -6402,6 +7142,33 @@ export {
6402
7142
  EMPTY_CANONICAL_DOCUMENT,
6403
7143
  EXIT_CODE,
6404
7144
  resolveTelemetryErrorCategory,
7145
+ BUILTIN_ITEM_TYPE_VALUES,
7146
+ STATUS_VALUES,
7147
+ RUNTIME_STATUS_ROLE_VALUES,
7148
+ RUNTIME_FIELD_TYPE_VALUES,
7149
+ RUNTIME_FIELD_COMMAND_VALUES,
7150
+ DEPENDENCY_KIND_VALUES,
7151
+ SCOPE_VALUES,
7152
+ RISK_VALUES,
7153
+ ISSUE_SEVERITY_VALUES,
7154
+ CONFIDENCE_TEXT_VALUES,
7155
+ RECURRENCE_FREQUENCY_VALUES,
7156
+ RECURRENCE_WEEKDAY_VALUES,
7157
+ weekdayOrderIndex,
7158
+ PLAN_MODE_VALUES,
7159
+ PLAN_STEP_STATUS_VALUES,
7160
+ PLAN_HARNESS_VALUES,
7161
+ PLAN_STEP_LINK_KIND_VALUES,
7162
+ CONTEXT_DEPTH_VALUES,
7163
+ CONTEXT_SECTION_VALUES,
7164
+ canonicalizeCommandOptionKey,
7165
+ commandOptionFlagLabel,
7166
+ toDefaultFolder,
7167
+ resolveItemTypeRegistry,
7168
+ resolveTypeName,
7169
+ resolveTypeDefinition,
7170
+ resolveCommandOptionPolicyState,
7171
+ validateTypeOptions,
6405
7172
  ITEM_FILE_EXTENSIONS,
6406
7173
  resolvePmRoot,
6407
7174
  resolveGlobalPmRoot,
@@ -6471,29 +7238,6 @@ export {
6471
7238
  runActiveRendererOverride,
6472
7239
  runActiveServiceOverride,
6473
7240
  runActiveServiceOverrideSync,
6474
- BUILTIN_ITEM_TYPE_VALUES,
6475
- ITEM_TYPE_VALUES,
6476
- STATUS_VALUES,
6477
- RUNTIME_STATUS_ROLE_VALUES,
6478
- RUNTIME_FIELD_TYPE_VALUES,
6479
- RUNTIME_FIELD_COMMAND_VALUES,
6480
- DEPENDENCY_KIND_VALUES,
6481
- SCOPE_VALUES,
6482
- RISK_VALUES,
6483
- ISSUE_SEVERITY_VALUES,
6484
- CONFIDENCE_TEXT_VALUES,
6485
- RECURRENCE_FREQUENCY_VALUES,
6486
- RECURRENCE_WEEKDAY_VALUES,
6487
- weekdayOrderIndex,
6488
- PLAN_MODE_VALUES,
6489
- PLAN_STEP_STATUS_VALUES,
6490
- PLAN_HARNESS_VALUES,
6491
- PLAN_STEP_LINK_KIND_VALUES,
6492
- CONTEXT_DEPTH_VALUES,
6493
- CONTEXT_SECTION_VALUES,
6494
- normalizeItemTypeStringList,
6495
- strictPolicyCommand,
6496
- normalizeItemTypeDefinition,
6497
7241
  DEFAULT_RUNTIME_SCHEMA_FILE_PATHS,
6498
7242
  DEFAULT_RUNTIME_STATUS_DEFINITIONS,
6499
7243
  normalizeRuntimeSchemaSettings,
@@ -6516,6 +7260,6 @@ export {
6516
7260
  readSettings,
6517
7261
  writeSettings
6518
7262
  };
6519
- //# sourceMappingURL=chunk-UELRKQQU.js.map
7263
+ //# sourceMappingURL=chunk-CY5IJMUM.js.map
6520
7264
 
6521
- //# debugId=94fb806d-f79e-5000-8d03-0667229930c5
7265
+ //# debugId=b452df4b-661b-5f08-9d20-dff37c4bfb2f