@unbrained/pm-cli 2026.6.13 → 2026.6.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (808) hide show
  1. package/CHANGELOG.md +102 -0
  2. package/README.md +1 -1
  3. package/dist/cli/bootstrap-args.d.ts +29 -0
  4. package/dist/cli/bootstrap-args.js +11 -4
  5. package/dist/cli/bootstrap-args.js.map +1 -1
  6. package/dist/cli/commander-usage.d.ts +12 -0
  7. package/dist/cli/commander-usage.js +18 -7
  8. package/dist/cli/commander-usage.js.map +1 -1
  9. package/dist/cli/commands/activity.d.ts +19 -0
  10. package/dist/cli/commands/activity.js +12 -2
  11. package/dist/cli/commands/activity.js.map +1 -1
  12. package/dist/cli/commands/aggregate.d.ts +58 -0
  13. package/dist/cli/commands/aggregate.js +48 -15
  14. package/dist/cli/commands/aggregate.js.map +1 -1
  15. package/dist/cli/commands/annotation-command.d.ts +6 -1
  16. package/dist/cli/commands/annotation-command.js +72 -2
  17. package/dist/cli/commands/annotation-command.js.map +1 -1
  18. package/dist/cli/commands/append.js +4 -3
  19. package/dist/cli/commands/append.js.map +1 -1
  20. package/dist/cli/commands/close-many.d.ts +20 -0
  21. package/dist/cli/commands/close-many.js +14 -23
  22. package/dist/cli/commands/close-many.js.map +1 -1
  23. package/dist/cli/commands/close.js +37 -4
  24. package/dist/cli/commands/close.js.map +1 -1
  25. package/dist/cli/commands/comments-audit.js +3 -2
  26. package/dist/cli/commands/comments-audit.js.map +1 -1
  27. package/dist/cli/commands/comments.d.ts +2 -0
  28. package/dist/cli/commands/comments.js +49 -23
  29. package/dist/cli/commands/comments.js.map +1 -1
  30. package/dist/cli/commands/completion.js +362 -15
  31. package/dist/cli/commands/completion.js.map +1 -1
  32. package/dist/cli/commands/config.d.ts +51 -1
  33. package/dist/cli/commands/config.js +50 -12
  34. package/dist/cli/commands/config.js.map +1 -1
  35. package/dist/cli/commands/context.d.ts +79 -1
  36. package/dist/cli/commands/context.js +151 -25
  37. package/dist/cli/commands/context.js.map +1 -1
  38. package/dist/cli/commands/contracts.d.ts +80 -1
  39. package/dist/cli/commands/contracts.js +54 -4
  40. package/dist/cli/commands/contracts.js.map +1 -1
  41. package/dist/cli/commands/create.d.ts +51 -0
  42. package/dist/cli/commands/create.js +137 -18
  43. package/dist/cli/commands/create.js.map +1 -1
  44. package/dist/cli/commands/dedupe-audit.d.ts +33 -0
  45. package/dist/cli/commands/dedupe-audit.js +18 -14
  46. package/dist/cli/commands/dedupe-audit.js.map +1 -1
  47. package/dist/cli/commands/deps.js +7 -4
  48. package/dist/cli/commands/deps.js.map +1 -1
  49. package/dist/cli/commands/event-validation-messages.js +3 -3
  50. package/dist/cli/commands/event-validation-messages.js.map +1 -1
  51. package/dist/cli/commands/extension/bundled-catalog.d.ts +7 -0
  52. package/dist/cli/commands/extension/bundled-catalog.js +19 -15
  53. package/dist/cli/commands/extension/bundled-catalog.js.map +1 -1
  54. package/dist/cli/commands/extension/install-sources.d.ts +41 -1
  55. package/dist/cli/commands/extension/install-sources.js +26 -8
  56. package/dist/cli/commands/extension/install-sources.js.map +1 -1
  57. package/dist/cli/commands/extension/shared.d.ts +5 -0
  58. package/dist/cli/commands/extension/shared.js +9 -3
  59. package/dist/cli/commands/extension/shared.js.map +1 -1
  60. package/dist/cli/commands/extension.d.ts +133 -1
  61. package/dist/cli/commands/extension.js +127 -9
  62. package/dist/cli/commands/extension.js.map +1 -1
  63. package/dist/cli/commands/files.d.ts +30 -1
  64. package/dist/cli/commands/files.js +21 -2
  65. package/dist/cli/commands/files.js.map +1 -1
  66. package/dist/cli/commands/focus.d.ts +11 -0
  67. package/dist/cli/commands/focus.js +86 -0
  68. package/dist/cli/commands/focus.js.map +1 -0
  69. package/dist/cli/commands/get.d.ts +9 -2
  70. package/dist/cli/commands/get.js +34 -6
  71. package/dist/cli/commands/get.js.map +1 -1
  72. package/dist/cli/commands/guide.d.ts +5 -0
  73. package/dist/cli/commands/guide.js +6 -3
  74. package/dist/cli/commands/guide.js.map +1 -1
  75. package/dist/cli/commands/health.d.ts +109 -0
  76. package/dist/cli/commands/health.js +87 -35
  77. package/dist/cli/commands/health.js.map +1 -1
  78. package/dist/cli/commands/history-compact.js +27 -36
  79. package/dist/cli/commands/history-compact.js.map +1 -1
  80. package/dist/cli/commands/history-redact.d.ts +46 -0
  81. package/dist/cli/commands/history-redact.js +99 -67
  82. package/dist/cli/commands/history-redact.js.map +1 -1
  83. package/dist/cli/commands/history-repair.js +34 -37
  84. package/dist/cli/commands/history-repair.js.map +1 -1
  85. package/dist/cli/commands/history.js +6 -2
  86. package/dist/cli/commands/history.js.map +1 -1
  87. package/dist/cli/commands/index.d.ts +4 -1
  88. package/dist/cli/commands/index.js +6 -3
  89. package/dist/cli/commands/index.js.map +1 -1
  90. package/dist/cli/commands/init-agent-guidance.d.ts +54 -0
  91. package/dist/cli/commands/init-agent-guidance.js +31 -4
  92. package/dist/cli/commands/init-agent-guidance.js.map +1 -1
  93. package/dist/cli/commands/init.d.ts +38 -2
  94. package/dist/cli/commands/init.js +50 -64
  95. package/dist/cli/commands/init.js.map +1 -1
  96. package/dist/cli/commands/learnings.js +4 -3
  97. package/dist/cli/commands/learnings.js.map +1 -1
  98. package/dist/cli/commands/lifecycle-transitions.d.ts +23 -0
  99. package/dist/cli/commands/lifecycle-transitions.js +41 -0
  100. package/dist/cli/commands/lifecycle-transitions.js.map +1 -0
  101. package/dist/cli/commands/linked-artifacts.d.ts +5 -0
  102. package/dist/cli/commands/linked-artifacts.js +18 -4
  103. package/dist/cli/commands/linked-artifacts.js.map +1 -1
  104. package/dist/cli/commands/linked-test-parsers.d.ts +5 -0
  105. package/dist/cli/commands/linked-test-parsers.js +5 -2
  106. package/dist/cli/commands/linked-test-parsers.js.map +1 -1
  107. package/dist/cli/commands/list-filter-shared.d.ts +8 -0
  108. package/dist/cli/commands/list-filter-shared.js +70 -0
  109. package/dist/cli/commands/list-filter-shared.js.map +1 -0
  110. package/dist/cli/commands/list.d.ts +116 -0
  111. package/dist/cli/commands/list.js +194 -6
  112. package/dist/cli/commands/list.js.map +1 -1
  113. package/dist/cli/commands/normalize.js +16 -2
  114. package/dist/cli/commands/normalize.js.map +1 -1
  115. package/dist/cli/commands/notes.js +4 -3
  116. package/dist/cli/commands/notes.js.map +1 -1
  117. package/dist/cli/commands/plan.js +3 -2
  118. package/dist/cli/commands/plan.js.map +1 -1
  119. package/dist/cli/commands/recurrence-parsers.d.ts +9 -0
  120. package/dist/cli/commands/recurrence-parsers.js +19 -2
  121. package/dist/cli/commands/recurrence-parsers.js.map +1 -1
  122. package/dist/cli/commands/reindex.d.ts +83 -0
  123. package/dist/cli/commands/reindex.js +45 -10
  124. package/dist/cli/commands/reindex.js.map +1 -1
  125. package/dist/cli/commands/repeatable-metadata-parsers.js +28 -4
  126. package/dist/cli/commands/repeatable-metadata-parsers.js.map +1 -1
  127. package/dist/cli/commands/restore.d.ts +40 -1
  128. package/dist/cli/commands/restore.js +27 -2
  129. package/dist/cli/commands/restore.js.map +1 -1
  130. package/dist/cli/commands/scheduling-shortcuts.d.ts +43 -0
  131. package/dist/cli/commands/scheduling-shortcuts.js +87 -0
  132. package/dist/cli/commands/scheduling-shortcuts.js.map +1 -0
  133. package/dist/cli/commands/schema.d.ts +152 -2
  134. package/dist/cli/commands/schema.js +510 -4
  135. package/dist/cli/commands/schema.js.map +1 -1
  136. package/dist/cli/commands/search.d.ts +289 -1
  137. package/dist/cli/commands/search.js +367 -60
  138. package/dist/cli/commands/search.js.map +1 -1
  139. package/dist/cli/commands/stats.d.ts +38 -0
  140. package/dist/cli/commands/stats.js +38 -10
  141. package/dist/cli/commands/stats.js.map +1 -1
  142. package/dist/cli/commands/telemetry.js +5 -3
  143. package/dist/cli/commands/telemetry.js.map +1 -1
  144. package/dist/cli/commands/templates.d.ts +18 -0
  145. package/dist/cli/commands/templates.js +9 -2
  146. package/dist/cli/commands/templates.js.map +1 -1
  147. package/dist/cli/commands/test-all.d.ts +5 -0
  148. package/dist/cli/commands/test-all.js +9 -3
  149. package/dist/cli/commands/test-all.js.map +1 -1
  150. package/dist/cli/commands/test.d.ts +70 -1
  151. package/dist/cli/commands/test.js +84 -3
  152. package/dist/cli/commands/test.js.map +1 -1
  153. package/dist/cli/commands/update-many.d.ts +34 -1
  154. package/dist/cli/commands/update-many.js +60 -31
  155. package/dist/cli/commands/update-many.js.map +1 -1
  156. package/dist/cli/commands/update.d.ts +71 -0
  157. package/dist/cli/commands/update.js +91 -11
  158. package/dist/cli/commands/update.js.map +1 -1
  159. package/dist/cli/commands/upgrade.d.ts +28 -1
  160. package/dist/cli/commands/upgrade.js +17 -4
  161. package/dist/cli/commands/upgrade.js.map +1 -1
  162. package/dist/cli/commands/validate.d.ts +114 -0
  163. package/dist/cli/commands/validate.js +153 -8
  164. package/dist/cli/commands/validate.js.map +1 -1
  165. package/dist/cli/error-guidance.d.ts +30 -0
  166. package/dist/cli/error-guidance.js +41 -6
  167. package/dist/cli/error-guidance.js.map +1 -1
  168. package/dist/cli/extension-command-options.js +9 -7
  169. package/dist/cli/extension-command-options.js.map +1 -1
  170. package/dist/cli/help-content.d.ts +8 -0
  171. package/dist/cli/help-content.js +54 -6
  172. package/dist/cli/help-content.js.map +1 -1
  173. package/dist/cli/help-json-payload.d.ts +19 -1
  174. package/dist/cli/help-json-payload.js +16 -7
  175. package/dist/cli/help-json-payload.js.map +1 -1
  176. package/dist/cli/main.d.ts +242 -0
  177. package/dist/cli/main.js +241 -45
  178. package/dist/cli/main.js.map +1 -1
  179. package/dist/cli/register-list-query.js +62 -5
  180. package/dist/cli/register-list-query.js.map +1 -1
  181. package/dist/cli/register-mutation.d.ts +16 -0
  182. package/dist/cli/register-mutation.js +376 -100
  183. package/dist/cli/register-mutation.js.map +1 -1
  184. package/dist/cli/register-operations.d.ts +8 -0
  185. package/dist/cli/register-operations.js +134 -11
  186. package/dist/cli/register-operations.js.map +1 -1
  187. package/dist/cli/register-setup.js +9 -6
  188. package/dist/cli/register-setup.js.map +1 -1
  189. package/dist/cli/registration-helpers.d.ts +4 -0
  190. package/dist/cli/registration-helpers.js +124 -38
  191. package/dist/cli/registration-helpers.js.map +1 -1
  192. package/dist/cli-bundle/chunks/activity-PZYSZA26.js +18 -0
  193. package/dist/cli-bundle/chunks/{activity-PPO7QWJF.js → activity-SFM4THAU.js} +13 -11
  194. package/dist/cli-bundle/chunks/{aggregate-IRHJWEKG.js → aggregate-Y5ADDKBM.js} +55 -26
  195. package/dist/cli-bundle/chunks/aggregate-Y5ADDKBM.js.map +1 -0
  196. package/dist/cli-bundle/chunks/{aggregate-XEBW22UQ.js → aggregate-YTAUQLRW.js} +54 -25
  197. package/dist/cli-bundle/chunks/aggregate-YTAUQLRW.js.map +7 -0
  198. package/dist/cli-bundle/chunks/{append-NL67JNJU.js → append-4M7OVV7M.js} +11 -11
  199. package/dist/cli-bundle/chunks/append-4M7OVV7M.js.map +1 -0
  200. package/dist/cli-bundle/chunks/{append-N2AWXKZC.js → append-HSPK4L4V.js} +10 -10
  201. package/dist/cli-bundle/chunks/{append-N2AWXKZC.js.map → append-HSPK4L4V.js.map} +2 -2
  202. package/dist/cli-bundle/chunks/{chunk-IIOIBAQW.js → chunk-26BM6YLO.js} +3 -3
  203. package/dist/cli-bundle/chunks/{chunk-CEGUH2E5.js → chunk-2C6FU3D3.js} +5 -5
  204. package/dist/cli-bundle/chunks/{chunk-CEGUH2E5.js.map → chunk-2C6FU3D3.js.map} +1 -1
  205. package/dist/cli-bundle/chunks/{chunk-SQDKAEKG.js → chunk-2OPYLXDO.js} +117 -37
  206. package/dist/cli-bundle/chunks/chunk-2OPYLXDO.js.map +7 -0
  207. package/dist/cli-bundle/chunks/{chunk-4ZKKZMLH.js → chunk-2S46FKLB.js} +104 -30
  208. package/dist/cli-bundle/chunks/chunk-2S46FKLB.js.map +1 -0
  209. package/dist/cli-bundle/chunks/{chunk-LSSTKL3Y.js → chunk-2TMKMTEI.js} +3 -3
  210. package/dist/cli-bundle/chunks/{chunk-QU3OPNVV.js → chunk-2VH7DFSJ.js} +2 -2
  211. package/dist/cli-bundle/chunks/{chunk-RHYBR6G7.js → chunk-3ENF4NO4.js} +74 -14
  212. package/dist/cli-bundle/chunks/chunk-3ENF4NO4.js.map +1 -0
  213. package/dist/cli-bundle/chunks/chunk-3GR2HTYY.js +404 -0
  214. package/dist/cli-bundle/chunks/chunk-3GR2HTYY.js.map +7 -0
  215. package/dist/cli-bundle/chunks/{chunk-AAUYXSFF.js → chunk-3R3FYCBV.js} +223 -50
  216. package/dist/cli-bundle/chunks/chunk-3R3FYCBV.js.map +7 -0
  217. package/dist/cli-bundle/chunks/{chunk-5HSAHRYA.js → chunk-3UKJX3RP.js} +82 -21
  218. package/dist/cli-bundle/chunks/chunk-3UKJX3RP.js.map +7 -0
  219. package/dist/cli-bundle/chunks/chunk-4RTLBTYS.js +83 -0
  220. package/dist/cli-bundle/chunks/chunk-4RTLBTYS.js.map +1 -0
  221. package/dist/cli-bundle/chunks/{chunk-UCVJP4JL.js → chunk-5FDYWOJT.js} +52 -8
  222. package/dist/cli-bundle/chunks/chunk-5FDYWOJT.js.map +7 -0
  223. package/dist/cli-bundle/chunks/{chunk-LGOXXQUW.js → chunk-5XGWFUW2.js} +2 -2
  224. package/dist/cli-bundle/chunks/{chunk-LYNQ3NGI.js → chunk-6BD77FGL.js} +309 -20
  225. package/dist/cli-bundle/chunks/chunk-6BD77FGL.js.map +1 -0
  226. package/dist/cli-bundle/chunks/chunk-6EFCFPNE.js +35 -0
  227. package/dist/cli-bundle/chunks/chunk-6EFCFPNE.js.map +7 -0
  228. package/dist/cli-bundle/chunks/{chunk-36BCSMKP.js → chunk-6HF6CIY2.js} +26 -11
  229. package/dist/cli-bundle/chunks/chunk-6HF6CIY2.js.map +7 -0
  230. package/dist/cli-bundle/chunks/{chunk-M3SI2REU.js → chunk-6PBPD4MN.js} +322 -19
  231. package/dist/cli-bundle/chunks/chunk-6PBPD4MN.js.map +7 -0
  232. package/dist/cli-bundle/chunks/{chunk-TSXWFN3L.js → chunk-6VFUEGOA.js} +53 -9
  233. package/dist/cli-bundle/chunks/chunk-6VFUEGOA.js.map +1 -0
  234. package/dist/cli-bundle/chunks/{chunk-2J2AH4V5.js → chunk-AAOXSPAE.js} +56 -72
  235. package/dist/cli-bundle/chunks/chunk-AAOXSPAE.js.map +1 -0
  236. package/dist/cli-bundle/chunks/{chunk-Z647PYLD.js → chunk-AJCQ5GT6.js} +4 -4
  237. package/dist/cli-bundle/chunks/chunk-ALTGYHN3.js +61 -0
  238. package/dist/cli-bundle/chunks/chunk-ALTGYHN3.js.map +7 -0
  239. package/dist/cli-bundle/chunks/{chunk-KHGTYCJ6.js → chunk-AOJQL33L.js} +83 -22
  240. package/dist/cli-bundle/chunks/chunk-AOJQL33L.js.map +1 -0
  241. package/dist/cli-bundle/chunks/{chunk-5LMF75Q7.js → chunk-AXLDUGXA.js} +7 -4
  242. package/dist/cli-bundle/chunks/{chunk-5LMF75Q7.js.map → chunk-AXLDUGXA.js.map} +2 -2
  243. package/dist/cli-bundle/chunks/{chunk-DWG4FHPY.js → chunk-BITCVGHT.js} +2 -2
  244. package/dist/cli-bundle/chunks/{chunk-JE5IZXDS.js → chunk-CGQTFWYI.js} +4 -4
  245. package/dist/cli-bundle/chunks/{chunk-LFW5NQUP.js → chunk-CHM2VFVL.js} +407 -290
  246. package/dist/cli-bundle/chunks/chunk-CHM2VFVL.js.map +7 -0
  247. package/dist/cli-bundle/chunks/{chunk-VYZNX4C5.js → chunk-COVLE33A.js} +3 -3
  248. package/dist/cli-bundle/chunks/{chunk-SGMGMCIF.js → chunk-DDNBWH4W.js} +157 -25
  249. package/dist/cli-bundle/chunks/chunk-DDNBWH4W.js.map +1 -0
  250. package/dist/cli-bundle/chunks/{chunk-6ZFTM65G.js → chunk-F5MSD5HE.js} +2 -2
  251. package/dist/cli-bundle/chunks/{chunk-6TBR5AZ2.js → chunk-FAXB6F6R.js} +76 -8
  252. package/dist/cli-bundle/chunks/chunk-FAXB6F6R.js.map +7 -0
  253. package/dist/cli-bundle/chunks/{chunk-L6YQONLM.js → chunk-FPDK5BZQ.js} +18 -19
  254. package/dist/cli-bundle/chunks/chunk-FPDK5BZQ.js.map +1 -0
  255. package/dist/cli-bundle/chunks/{chunk-AGG32LKL.js → chunk-FPY2TOFI.js} +480 -24
  256. package/dist/cli-bundle/chunks/chunk-FPY2TOFI.js.map +1 -0
  257. package/dist/cli-bundle/chunks/{chunk-JWXTOYBI.js → chunk-G2MOUCTU.js} +121 -44
  258. package/dist/cli-bundle/chunks/chunk-G2MOUCTU.js.map +7 -0
  259. package/dist/cli-bundle/chunks/{chunk-3VULHQNS.js → chunk-G57RHEGP.js} +36 -18
  260. package/dist/cli-bundle/chunks/chunk-G57RHEGP.js.map +1 -0
  261. package/dist/cli-bundle/chunks/{chunk-QQG4HEX7.js → chunk-IROHIK2T.js} +37 -63
  262. package/dist/cli-bundle/chunks/chunk-IROHIK2T.js.map +1 -0
  263. package/dist/cli-bundle/chunks/{chunk-GOO4UXBI.js → chunk-JZHL4E3Q.js} +4 -4
  264. package/dist/cli-bundle/chunks/{chunk-XXLMJDUB.js → chunk-KA22USXD.js} +21 -22
  265. package/dist/cli-bundle/chunks/chunk-KA22USXD.js.map +7 -0
  266. package/dist/cli-bundle/chunks/{chunk-WLH7X4RN.js → chunk-KBC4O7SY.js} +56 -72
  267. package/dist/cli-bundle/chunks/chunk-KBC4O7SY.js.map +7 -0
  268. package/dist/cli-bundle/chunks/{chunk-NN6RKGFW.js → chunk-KCAGIH6K.js} +3 -3
  269. package/dist/cli-bundle/chunks/{chunk-BVL5KGVA.js → chunk-KO3VM5GS.js} +27 -12
  270. package/dist/cli-bundle/chunks/chunk-KO3VM5GS.js.map +1 -0
  271. package/dist/cli-bundle/chunks/{chunk-IXVSSHGV.js → chunk-LNH5Q32E.js} +13 -8
  272. package/dist/cli-bundle/chunks/chunk-LNH5Q32E.js.map +7 -0
  273. package/dist/cli-bundle/chunks/{chunk-3FMQMHAG.js → chunk-LORM3M2I.js} +4 -4
  274. package/dist/cli-bundle/chunks/{chunk-3FMQMHAG.js.map → chunk-LORM3M2I.js.map} +1 -1
  275. package/dist/cli-bundle/chunks/{chunk-PNYAAB4S.js → chunk-LWGMDLQ6.js} +8 -3
  276. package/dist/cli-bundle/chunks/chunk-LWGMDLQ6.js.map +1 -0
  277. package/dist/cli-bundle/chunks/{chunk-GFBEXDCQ.js → chunk-M4AVU7VC.js} +19 -8
  278. package/dist/cli-bundle/chunks/{chunk-GFBEXDCQ.js.map → chunk-M4AVU7VC.js.map} +2 -2
  279. package/dist/cli-bundle/chunks/{chunk-3CQPVBK3.js → chunk-MIBX6ZRN.js} +3 -3
  280. package/dist/cli-bundle/chunks/{chunk-AUDDXKNX.js → chunk-MMF2E3FM.js} +77 -9
  281. package/dist/cli-bundle/chunks/chunk-MMF2E3FM.js.map +1 -0
  282. package/dist/cli-bundle/chunks/{chunk-RFR2YQGO.js → chunk-MORZOR7W.js} +21 -8
  283. package/dist/cli-bundle/chunks/chunk-MORZOR7W.js.map +1 -0
  284. package/dist/cli-bundle/chunks/{chunk-4TPFXE2R.js → chunk-MUTUZ2HD.js} +118 -74
  285. package/dist/cli-bundle/chunks/chunk-MUTUZ2HD.js.map +1 -0
  286. package/dist/cli-bundle/chunks/{chunk-HZOX5BYD.js → chunk-OGXEBTX3.js} +35 -17
  287. package/dist/cli-bundle/chunks/chunk-OGXEBTX3.js.map +7 -0
  288. package/dist/cli-bundle/chunks/{chunk-LOAR5TKX.js → chunk-OOIH6J5T.js} +4 -4
  289. package/dist/cli-bundle/chunks/{chunk-LOAR5TKX.js.map → chunk-OOIH6J5T.js.map} +1 -1
  290. package/dist/cli-bundle/chunks/{chunk-VNC2HBL4.js → chunk-OSBJPPX3.js} +20 -9
  291. package/dist/cli-bundle/chunks/chunk-OSBJPPX3.js.map +1 -0
  292. package/dist/cli-bundle/chunks/{chunk-2ANTZBYF.js → chunk-PJS3WDO2.js} +122 -45
  293. package/dist/cli-bundle/chunks/chunk-PJS3WDO2.js.map +1 -0
  294. package/dist/cli-bundle/chunks/{chunk-7SM7VA5I.js → chunk-QGPE2H6Z.js} +19 -8
  295. package/dist/cli-bundle/chunks/chunk-QGPE2H6Z.js.map +7 -0
  296. package/dist/cli-bundle/chunks/chunk-QVTFFLR2.js +58 -0
  297. package/dist/cli-bundle/chunks/chunk-QVTFFLR2.js.map +1 -0
  298. package/dist/cli-bundle/chunks/{chunk-JCTZV7TO.js → chunk-QW2F6ARZ.js} +8 -5
  299. package/dist/cli-bundle/chunks/{chunk-JCTZV7TO.js.map → chunk-QW2F6ARZ.js.map} +1 -1
  300. package/dist/cli-bundle/chunks/{chunk-TOX7YQ7X.js → chunk-QXC3LWB7.js} +223 -50
  301. package/dist/cli-bundle/chunks/chunk-QXC3LWB7.js.map +1 -0
  302. package/dist/cli-bundle/chunks/{chunk-W6KNFAMZ.js → chunk-QXMXRPX5.js} +9 -8
  303. package/dist/cli-bundle/chunks/chunk-QXMXRPX5.js.map +7 -0
  304. package/dist/cli-bundle/chunks/{chunk-O3YCJOVX.js → chunk-R4AKUPKI.js} +3 -3
  305. package/dist/cli-bundle/chunks/{chunk-O3YCJOVX.js.map → chunk-R4AKUPKI.js.map} +1 -1
  306. package/dist/cli-bundle/chunks/chunk-RASR23HV.js +394 -0
  307. package/dist/cli-bundle/chunks/chunk-RASR23HV.js.map +1 -0
  308. package/dist/cli-bundle/chunks/{chunk-JW7D6437.js → chunk-SCDCNGCV.js} +20 -9
  309. package/dist/cli-bundle/chunks/chunk-SCDCNGCV.js.map +1 -0
  310. package/dist/cli-bundle/chunks/{chunk-GRZGHGRG.js → chunk-SCS5PVAA.js} +10 -9
  311. package/dist/cli-bundle/chunks/{chunk-GRZGHGRG.js.map → chunk-SCS5PVAA.js.map} +2 -2
  312. package/dist/cli-bundle/chunks/{chunk-S2CDTRJ6.js → chunk-SJCMTOEU.js} +381 -271
  313. package/dist/cli-bundle/chunks/chunk-SJCMTOEU.js.map +1 -0
  314. package/dist/cli-bundle/chunks/{chunk-XWDZVCBJ.js → chunk-SO2ES46D.js} +11 -10
  315. package/dist/cli-bundle/chunks/{chunk-XWDZVCBJ.js.map → chunk-SO2ES46D.js.map} +1 -1
  316. package/dist/cli-bundle/chunks/{chunk-MACCNKSZ.js → chunk-TBV33CB4.js} +36 -62
  317. package/dist/cli-bundle/chunks/chunk-TBV33CB4.js.map +7 -0
  318. package/dist/cli-bundle/chunks/chunk-TEFEXQWI.js +86 -0
  319. package/dist/cli-bundle/chunks/chunk-TEFEXQWI.js.map +7 -0
  320. package/dist/cli-bundle/chunks/{chunk-HLEGAQXT.js → chunk-TWBDDVIF.js} +20 -7
  321. package/dist/cli-bundle/chunks/chunk-TWBDDVIF.js.map +7 -0
  322. package/dist/cli-bundle/chunks/{chunk-4JHJ7YG2.js → chunk-UGUJ2UOR.js} +118 -74
  323. package/dist/cli-bundle/chunks/chunk-UGUJ2UOR.js.map +7 -0
  324. package/dist/cli-bundle/chunks/{chunk-XOYHMHFF.js → chunk-UN6P3IJ4.js} +3 -3
  325. package/dist/cli-bundle/chunks/{chunk-32XSW44C.js → chunk-V2GYOMEX.js} +10 -9
  326. package/dist/cli-bundle/chunks/chunk-V2GYOMEX.js.map +1 -0
  327. package/dist/cli-bundle/chunks/{chunk-HWHONML5.js → chunk-VF3KQGNY.js} +4 -4
  328. package/dist/cli-bundle/chunks/{chunk-SOHXUA2Q.js → chunk-VHG6LUKR.js} +116 -36
  329. package/dist/cli-bundle/chunks/chunk-VHG6LUKR.js.map +1 -0
  330. package/dist/cli-bundle/chunks/{chunk-7CRFV6JR.js → chunk-VXHMQDXA.js} +483 -27
  331. package/dist/cli-bundle/chunks/chunk-VXHMQDXA.js.map +7 -0
  332. package/dist/cli-bundle/chunks/{chunk-IZHCCG4S.js → chunk-VXRFAE7W.js} +14 -9
  333. package/dist/cli-bundle/chunks/chunk-VXRFAE7W.js.map +1 -0
  334. package/dist/cli-bundle/chunks/{chunk-R4VWYWRN.js → chunk-W3HFLORZ.js} +7 -2
  335. package/dist/cli-bundle/chunks/chunk-W3HFLORZ.js.map +7 -0
  336. package/dist/cli-bundle/chunks/{chunk-4FHLNNW7.js → chunk-WQRL4COW.js} +74 -14
  337. package/dist/cli-bundle/chunks/chunk-WQRL4COW.js.map +7 -0
  338. package/dist/cli-bundle/chunks/chunk-X3W5ESZQ.js +32 -0
  339. package/dist/cli-bundle/chunks/chunk-X3W5ESZQ.js.map +1 -0
  340. package/dist/cli-bundle/chunks/{chunk-MGAQ6KZG.js → chunk-XESAPVZ4.js} +166 -27
  341. package/dist/cli-bundle/chunks/chunk-XESAPVZ4.js.map +7 -0
  342. package/dist/cli-bundle/chunks/{chunk-PEH7SZD2.js → chunk-YLAW3FZN.js} +105 -31
  343. package/dist/cli-bundle/chunks/chunk-YLAW3FZN.js.map +7 -0
  344. package/dist/cli-bundle/chunks/{claim-HE6KEGJW.js → claim-WGAWJCPY.js} +10 -10
  345. package/dist/cli-bundle/chunks/{claim-QJOQBH7J.js → claim-ZI6P4LMU.js} +10 -10
  346. package/dist/cli-bundle/chunks/close-I7PRQ5G7.js +13 -0
  347. package/dist/cli-bundle/chunks/{close-SPUFW5QR.js → close-JMVVSIQE.js} +8 -8
  348. package/dist/cli-bundle/chunks/{close-many-GKAJX54X.js → close-many-IKPJXVOZ.js} +32 -20
  349. package/dist/cli-bundle/chunks/close-many-IKPJXVOZ.js.map +1 -0
  350. package/dist/cli-bundle/chunks/{close-many-GL6NRUU5.js → close-many-TXABDCSJ.js} +31 -19
  351. package/dist/cli-bundle/chunks/close-many-TXABDCSJ.js.map +7 -0
  352. package/dist/cli-bundle/chunks/{comments-5FPT6L7N.js → comments-RLWR2S7W.js} +55 -31
  353. package/dist/cli-bundle/chunks/comments-RLWR2S7W.js.map +1 -0
  354. package/dist/cli-bundle/chunks/{comments-TOLOYWNI.js → comments-YAMXKHUX.js} +54 -30
  355. package/dist/cli-bundle/chunks/comments-YAMXKHUX.js.map +7 -0
  356. package/dist/cli-bundle/chunks/{config-7N6D7YJE.js → config-7ICYC2WU.js} +83 -19
  357. package/dist/cli-bundle/chunks/config-7ICYC2WU.js.map +7 -0
  358. package/dist/cli-bundle/chunks/{config-4MN45TIH.js → config-NGWN3EXC.js} +83 -19
  359. package/dist/cli-bundle/chunks/config-NGWN3EXC.js.map +1 -0
  360. package/dist/cli-bundle/chunks/{context-AQSLE7DZ.js → context-K6QAHN5H.js} +128 -39
  361. package/dist/cli-bundle/chunks/context-K6QAHN5H.js.map +1 -0
  362. package/dist/cli-bundle/chunks/{context-U3PUJMVN.js → context-VGXOOAH2.js} +127 -38
  363. package/dist/cli-bundle/chunks/context-VGXOOAH2.js.map +7 -0
  364. package/dist/cli-bundle/chunks/{contracts-ITSJXO3O.js → contracts-KJGY2AQA.js} +99 -15
  365. package/dist/cli-bundle/chunks/contracts-KJGY2AQA.js.map +1 -0
  366. package/dist/cli-bundle/chunks/{contracts-H7KCQXLY.js → contracts-KMA6OJY7.js} +99 -15
  367. package/dist/cli-bundle/chunks/contracts-KMA6OJY7.js.map +7 -0
  368. package/dist/cli-bundle/chunks/{copy-EB3MUCSW.js → copy-Q2PPU4AY.js} +7 -7
  369. package/dist/cli-bundle/chunks/{copy-C4W522JM.js → copy-SC6UF3PI.js} +7 -7
  370. package/dist/cli-bundle/chunks/{create-4EQNELMY.js → create-76FE7JVF.js} +16 -13
  371. package/dist/cli-bundle/chunks/create-RTRFW6RE.js +30 -0
  372. package/dist/cli-bundle/chunks/{delete-X5QLXIQX.js → delete-T6DJSUJI.js} +7 -7
  373. package/dist/cli-bundle/chunks/{delete-ZLGUYIXU.js → delete-XFUX533E.js} +7 -7
  374. package/dist/cli-bundle/chunks/{deps-GPB3LGWN.js → deps-5GWMMS6D.js} +9 -10
  375. package/dist/cli-bundle/chunks/{deps-GPB3LGWN.js.map → deps-5GWMMS6D.js.map} +2 -2
  376. package/dist/cli-bundle/chunks/{deps-HV2C2L46.js → deps-MCCU633S.js} +10 -11
  377. package/dist/cli-bundle/chunks/deps-MCCU633S.js.map +1 -0
  378. package/dist/cli-bundle/chunks/{docs-SRTLCQOL.js → docs-HE3HCQ4S.js} +9 -9
  379. package/dist/cli-bundle/chunks/{docs-RJQPLROO.js → docs-SXMOABHR.js} +9 -9
  380. package/dist/cli-bundle/chunks/{extension-WKPVPNCC.js → extension-E23K4QRR.js} +7 -5
  381. package/dist/cli-bundle/chunks/{extension-MM3TVWOO.js → extension-PMD3XMLN.js} +7 -5
  382. package/dist/cli-bundle/chunks/{files-OIFN3DQX.js → files-2RSWGPEU.js} +25 -11
  383. package/dist/cli-bundle/chunks/files-2RSWGPEU.js.map +1 -0
  384. package/dist/cli-bundle/chunks/{files-LIFDKNCN.js → files-ZWFJFWBK.js} +24 -10
  385. package/dist/cli-bundle/chunks/files-ZWFJFWBK.js.map +7 -0
  386. package/dist/cli-bundle/chunks/focus-KTTB3P3F.js +106 -0
  387. package/dist/cli-bundle/chunks/focus-KTTB3P3F.js.map +1 -0
  388. package/dist/cli-bundle/chunks/focus-ZMDP4FEL.js +109 -0
  389. package/dist/cli-bundle/chunks/focus-ZMDP4FEL.js.map +7 -0
  390. package/dist/cli-bundle/chunks/{gc-NRFHLVFT.js → gc-BXIAKLAH.js} +3 -3
  391. package/dist/cli-bundle/chunks/{gc-DL6AVOX5.js → gc-C7K6JNUO.js} +3 -3
  392. package/dist/cli-bundle/chunks/{get-SAB7CRBG.js → get-AZQLC4NO.js} +43 -16
  393. package/dist/cli-bundle/chunks/get-AZQLC4NO.js.map +1 -0
  394. package/dist/cli-bundle/chunks/{get-K7UULTQF.js → get-I65HTAWO.js} +42 -15
  395. package/dist/cli-bundle/chunks/get-I65HTAWO.js.map +7 -0
  396. package/dist/cli-bundle/chunks/{health-NUVZYIEV.js → health-3MFFPQVZ.js} +75 -49
  397. package/dist/cli-bundle/chunks/health-3MFFPQVZ.js.map +1 -0
  398. package/dist/cli-bundle/chunks/{health-VJWH3ZFK.js → health-MYZEOCLI.js} +74 -48
  399. package/dist/cli-bundle/chunks/health-MYZEOCLI.js.map +7 -0
  400. package/dist/cli-bundle/chunks/{history-GYFD2DJW.js → history-73Z6OBFZ.js} +10 -10
  401. package/dist/cli-bundle/chunks/history-BIPHVUMF.js +20 -0
  402. package/dist/cli-bundle/chunks/{history-compact-WQZQ6KXM.js → history-compact-24VQ63A3.js} +37 -46
  403. package/dist/cli-bundle/chunks/history-compact-24VQ63A3.js.map +7 -0
  404. package/dist/cli-bundle/chunks/{history-compact-SLL6ESXH.js → history-compact-UIAR2OI4.js} +38 -47
  405. package/dist/cli-bundle/chunks/history-compact-UIAR2OI4.js.map +1 -0
  406. package/dist/cli-bundle/chunks/{history-redact-SDTDR6WM.js → history-redact-7YCXEWJD.js} +13 -11
  407. package/dist/cli-bundle/chunks/history-redact-WZZ6GZ2Z.js +21 -0
  408. package/dist/cli-bundle/chunks/{history-repair-BJCGM6Q3.js → history-repair-4NOFFG2W.js} +44 -49
  409. package/dist/cli-bundle/chunks/history-repair-4NOFFG2W.js.map +1 -0
  410. package/dist/cli-bundle/chunks/{history-repair-UCYS55ZX.js → history-repair-GQN2X4TR.js} +43 -48
  411. package/dist/cli-bundle/chunks/history-repair-GQN2X4TR.js.map +7 -0
  412. package/dist/cli-bundle/chunks/init-K34V4PZR.js +20 -0
  413. package/dist/cli-bundle/chunks/{init-MXV57LKL.js → init-TDEDNVMM.js} +12 -9
  414. package/dist/cli-bundle/chunks/{learnings-QKJOKEAO.js → learnings-TV2CTGJ3.js} +13 -12
  415. package/dist/cli-bundle/chunks/learnings-TV2CTGJ3.js.map +7 -0
  416. package/dist/cli-bundle/chunks/{learnings-L6KTZGOT.js → learnings-U67FTXPB.js} +14 -13
  417. package/dist/cli-bundle/chunks/learnings-U67FTXPB.js.map +1 -0
  418. package/dist/cli-bundle/chunks/list-MSHYOCFU.js +33 -0
  419. package/dist/cli-bundle/chunks/list-VV57WGUD.js +29 -0
  420. package/dist/cli-bundle/chunks/{notes-HMCB7TK6.js → notes-EUANWWKD.js} +13 -12
  421. package/dist/cli-bundle/chunks/notes-EUANWWKD.js.map +7 -0
  422. package/dist/cli-bundle/chunks/{notes-3NLK7WTZ.js → notes-GYVNDAL4.js} +14 -13
  423. package/dist/cli-bundle/chunks/notes-GYVNDAL4.js.map +1 -0
  424. package/dist/cli-bundle/chunks/{plan-NANUWH4T.js → plan-4LF4AV63.js} +15 -14
  425. package/dist/cli-bundle/chunks/plan-4LF4AV63.js.map +7 -0
  426. package/dist/cli-bundle/chunks/{plan-DWBYI5C6.js → plan-W27O6DBS.js} +16 -15
  427. package/dist/cli-bundle/chunks/plan-W27O6DBS.js.map +1 -0
  428. package/dist/cli-bundle/chunks/{register-list-query-SMMMLSWW.js → register-list-query-BXLEHJ7L.js} +32 -23
  429. package/dist/cli-bundle/chunks/register-list-query-BXLEHJ7L.js.map +1 -0
  430. package/dist/cli-bundle/chunks/{register-list-query-PWQ5F2VI.js → register-list-query-C2MS3BVQ.js} +31 -22
  431. package/dist/cli-bundle/chunks/register-list-query-C2MS3BVQ.js.map +7 -0
  432. package/dist/cli-bundle/chunks/{register-mutation-QKFPTIZG.js → register-mutation-6UCOEQ6L.js} +361 -106
  433. package/dist/cli-bundle/chunks/register-mutation-6UCOEQ6L.js.map +7 -0
  434. package/dist/cli-bundle/chunks/{register-mutation-ZYJQ4DVP.js → register-mutation-HE73PREP.js} +355 -107
  435. package/dist/cli-bundle/chunks/register-mutation-HE73PREP.js.map +1 -0
  436. package/dist/cli-bundle/chunks/{register-operations-2FMZ6WEF.js → register-operations-L6C32FDA.js} +111 -39
  437. package/dist/cli-bundle/chunks/register-operations-L6C32FDA.js.map +7 -0
  438. package/dist/cli-bundle/chunks/{register-operations-BAFQURZG.js → register-operations-QQEHEX4P.js} +112 -40
  439. package/dist/cli-bundle/chunks/register-operations-QQEHEX4P.js.map +1 -0
  440. package/dist/cli-bundle/chunks/{register-setup-QN2XV7UL.js → register-setup-A7N4PNT3.js} +18 -21
  441. package/dist/cli-bundle/chunks/register-setup-A7N4PNT3.js.map +1 -0
  442. package/dist/cli-bundle/chunks/{register-setup-DQEIKBIP.js → register-setup-WHG3NBP6.js} +17 -20
  443. package/dist/cli-bundle/chunks/register-setup-WHG3NBP6.js.map +7 -0
  444. package/dist/cli-bundle/chunks/{restore-FJQWXMPY.js → restore-TSWSULYY.js} +13 -11
  445. package/dist/cli-bundle/chunks/restore-XQXICL3V.js +19 -0
  446. package/dist/cli-bundle/chunks/scheduling-shortcuts-NC46K6BD.js +91 -0
  447. package/dist/cli-bundle/chunks/scheduling-shortcuts-NC46K6BD.js.map +7 -0
  448. package/dist/cli-bundle/chunks/scheduling-shortcuts-UGDPQALY.js +88 -0
  449. package/dist/cli-bundle/chunks/scheduling-shortcuts-UGDPQALY.js.map +1 -0
  450. package/dist/cli-bundle/chunks/{schema-ZZ7ZDM2X.js → schema-7U7JUYGK.js} +797 -10
  451. package/dist/cli-bundle/chunks/schema-7U7JUYGK.js.map +1 -0
  452. package/dist/cli-bundle/chunks/{schema-RNVJ55V2.js → schema-TSBYSEMW.js} +810 -9
  453. package/dist/cli-bundle/chunks/schema-TSBYSEMW.js.map +7 -0
  454. package/dist/cli-bundle/chunks/{search-BJ457C2A.js → search-OXLSQKHP.js} +328 -71
  455. package/dist/cli-bundle/chunks/search-OXLSQKHP.js.map +7 -0
  456. package/dist/cli-bundle/chunks/{search-FQDZXX7P.js → search-T3TOFLOQ.js} +328 -71
  457. package/dist/cli-bundle/chunks/search-T3TOFLOQ.js.map +1 -0
  458. package/dist/cli-bundle/chunks/{stats-DUQWCVOS.js → stats-5CLG22YZ.js} +41 -16
  459. package/dist/cli-bundle/chunks/stats-5CLG22YZ.js.map +7 -0
  460. package/dist/cli-bundle/chunks/{stats-CUG3ZHOI.js → stats-XEMUXS42.js} +42 -17
  461. package/dist/cli-bundle/chunks/stats-XEMUXS42.js.map +1 -0
  462. package/dist/cli-bundle/chunks/{telemetry-RK2VX75A.js → telemetry-23OPBBZT.js} +7 -7
  463. package/dist/cli-bundle/chunks/telemetry-23OPBBZT.js.map +1 -0
  464. package/dist/cli-bundle/chunks/{telemetry-33MRGX4Z.js → telemetry-I3D7XZ55.js} +6 -6
  465. package/dist/cli-bundle/chunks/telemetry-I3D7XZ55.js.map +7 -0
  466. package/dist/cli-bundle/chunks/test-AROS3LIV.js +35 -0
  467. package/dist/cli-bundle/chunks/{test-Y3CTFMEC.js → test-CECIMKOA.js} +17 -14
  468. package/dist/cli-bundle/chunks/{test-all-ARSMX33Q.js → test-all-4DEQPIXH.js} +25 -17
  469. package/dist/cli-bundle/chunks/test-all-4DEQPIXH.js.map +1 -0
  470. package/dist/cli-bundle/chunks/{test-all-ANYQ33O2.js → test-all-6RO6X3SM.js} +24 -16
  471. package/dist/cli-bundle/chunks/test-all-6RO6X3SM.js.map +7 -0
  472. package/dist/cli-bundle/chunks/{test-runs-5URSD34O.js → test-runs-AAXVFWKH.js} +62 -65
  473. package/dist/cli-bundle/chunks/test-runs-AAXVFWKH.js.map +1 -0
  474. package/dist/cli-bundle/chunks/{test-runs-XNACGSNQ.js → test-runs-LYBQSYRC.js} +61 -64
  475. package/dist/cli-bundle/chunks/test-runs-LYBQSYRC.js.map +7 -0
  476. package/dist/cli-bundle/chunks/update-MIWEJC76.js +24 -0
  477. package/dist/cli-bundle/chunks/update-P7I5YSRB.js +28 -0
  478. package/dist/cli-bundle/chunks/{update-many-724JCVDE.js → update-many-5B4HLVBK.js} +79 -33
  479. package/dist/cli-bundle/chunks/update-many-5B4HLVBK.js.map +7 -0
  480. package/dist/cli-bundle/chunks/{update-many-6B7PJ33I.js → update-many-G2QOVZSB.js} +80 -34
  481. package/dist/cli-bundle/chunks/update-many-G2QOVZSB.js.map +1 -0
  482. package/dist/cli-bundle/chunks/{upgrade-QHRGDBSA.js → upgrade-GFIDL62L.js} +23 -9
  483. package/dist/cli-bundle/chunks/upgrade-GFIDL62L.js.map +1 -0
  484. package/dist/cli-bundle/chunks/{upgrade-ALBEZAI7.js → upgrade-QUQYL7D3.js} +22 -8
  485. package/dist/cli-bundle/chunks/upgrade-QUQYL7D3.js.map +7 -0
  486. package/dist/cli-bundle/chunks/{validate-UY6DRCG5.js → validate-ADDZBMM3.js} +236 -30
  487. package/dist/cli-bundle/chunks/validate-ADDZBMM3.js.map +7 -0
  488. package/dist/cli-bundle/chunks/{validate-IQRYFXIV.js → validate-MAS3H6ZP.js} +222 -30
  489. package/dist/cli-bundle/chunks/validate-MAS3H6ZP.js.map +1 -0
  490. package/dist/cli-bundle/main.js +312 -139
  491. package/dist/cli-bundle/main.js.map +3 -3
  492. package/dist/cli.d.ts +10 -0
  493. package/dist/cli.js +21 -8
  494. package/dist/cli.js.map +1 -1
  495. package/dist/core/config/nested-settings.js +40 -2
  496. package/dist/core/config/nested-settings.js.map +1 -1
  497. package/dist/core/diagnostics/remediation.js +7 -2
  498. package/dist/core/diagnostics/remediation.js.map +1 -1
  499. package/dist/core/extensions/extension-policy.js +14 -15
  500. package/dist/core/extensions/extension-policy.js.map +1 -1
  501. package/dist/core/extensions/item-fields.js +4 -5
  502. package/dist/core/extensions/item-fields.js.map +1 -1
  503. package/dist/core/extensions/loader.d.ts +75 -1
  504. package/dist/core/extensions/loader.js +56 -32
  505. package/dist/core/extensions/loader.js.map +1 -1
  506. package/dist/core/governance/content-fields.d.ts +84 -0
  507. package/dist/core/governance/content-fields.js +182 -0
  508. package/dist/core/governance/content-fields.js.map +1 -0
  509. package/dist/core/governance/issue-codes.d.ts +51 -0
  510. package/dist/core/governance/issue-codes.js +95 -0
  511. package/dist/core/governance/issue-codes.js.map +1 -0
  512. package/dist/core/governance/metadata-coverage.d.ts +168 -0
  513. package/dist/core/governance/metadata-coverage.js +362 -0
  514. package/dist/core/governance/metadata-coverage.js.map +1 -0
  515. package/dist/core/history/history-rewrite.d.ts +22 -0
  516. package/dist/core/history/history-rewrite.js +38 -2
  517. package/dist/core/history/history-rewrite.js.map +1 -1
  518. package/dist/core/history/history.d.ts +7 -0
  519. package/dist/core/history/history.js +6 -2
  520. package/dist/core/history/history.js.map +1 -1
  521. package/dist/core/io/body-file.d.ts +14 -0
  522. package/dist/core/io/body-file.js +47 -0
  523. package/dist/core/io/body-file.js.map +1 -0
  524. package/dist/core/item/item-format.d.ts +46 -1
  525. package/dist/core/item/item-format.js +51 -60
  526. package/dist/core/item/item-format.js.map +1 -1
  527. package/dist/core/item/parse.d.ts +41 -0
  528. package/dist/core/item/parse.js +69 -16
  529. package/dist/core/item/parse.js.map +1 -1
  530. package/dist/core/item/type-registry.d.ts +1 -0
  531. package/dist/core/item/type-registry.js +8 -10
  532. package/dist/core/item/type-registry.js.map +1 -1
  533. package/dist/core/lock/lock.d.ts +26 -0
  534. package/dist/core/lock/lock.js +10 -2
  535. package/dist/core/lock/lock.js.map +1 -1
  536. package/dist/core/output/output.d.ts +7 -0
  537. package/dist/core/output/output.js +6 -2
  538. package/dist/core/output/output.js.map +1 -1
  539. package/dist/core/schema/fields-file.d.ts +94 -0
  540. package/dist/core/schema/fields-file.js +317 -0
  541. package/dist/core/schema/fields-file.js.map +1 -0
  542. package/dist/core/schema/item-types-file.d.ts +25 -2
  543. package/dist/core/schema/item-types-file.js +78 -6
  544. package/dist/core/schema/item-types-file.js.map +1 -1
  545. package/dist/core/schema/runtime-schema.d.ts +7 -0
  546. package/dist/core/schema/runtime-schema.js +23 -16
  547. package/dist/core/schema/runtime-schema.js.map +1 -1
  548. package/dist/core/schema/type-inference.d.ts +34 -0
  549. package/dist/core/schema/type-inference.js +97 -0
  550. package/dist/core/schema/type-inference.js.map +1 -0
  551. package/dist/core/schema/type-presets.d.ts +30 -0
  552. package/dist/core/schema/type-presets.js +96 -0
  553. package/dist/core/schema/type-presets.js.map +1 -0
  554. package/dist/core/search/cache.d.ts +19 -1
  555. package/dist/core/search/cache.js +11 -3
  556. package/dist/core/search/cache.js.map +1 -1
  557. package/dist/core/search/corpus.d.ts +36 -2
  558. package/dist/core/search/corpus.js +120 -24
  559. package/dist/core/search/corpus.js.map +1 -1
  560. package/dist/core/search/providers.d.ts +19 -0
  561. package/dist/core/search/providers.js +19 -2
  562. package/dist/core/search/providers.js.map +1 -1
  563. package/dist/core/sentry/instrument.d.ts +1 -0
  564. package/dist/core/sentry/instrument.js +6 -2
  565. package/dist/core/sentry/instrument.js.map +1 -1
  566. package/dist/core/session/session-state.d.ts +16 -0
  567. package/dist/core/session/session-state.js +48 -0
  568. package/dist/core/session/session-state.js.map +1 -0
  569. package/dist/core/shared/constants.d.ts +8 -0
  570. package/dist/core/shared/constants.js +11 -2
  571. package/dist/core/shared/constants.js.map +1 -1
  572. package/dist/core/shared/text-normalization.js +4 -3
  573. package/dist/core/shared/text-normalization.js.map +1 -1
  574. package/dist/core/shared/time.d.ts +13 -0
  575. package/dist/core/shared/time.js +19 -7
  576. package/dist/core/shared/time.js.map +1 -1
  577. package/dist/core/store/front-matter-cache.d.ts +13 -0
  578. package/dist/core/store/front-matter-cache.js +21 -11
  579. package/dist/core/store/front-matter-cache.js.map +1 -1
  580. package/dist/core/store/item-store.d.ts +11 -0
  581. package/dist/core/store/item-store.js +12 -3
  582. package/dist/core/store/item-store.js.map +1 -1
  583. package/dist/core/store/settings-validator.d.ts +2 -0
  584. package/dist/core/store/settings-validator.js +25 -2
  585. package/dist/core/store/settings-validator.js.map +1 -1
  586. package/dist/core/store/settings.d.ts +60 -1
  587. package/dist/core/store/settings.js +100 -46
  588. package/dist/core/store/settings.js.map +1 -1
  589. package/dist/core/telemetry/observability.js +10 -8
  590. package/dist/core/telemetry/observability.js.map +1 -1
  591. package/dist/core/telemetry/runtime.d.ts +272 -1
  592. package/dist/core/telemetry/runtime.js +358 -37
  593. package/dist/core/telemetry/runtime.js.map +1 -1
  594. package/dist/core/test/background-runs.d.ts +35 -0
  595. package/dist/core/test/background-runs.js +72 -61
  596. package/dist/core/test/background-runs.js.map +1 -1
  597. package/dist/core/test/run-selectors.js +5 -4
  598. package/dist/core/test/run-selectors.js.map +1 -1
  599. package/dist/core/validate/estimate-defaults.d.ts +39 -0
  600. package/dist/core/validate/estimate-defaults.js +117 -0
  601. package/dist/core/validate/estimate-defaults.js.map +1 -0
  602. package/dist/core/validate/fix-planning.d.ts +21 -3
  603. package/dist/core/validate/fix-planning.js +31 -4
  604. package/dist/core/validate/fix-planning.js.map +1 -1
  605. package/dist/core/validate/missing-link-owners.d.ts +64 -0
  606. package/dist/core/validate/missing-link-owners.js +98 -0
  607. package/dist/core/validate/missing-link-owners.js.map +1 -0
  608. package/dist/mcp/server.d.ts +61 -0
  609. package/dist/mcp/server.js +98 -8
  610. package/dist/mcp/server.js.map +1 -1
  611. package/dist/mcp/tool-definitions.js +64 -10
  612. package/dist/mcp/tool-definitions.js.map +1 -1
  613. package/dist/sdk/cli-contracts/commander-types.js +13 -2
  614. package/dist/sdk/cli-contracts/commander-types.js.map +1 -1
  615. package/dist/sdk/cli-contracts/enum-contracts.d.ts +2 -2
  616. package/dist/sdk/cli-contracts/enum-contracts.js +7 -2
  617. package/dist/sdk/cli-contracts/enum-contracts.js.map +1 -1
  618. package/dist/sdk/cli-contracts/tool-option-contracts.js +110 -2
  619. package/dist/sdk/cli-contracts/tool-option-contracts.js.map +1 -1
  620. package/dist/sdk/cli-contracts/tool-parameter-tables.js +127 -11
  621. package/dist/sdk/cli-contracts/tool-parameter-tables.js.map +1 -1
  622. package/dist/sdk/cli-contracts.d.ts +31 -0
  623. package/dist/sdk/cli-contracts.js +238 -12
  624. package/dist/sdk/cli-contracts.js.map +1 -1
  625. package/dist/types.d.ts +17 -1
  626. package/dist/types.js +3 -3
  627. package/dist/types.js.map +1 -1
  628. package/docs/AGENT_GUIDE.md +15 -3
  629. package/docs/CLAUDE_CODE_PLUGIN.md +2 -2
  630. package/docs/COMMANDS.md +171 -10
  631. package/docs/CONFIGURATION.md +135 -0
  632. package/docs/TESTING.md +6 -4
  633. package/package.json +6 -4
  634. package/packages/pm-calendar/extensions/calendar/runtime.js +6 -0
  635. package/packages/pm-calendar/extensions/calendar/runtime.ts +12 -0
  636. package/packages/pm-todos/extensions/todos/runtime.ts +5 -0
  637. package/plugins/pm-claude/.claude-plugin/plugin.json +1 -1
  638. package/plugins/pm-claude/README.md +3 -3
  639. package/plugins/pm-claude/commands/pm-init.md +1 -1
  640. package/plugins/pm-codex/README.md +1 -1
  641. package/scripts/bundle-cli.mjs +46 -37
  642. package/scripts/finalize-build.mjs +20 -9
  643. package/scripts/prepare-build-cache.mjs +27 -16
  644. package/dist/cli-bundle/chunks/activity-XIOTGZMU.js +0 -16
  645. package/dist/cli-bundle/chunks/aggregate-IRHJWEKG.js.map +0 -1
  646. package/dist/cli-bundle/chunks/aggregate-XEBW22UQ.js.map +0 -7
  647. package/dist/cli-bundle/chunks/append-NL67JNJU.js.map +0 -1
  648. package/dist/cli-bundle/chunks/chunk-2ANTZBYF.js.map +0 -1
  649. package/dist/cli-bundle/chunks/chunk-2J2AH4V5.js.map +0 -1
  650. package/dist/cli-bundle/chunks/chunk-32XSW44C.js.map +0 -1
  651. package/dist/cli-bundle/chunks/chunk-36BCSMKP.js.map +0 -7
  652. package/dist/cli-bundle/chunks/chunk-3VULHQNS.js.map +0 -1
  653. package/dist/cli-bundle/chunks/chunk-4FHLNNW7.js.map +0 -7
  654. package/dist/cli-bundle/chunks/chunk-4JHJ7YG2.js.map +0 -7
  655. package/dist/cli-bundle/chunks/chunk-4TPFXE2R.js.map +0 -1
  656. package/dist/cli-bundle/chunks/chunk-4ZKKZMLH.js.map +0 -1
  657. package/dist/cli-bundle/chunks/chunk-5HSAHRYA.js.map +0 -7
  658. package/dist/cli-bundle/chunks/chunk-6TBR5AZ2.js.map +0 -7
  659. package/dist/cli-bundle/chunks/chunk-7CRFV6JR.js.map +0 -7
  660. package/dist/cli-bundle/chunks/chunk-7SM7VA5I.js.map +0 -7
  661. package/dist/cli-bundle/chunks/chunk-AAUYXSFF.js.map +0 -7
  662. package/dist/cli-bundle/chunks/chunk-AGG32LKL.js.map +0 -1
  663. package/dist/cli-bundle/chunks/chunk-AUDDXKNX.js.map +0 -1
  664. package/dist/cli-bundle/chunks/chunk-BVL5KGVA.js.map +0 -1
  665. package/dist/cli-bundle/chunks/chunk-C24PWDFG.js +0 -138
  666. package/dist/cli-bundle/chunks/chunk-C24PWDFG.js.map +0 -7
  667. package/dist/cli-bundle/chunks/chunk-HLEGAQXT.js.map +0 -7
  668. package/dist/cli-bundle/chunks/chunk-HZOX5BYD.js.map +0 -7
  669. package/dist/cli-bundle/chunks/chunk-IXVSSHGV.js.map +0 -7
  670. package/dist/cli-bundle/chunks/chunk-IZHCCG4S.js.map +0 -1
  671. package/dist/cli-bundle/chunks/chunk-JW7D6437.js.map +0 -1
  672. package/dist/cli-bundle/chunks/chunk-JWXTOYBI.js.map +0 -7
  673. package/dist/cli-bundle/chunks/chunk-KHGTYCJ6.js.map +0 -1
  674. package/dist/cli-bundle/chunks/chunk-L6YQONLM.js.map +0 -1
  675. package/dist/cli-bundle/chunks/chunk-LFW5NQUP.js.map +0 -7
  676. package/dist/cli-bundle/chunks/chunk-LYNQ3NGI.js.map +0 -1
  677. package/dist/cli-bundle/chunks/chunk-M3SI2REU.js.map +0 -7
  678. package/dist/cli-bundle/chunks/chunk-MACCNKSZ.js.map +0 -7
  679. package/dist/cli-bundle/chunks/chunk-MGAQ6KZG.js.map +0 -7
  680. package/dist/cli-bundle/chunks/chunk-PEH7SZD2.js.map +0 -7
  681. package/dist/cli-bundle/chunks/chunk-PNYAAB4S.js.map +0 -1
  682. package/dist/cli-bundle/chunks/chunk-QQG4HEX7.js.map +0 -1
  683. package/dist/cli-bundle/chunks/chunk-R4VWYWRN.js.map +0 -7
  684. package/dist/cli-bundle/chunks/chunk-RFR2YQGO.js.map +0 -1
  685. package/dist/cli-bundle/chunks/chunk-RHYBR6G7.js.map +0 -1
  686. package/dist/cli-bundle/chunks/chunk-S2CDTRJ6.js.map +0 -1
  687. package/dist/cli-bundle/chunks/chunk-SGMGMCIF.js.map +0 -1
  688. package/dist/cli-bundle/chunks/chunk-SOHXUA2Q.js.map +0 -1
  689. package/dist/cli-bundle/chunks/chunk-SQDKAEKG.js.map +0 -7
  690. package/dist/cli-bundle/chunks/chunk-TOX7YQ7X.js.map +0 -1
  691. package/dist/cli-bundle/chunks/chunk-TSXWFN3L.js.map +0 -1
  692. package/dist/cli-bundle/chunks/chunk-UCVJP4JL.js.map +0 -7
  693. package/dist/cli-bundle/chunks/chunk-V4KP3TCN.js +0 -128
  694. package/dist/cli-bundle/chunks/chunk-V4KP3TCN.js.map +0 -1
  695. package/dist/cli-bundle/chunks/chunk-VNC2HBL4.js.map +0 -1
  696. package/dist/cli-bundle/chunks/chunk-W6KNFAMZ.js.map +0 -7
  697. package/dist/cli-bundle/chunks/chunk-WLH7X4RN.js.map +0 -7
  698. package/dist/cli-bundle/chunks/chunk-XXLMJDUB.js.map +0 -7
  699. package/dist/cli-bundle/chunks/close-WOG5WTMZ.js +0 -13
  700. package/dist/cli-bundle/chunks/close-many-GKAJX54X.js.map +0 -1
  701. package/dist/cli-bundle/chunks/close-many-GL6NRUU5.js.map +0 -7
  702. package/dist/cli-bundle/chunks/comments-5FPT6L7N.js.map +0 -1
  703. package/dist/cli-bundle/chunks/comments-TOLOYWNI.js.map +0 -7
  704. package/dist/cli-bundle/chunks/config-4MN45TIH.js.map +0 -1
  705. package/dist/cli-bundle/chunks/config-7N6D7YJE.js.map +0 -7
  706. package/dist/cli-bundle/chunks/context-AQSLE7DZ.js.map +0 -1
  707. package/dist/cli-bundle/chunks/context-U3PUJMVN.js.map +0 -7
  708. package/dist/cli-bundle/chunks/contracts-H7KCQXLY.js.map +0 -7
  709. package/dist/cli-bundle/chunks/contracts-ITSJXO3O.js.map +0 -1
  710. package/dist/cli-bundle/chunks/create-NW3K7LVG.js +0 -27
  711. package/dist/cli-bundle/chunks/deps-HV2C2L46.js.map +0 -1
  712. package/dist/cli-bundle/chunks/files-LIFDKNCN.js.map +0 -7
  713. package/dist/cli-bundle/chunks/files-OIFN3DQX.js.map +0 -1
  714. package/dist/cli-bundle/chunks/get-K7UULTQF.js.map +0 -7
  715. package/dist/cli-bundle/chunks/get-SAB7CRBG.js.map +0 -1
  716. package/dist/cli-bundle/chunks/health-NUVZYIEV.js.map +0 -1
  717. package/dist/cli-bundle/chunks/health-VJWH3ZFK.js.map +0 -7
  718. package/dist/cli-bundle/chunks/history-IUVN4NTN.js +0 -20
  719. package/dist/cli-bundle/chunks/history-compact-SLL6ESXH.js.map +0 -1
  720. package/dist/cli-bundle/chunks/history-compact-WQZQ6KXM.js.map +0 -7
  721. package/dist/cli-bundle/chunks/history-redact-75KIIJUJ.js +0 -19
  722. package/dist/cli-bundle/chunks/history-repair-BJCGM6Q3.js.map +0 -1
  723. package/dist/cli-bundle/chunks/history-repair-UCYS55ZX.js.map +0 -7
  724. package/dist/cli-bundle/chunks/init-JJFYRUKG.js +0 -17
  725. package/dist/cli-bundle/chunks/learnings-L6KTZGOT.js.map +0 -1
  726. package/dist/cli-bundle/chunks/learnings-QKJOKEAO.js.map +0 -7
  727. package/dist/cli-bundle/chunks/list-GGVPXEV6.js +0 -23
  728. package/dist/cli-bundle/chunks/list-VOQDQHA4.js +0 -19
  729. package/dist/cli-bundle/chunks/notes-3NLK7WTZ.js.map +0 -1
  730. package/dist/cli-bundle/chunks/notes-HMCB7TK6.js.map +0 -7
  731. package/dist/cli-bundle/chunks/plan-DWBYI5C6.js.map +0 -1
  732. package/dist/cli-bundle/chunks/plan-NANUWH4T.js.map +0 -7
  733. package/dist/cli-bundle/chunks/register-list-query-PWQ5F2VI.js.map +0 -7
  734. package/dist/cli-bundle/chunks/register-list-query-SMMMLSWW.js.map +0 -1
  735. package/dist/cli-bundle/chunks/register-mutation-QKFPTIZG.js.map +0 -7
  736. package/dist/cli-bundle/chunks/register-mutation-ZYJQ4DVP.js.map +0 -1
  737. package/dist/cli-bundle/chunks/register-operations-2FMZ6WEF.js.map +0 -7
  738. package/dist/cli-bundle/chunks/register-operations-BAFQURZG.js.map +0 -1
  739. package/dist/cli-bundle/chunks/register-setup-DQEIKBIP.js.map +0 -7
  740. package/dist/cli-bundle/chunks/register-setup-QN2XV7UL.js.map +0 -1
  741. package/dist/cli-bundle/chunks/restore-DRBNXJJH.js +0 -17
  742. package/dist/cli-bundle/chunks/schema-RNVJ55V2.js.map +0 -7
  743. package/dist/cli-bundle/chunks/schema-ZZ7ZDM2X.js.map +0 -1
  744. package/dist/cli-bundle/chunks/search-BJ457C2A.js.map +0 -7
  745. package/dist/cli-bundle/chunks/search-FQDZXX7P.js.map +0 -1
  746. package/dist/cli-bundle/chunks/stats-CUG3ZHOI.js.map +0 -1
  747. package/dist/cli-bundle/chunks/stats-DUQWCVOS.js.map +0 -7
  748. package/dist/cli-bundle/chunks/telemetry-33MRGX4Z.js.map +0 -7
  749. package/dist/cli-bundle/chunks/telemetry-RK2VX75A.js.map +0 -1
  750. package/dist/cli-bundle/chunks/test-SDMYEQHH.js +0 -32
  751. package/dist/cli-bundle/chunks/test-all-ANYQ33O2.js.map +0 -7
  752. package/dist/cli-bundle/chunks/test-all-ARSMX33Q.js.map +0 -1
  753. package/dist/cli-bundle/chunks/test-runs-5URSD34O.js.map +0 -1
  754. package/dist/cli-bundle/chunks/test-runs-XNACGSNQ.js.map +0 -7
  755. package/dist/cli-bundle/chunks/update-PD46VOXI.js +0 -21
  756. package/dist/cli-bundle/chunks/update-U235A7WP.js +0 -25
  757. package/dist/cli-bundle/chunks/update-many-6B7PJ33I.js.map +0 -1
  758. package/dist/cli-bundle/chunks/update-many-724JCVDE.js.map +0 -7
  759. package/dist/cli-bundle/chunks/upgrade-ALBEZAI7.js.map +0 -7
  760. package/dist/cli-bundle/chunks/upgrade-QHRGDBSA.js.map +0 -1
  761. package/dist/cli-bundle/chunks/validate-IQRYFXIV.js.map +0 -1
  762. package/dist/cli-bundle/chunks/validate-UY6DRCG5.js.map +0 -7
  763. /package/dist/cli-bundle/chunks/{activity-XIOTGZMU.js.map → activity-PZYSZA26.js.map} +0 -0
  764. /package/dist/cli-bundle/chunks/{activity-PPO7QWJF.js.map → activity-SFM4THAU.js.map} +0 -0
  765. /package/dist/cli-bundle/chunks/{chunk-IIOIBAQW.js.map → chunk-26BM6YLO.js.map} +0 -0
  766. /package/dist/cli-bundle/chunks/{chunk-LSSTKL3Y.js.map → chunk-2TMKMTEI.js.map} +0 -0
  767. /package/dist/cli-bundle/chunks/{chunk-QU3OPNVV.js.map → chunk-2VH7DFSJ.js.map} +0 -0
  768. /package/dist/cli-bundle/chunks/{chunk-LGOXXQUW.js.map → chunk-5XGWFUW2.js.map} +0 -0
  769. /package/dist/cli-bundle/chunks/{chunk-Z647PYLD.js.map → chunk-AJCQ5GT6.js.map} +0 -0
  770. /package/dist/cli-bundle/chunks/{chunk-DWG4FHPY.js.map → chunk-BITCVGHT.js.map} +0 -0
  771. /package/dist/cli-bundle/chunks/{chunk-JE5IZXDS.js.map → chunk-CGQTFWYI.js.map} +0 -0
  772. /package/dist/cli-bundle/chunks/{chunk-VYZNX4C5.js.map → chunk-COVLE33A.js.map} +0 -0
  773. /package/dist/cli-bundle/chunks/{chunk-6ZFTM65G.js.map → chunk-F5MSD5HE.js.map} +0 -0
  774. /package/dist/cli-bundle/chunks/{chunk-GOO4UXBI.js.map → chunk-JZHL4E3Q.js.map} +0 -0
  775. /package/dist/cli-bundle/chunks/{chunk-NN6RKGFW.js.map → chunk-KCAGIH6K.js.map} +0 -0
  776. /package/dist/cli-bundle/chunks/{chunk-3CQPVBK3.js.map → chunk-MIBX6ZRN.js.map} +0 -0
  777. /package/dist/cli-bundle/chunks/{chunk-XOYHMHFF.js.map → chunk-UN6P3IJ4.js.map} +0 -0
  778. /package/dist/cli-bundle/chunks/{chunk-HWHONML5.js.map → chunk-VF3KQGNY.js.map} +0 -0
  779. /package/dist/cli-bundle/chunks/{claim-HE6KEGJW.js.map → claim-WGAWJCPY.js.map} +0 -0
  780. /package/dist/cli-bundle/chunks/{claim-QJOQBH7J.js.map → claim-ZI6P4LMU.js.map} +0 -0
  781. /package/dist/cli-bundle/chunks/{close-WOG5WTMZ.js.map → close-I7PRQ5G7.js.map} +0 -0
  782. /package/dist/cli-bundle/chunks/{close-SPUFW5QR.js.map → close-JMVVSIQE.js.map} +0 -0
  783. /package/dist/cli-bundle/chunks/{copy-EB3MUCSW.js.map → copy-Q2PPU4AY.js.map} +0 -0
  784. /package/dist/cli-bundle/chunks/{copy-C4W522JM.js.map → copy-SC6UF3PI.js.map} +0 -0
  785. /package/dist/cli-bundle/chunks/{create-4EQNELMY.js.map → create-76FE7JVF.js.map} +0 -0
  786. /package/dist/cli-bundle/chunks/{create-NW3K7LVG.js.map → create-RTRFW6RE.js.map} +0 -0
  787. /package/dist/cli-bundle/chunks/{delete-X5QLXIQX.js.map → delete-T6DJSUJI.js.map} +0 -0
  788. /package/dist/cli-bundle/chunks/{delete-ZLGUYIXU.js.map → delete-XFUX533E.js.map} +0 -0
  789. /package/dist/cli-bundle/chunks/{docs-SRTLCQOL.js.map → docs-HE3HCQ4S.js.map} +0 -0
  790. /package/dist/cli-bundle/chunks/{docs-RJQPLROO.js.map → docs-SXMOABHR.js.map} +0 -0
  791. /package/dist/cli-bundle/chunks/{extension-WKPVPNCC.js.map → extension-E23K4QRR.js.map} +0 -0
  792. /package/dist/cli-bundle/chunks/{extension-MM3TVWOO.js.map → extension-PMD3XMLN.js.map} +0 -0
  793. /package/dist/cli-bundle/chunks/{gc-NRFHLVFT.js.map → gc-BXIAKLAH.js.map} +0 -0
  794. /package/dist/cli-bundle/chunks/{gc-DL6AVOX5.js.map → gc-C7K6JNUO.js.map} +0 -0
  795. /package/dist/cli-bundle/chunks/{history-GYFD2DJW.js.map → history-73Z6OBFZ.js.map} +0 -0
  796. /package/dist/cli-bundle/chunks/{history-IUVN4NTN.js.map → history-BIPHVUMF.js.map} +0 -0
  797. /package/dist/cli-bundle/chunks/{history-redact-SDTDR6WM.js.map → history-redact-7YCXEWJD.js.map} +0 -0
  798. /package/dist/cli-bundle/chunks/{history-redact-75KIIJUJ.js.map → history-redact-WZZ6GZ2Z.js.map} +0 -0
  799. /package/dist/cli-bundle/chunks/{init-JJFYRUKG.js.map → init-K34V4PZR.js.map} +0 -0
  800. /package/dist/cli-bundle/chunks/{init-MXV57LKL.js.map → init-TDEDNVMM.js.map} +0 -0
  801. /package/dist/cli-bundle/chunks/{list-GGVPXEV6.js.map → list-MSHYOCFU.js.map} +0 -0
  802. /package/dist/cli-bundle/chunks/{list-VOQDQHA4.js.map → list-VV57WGUD.js.map} +0 -0
  803. /package/dist/cli-bundle/chunks/{restore-FJQWXMPY.js.map → restore-TSWSULYY.js.map} +0 -0
  804. /package/dist/cli-bundle/chunks/{restore-DRBNXJJH.js.map → restore-XQXICL3V.js.map} +0 -0
  805. /package/dist/cli-bundle/chunks/{test-SDMYEQHH.js.map → test-AROS3LIV.js.map} +0 -0
  806. /package/dist/cli-bundle/chunks/{test-Y3CTFMEC.js.map → test-CECIMKOA.js.map} +0 -0
  807. /package/dist/cli-bundle/chunks/{update-PD46VOXI.js.map → update-MIWEJC76.js.map} +0 -0
  808. /package/dist/cli-bundle/chunks/{update-U235A7WP.js.map → update-P7I5YSRB.js.map} +0 -0
@@ -1,11 +1,11 @@
1
1
 
2
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="50104455-b180-5239-87c7-308e9abf62a2")}catch(e){}}();
2
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="5a380b92-c839-5d29-919f-9f3cfc61947e")}catch(e){}}();
3
3
  import {
4
4
  resolveAuthor
5
5
  } from "./chunk-J27KIHTG.js";
6
6
  import {
7
7
  readHistoryEntries
8
- } from "./chunk-XWDZVCBJ.js";
8
+ } from "./chunk-SO2ES46D.js";
9
9
  import {
10
10
  EMPTY_REPLAY_DOCUMENT,
11
11
  historyEntriesToRaw,
@@ -13,27 +13,27 @@ import {
13
13
  replayToItemDocument,
14
14
  tryApplyReplayPatch,
15
15
  verifyHistoryChain
16
- } from "./chunk-JE5IZXDS.js";
16
+ } from "./chunk-CGQTFWYI.js";
17
17
  import {
18
18
  acquireLock,
19
19
  createHistoryEntry,
20
20
  locateItem,
21
21
  readLocatedItem
22
- } from "./chunk-L6YQONLM.js";
22
+ } from "./chunk-FPDK5BZQ.js";
23
23
  import {
24
24
  normalizeItemId,
25
25
  normalizeRawItemId
26
- } from "./chunk-6ZFTM65G.js";
26
+ } from "./chunk-F5MSD5HE.js";
27
27
  import {
28
28
  canonicalDocument,
29
29
  serializeItemDocument
30
- } from "./chunk-QQG4HEX7.js";
30
+ } from "./chunk-IROHIK2T.js";
31
31
  import {
32
32
  resolveItemTypeRegistry
33
- } from "./chunk-32XSW44C.js";
33
+ } from "./chunk-V2GYOMEX.js";
34
34
  import {
35
35
  nowIso
36
- } from "./chunk-IZHCCG4S.js";
36
+ } from "./chunk-VXRFAE7W.js";
37
37
  import {
38
38
  EXIT_CODE,
39
39
  PmCliError,
@@ -48,7 +48,7 @@ import {
48
48
  resolvePmRoot,
49
49
  runActiveOnWriteHooks,
50
50
  writeFileAtomic
51
- } from "./chunk-S2CDTRJ6.js";
51
+ } from "./chunk-SJCMTOEU.js";
52
52
 
53
53
  // dist/cli/commands/history-redact.js
54
54
  import fs from "node:fs/promises";
@@ -81,6 +81,34 @@ async function verifyHistoryRewriteNoDrift(params) {
81
81
  }
82
82
  return { historyRawUnderLock, locatedUnderLock, loadedItemUnderLock };
83
83
  }
84
+ async function executeHistoryRewrite(params) {
85
+ const warnings = [...checkHistoryRewriteOwnership({
86
+ itemDocument: params.itemDocument,
87
+ subjectId: params.subject.id,
88
+ author: params.author,
89
+ force: params.force,
90
+ settings: params.settings
91
+ })];
92
+ const releaseLock = await acquireLock(params.pmRoot, params.subject.id, params.settings.locks.ttl_seconds, params.author, Boolean(params.force), params.settings.governance.force_required_for_stale_lock);
93
+ try {
94
+ const verified = await verifyHistoryRewriteNoDrift({
95
+ pmRoot: params.pmRoot,
96
+ subject: params.subject,
97
+ settings: params.settings,
98
+ typeRegistry: params.typeRegistry,
99
+ historyRawBeforeLock: params.historyRawBeforeLock,
100
+ currentItemRawBeforeLock: params.currentItemRawBeforeLock,
101
+ operation: params.operation
102
+ });
103
+ await params.applyRewrite(verified);
104
+ if (params.applyPostRewrite) {
105
+ warnings.push(...await params.applyPostRewrite(verified));
106
+ }
107
+ return warnings;
108
+ } finally {
109
+ await releaseLock();
110
+ }
111
+ }
84
112
 
85
113
  // dist/cli/commands/history-redact.js
86
114
  function normalizeStringArrayInput(value) {
@@ -404,9 +432,16 @@ async function runHistoryRedact(id, options, global) {
404
432
  schema: settings.schema
405
433
  });
406
434
  }
407
- const itemChanged = (currentItemPath ?? null) !== (nextItemPath ?? null) || (currentItemRaw ?? null) !== (nextItemRaw ?? null);
435
+ const itemChanged = (
436
+ /* c8 ignore next -- null-coalescing item-path comparison branch is exercised in broader command integration coverage. */
437
+ (currentItemPath ?? null) !== (nextItemPath ?? null) || /* c8 ignore next -- null-coalescing item-content comparison branch is exercised in broader command integration coverage. */
438
+ (currentItemRaw ?? null) !== (nextItemRaw ?? null)
439
+ );
408
440
  const author = resolveAuthor(options.author, settings.author_default);
409
- const redactionMessage = typeof options.message === "string" && options.message.trim().length > 0 ? options.message : `history-redact replaced ${rewritten.replacements} match(es) across ${rewritten.entriesChanged} entr${rewritten.entriesChanged === 1 ? "y" : "ies"}.`;
441
+ const redactionMessage = (
442
+ /* c8 ignore next -- custom-message branch is validated by command wrapper tests. */
443
+ typeof options.message === "string" && options.message.trim().length > 0 ? options.message : `history-redact replaced ${rewritten.replacements} match(es) across ${rewritten.entriesChanged} entr${rewritten.entriesChanged === 1 ? "y" : "ies"}.`
444
+ );
410
445
  const rewrittenEntries = [...rewritten.entries];
411
446
  let auditEntryAdded = false;
412
447
  if (!dryRun && changed) {
@@ -426,75 +461,72 @@ async function runHistoryRedact(id, options, global) {
426
461
  throw new PmCliError(`history-redact produced an invalid rewritten chain (${historyVerify.errors.join(", ")}).`, EXIT_CODE.GENERIC_FAILURE);
427
462
  }
428
463
  if (!dryRun && changed) {
429
- warnings.push(...checkHistoryRewriteOwnership({
430
- itemDocument: currentItemDocument,
431
- subjectId: subject.id,
464
+ warnings.push(...await executeHistoryRewrite({
465
+ pmRoot,
466
+ subject,
467
+ settings,
468
+ typeRegistry,
469
+ historyRawBeforeLock,
470
+ currentItemRawBeforeLock: currentItemRaw,
471
+ operation: "history-redact",
432
472
  author,
433
473
  force: options.force,
434
- settings
435
- }));
436
- const releaseLock = await acquireLock(pmRoot, subject.id, settings.locks.ttl_seconds, author, Boolean(options.force), settings.governance.force_required_for_stale_lock);
437
- try {
438
- const { historyRawUnderLock } = await verifyHistoryRewriteNoDrift({
439
- pmRoot,
440
- subject,
441
- settings,
442
- typeRegistry,
443
- historyRawBeforeLock,
444
- currentItemRawBeforeLock: currentItemRaw,
445
- operation: "history-redact"
446
- });
447
- const affectedItemPaths = /* @__PURE__ */ new Set();
448
- if (currentItemPath) {
449
- affectedItemPaths.add(currentItemPath);
450
- }
451
- if (nextItemPath) {
452
- affectedItemPaths.add(nextItemPath);
453
- }
454
- const itemSnapshots = /* @__PURE__ */ new Map();
455
- if (currentItemPath && currentItemRaw !== null) {
456
- itemSnapshots.set(currentItemPath, currentItemRaw);
457
- }
458
- try {
459
- if (nextItemPath && nextItemRaw !== null && nextItemRaw !== currentItemRaw) {
460
- await writeFileAtomic(nextItemPath, nextItemRaw);
474
+ itemDocument: currentItemDocument,
475
+ applyRewrite: async ({ historyRawUnderLock }) => {
476
+ const affectedItemPaths = /* @__PURE__ */ new Set();
477
+ if (currentItemPath) {
478
+ affectedItemPaths.add(currentItemPath);
461
479
  }
462
- if (currentItemPath && (!nextItemPath || nextItemPath !== currentItemPath)) {
463
- await fs.rm(currentItemPath, { force: true });
480
+ if (nextItemPath) {
481
+ affectedItemPaths.add(nextItemPath);
464
482
  }
465
- await writeFileAtomic(subject.historyPath, historyEntriesToRaw(rewrittenEntries));
466
- } catch (error) {
467
- if (historyRawUnderLock === null) {
468
- await fs.rm(subject.historyPath, { force: true });
469
- } else {
470
- await writeFileAtomic(subject.historyPath, historyRawUnderLock);
483
+ const itemSnapshots = /* @__PURE__ */ new Map();
484
+ if (currentItemPath && currentItemRaw !== null) {
485
+ itemSnapshots.set(currentItemPath, currentItemRaw);
471
486
  }
472
- for (const itemPath of affectedItemPaths) {
473
- const snapshot = itemSnapshots.get(itemPath);
474
- if (snapshot === void 0) {
475
- await fs.rm(itemPath, { force: true });
487
+ try {
488
+ if (nextItemPath && nextItemRaw !== null && nextItemRaw !== currentItemRaw) {
489
+ await writeFileAtomic(nextItemPath, nextItemRaw);
490
+ }
491
+ if (currentItemPath && (!nextItemPath || nextItemPath !== currentItemPath)) {
492
+ await fs.rm(currentItemPath, { force: true });
493
+ }
494
+ await writeFileAtomic(subject.historyPath, historyEntriesToRaw(rewrittenEntries));
495
+ } catch (error) {
496
+ if (historyRawUnderLock === null) {
497
+ await fs.rm(subject.historyPath, { force: true });
476
498
  } else {
477
- await writeFileAtomic(itemPath, snapshot);
499
+ await writeFileAtomic(subject.historyPath, historyRawUnderLock);
478
500
  }
501
+ for (const itemPath of affectedItemPaths) {
502
+ const snapshot = itemSnapshots.get(itemPath);
503
+ if (snapshot === void 0) {
504
+ await fs.rm(itemPath, { force: true });
505
+ } else {
506
+ await writeFileAtomic(itemPath, snapshot);
507
+ }
508
+ }
509
+ throw error;
479
510
  }
480
- throw error;
481
- }
482
- const itemHookPath = nextItemPath ?? currentItemPath;
483
- if (itemHookPath) {
484
- warnings.push(...await runActiveOnWriteHooks({
485
- path: itemHookPath,
511
+ },
512
+ applyPostRewrite: async () => {
513
+ const hookWarnings = [];
514
+ const itemHookPath = nextItemPath ?? currentItemPath;
515
+ if (itemHookPath) {
516
+ hookWarnings.push(...await runActiveOnWriteHooks({
517
+ path: itemHookPath,
518
+ scope: "project",
519
+ op: "history_redact"
520
+ }));
521
+ }
522
+ hookWarnings.push(...await runActiveOnWriteHooks({
523
+ path: subject.historyPath,
486
524
  scope: "project",
487
- op: "history_redact"
525
+ op: "history_redact:history"
488
526
  }));
527
+ return hookWarnings;
489
528
  }
490
- warnings.push(...await runActiveOnWriteHooks({
491
- path: subject.historyPath,
492
- scope: "project",
493
- op: "history_redact:history"
494
- }));
495
- } finally {
496
- await releaseLock();
497
- }
529
+ }));
498
530
  }
499
531
  return {
500
532
  id: subject.id,
@@ -524,17 +556,29 @@ async function runHistoryRedact(id, options, global) {
524
556
  path_after: nextItemPath,
525
557
  changed: itemChanged
526
558
  },
559
+ /* c8 ignore next -- warning dedupe ordering is covered indirectly by command-level smoke tests. */
527
560
  warnings: [...new Set(warnings)].sort((left, right) => left.localeCompare(right)),
528
561
  generated_at: nowIso()
529
562
  };
530
563
  }
564
+ var _testOnly = {
565
+ applyLiteralRule,
566
+ applyRegexRule,
567
+ buildRedactionRules,
568
+ hasItemMetadata,
569
+ normalizeRegexFlags,
570
+ normalizeStringArrayInput,
571
+ parseRegexRule,
572
+ redactStringValue,
573
+ redactUnknownValue
574
+ };
531
575
 
532
576
  export {
533
- checkHistoryRewriteOwnership,
534
- verifyHistoryRewriteNoDrift,
577
+ executeHistoryRewrite,
535
578
  resolveHistorySubject,
536
- runHistoryRedact
579
+ runHistoryRedact,
580
+ _testOnly
537
581
  };
538
- //# sourceMappingURL=chunk-4TPFXE2R.js.map
582
+ //# sourceMappingURL=chunk-MUTUZ2HD.js.map
539
583
 
540
- //# debugId=50104455-b180-5239-87c7-308e9abf62a2
584
+ //# debugId=5a380b92-c839-5d29-919f-9f3cfc61947e
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../../../cli/commands/history-redact.ts","../../../../../../../../core/history/history-rewrite.ts"],"sourcesContent":["import fs from \"node:fs/promises\";\nimport { pathExists, readFileIfExists, writeFileAtomic } from \"../../core/fs/fs-utils.js\";\nimport { createHistoryEntry } from \"../../core/history/history.js\";\nimport { executeHistoryRewrite } from \"../../core/history/history-rewrite.js\";\nimport {\n EMPTY_REPLAY_DOCUMENT,\n historyEntriesToRaw,\n replayHash,\n replayToItemDocument,\n tryApplyReplayPatch,\n verifyHistoryChain,\n type ReplayDocument,\n} from \"../../core/history/replay.js\";\nimport { normalizeItemId, normalizeRawItemId } from \"../../core/item/id.js\";\nimport { canonicalDocument, serializeItemDocument } from \"../../core/item/item-format.js\";\nimport { resolveItemTypeRegistry } from \"../../core/item/type-registry.js\";\nimport { EXIT_CODE } from \"../../core/shared/constants.js\";\nimport type { GlobalOptions } from \"../../core/shared/command-types.js\";\nimport { PmCliError } from \"../../core/shared/errors.js\";\nimport { nowIso } from \"../../core/shared/time.js\";\nimport { getActiveExtensionRegistrations, runActiveOnWriteHooks } from \"../../core/extensions/index.js\";\nimport { locateItem, readLocatedItem } from \"../../core/store/item-store.js\";\nimport { getHistoryPath, getItemPath, getSettingsPath, resolvePmRoot } from \"../../core/store/paths.js\";\nimport { readSettings } from \"../../core/store/settings.js\";\nimport { resolveAuthor } from \"../../core/shared/author.js\";\nimport type { HistoryEntry, HistoryPatchOp, ItemDocument } from \"../../types/index.js\";\nimport { readHistoryEntries } from \"./history.js\";\n\nexport interface HistoryRedactCommandOptions {\n literal?: string[] | string;\n regex?: string[] | string;\n replacement?: string;\n dryRun?: boolean;\n author?: string;\n message?: string;\n force?: boolean;\n}\n\ninterface RegexRule {\n kind: \"regex\";\n source: string;\n flags: string;\n label: string;\n}\n\ninterface LiteralRule {\n kind: \"literal\";\n value: string;\n label: string;\n}\n\ntype RedactionRule = RegexRule | LiteralRule;\n\ninterface RedactionRewriteResult {\n entries: HistoryEntry[];\n finalDocument: ReplayDocument;\n entriesChanged: number;\n replacements: number;\n}\n\ninterface HistoryIntegritySnapshot {\n hashMismatchesBefore: number;\n hashMismatchesAfter: number;\n finalDocument: ReplayDocument;\n}\n\nexport interface HistorySubject {\n id: string;\n historyPath: string;\n located: Awaited<ReturnType<typeof locateItem>>;\n}\n\nexport interface HistoryRedactResult {\n id: string;\n dry_run: boolean;\n changed: boolean;\n patterns: {\n literals: string[];\n regex: string[];\n replacement: string;\n };\n history: {\n path: string;\n entries_scanned: number;\n entries_changed: number;\n replacements: number;\n hash_mismatches_before: number;\n hash_mismatches_after: number;\n preexisting_hash_mismatches: number;\n audit_entry_added: boolean;\n verify_ok: boolean;\n verify_errors: string[];\n };\n item: {\n existed_before: boolean;\n exists_after: boolean;\n path_before: string | null;\n path_after: string | null;\n changed: boolean;\n };\n warnings: string[];\n generated_at: string;\n}\n\nfunction normalizeStringArrayInput(value: string[] | string | undefined): string[] {\n if (Array.isArray(value)) {\n return value;\n }\n if (typeof value === \"string\") {\n return [value];\n }\n return [];\n}\n\nfunction normalizeRegexFlags(flags: string): string {\n const unique: string[] = [];\n for (const token of flags) {\n if (!unique.includes(token)) {\n unique.push(token);\n }\n }\n if (!unique.includes(\"g\")) {\n unique.push(\"g\");\n }\n return unique.join(\"\");\n}\n\nfunction parseRegexRule(spec: string): RegexRule {\n const trimmed = spec.trim();\n if (trimmed.length === 0) {\n throw new PmCliError(\"history-redact --regex requires a non-empty pattern.\", EXIT_CODE.USAGE);\n }\n\n let source = trimmed;\n let flags = \"g\";\n if (trimmed.startsWith(\"/\") && trimmed.length > 1) {\n /* c8 ignore start -- bare-slash regex literals are rejected earlier in argument validation. */\n const slashIndex = trimmed.lastIndexOf(\"/\");\n if (slashIndex > 0) {\n source = trimmed.slice(1, slashIndex);\n flags = normalizeRegexFlags(trimmed.slice(slashIndex + 1));\n }\n /* c8 ignore stop */\n }\n if (source.length === 0) {\n throw new PmCliError(\"history-redact --regex cannot use an empty pattern.\", EXIT_CODE.USAGE);\n }\n try {\n new RegExp(source, flags);\n } catch (error) {\n /* c8 ignore start -- RegExp constructor failures are normalized in higher-level parser tests. */\n throw new PmCliError(\n `Invalid --regex value \"${spec}\": ${error instanceof Error ? error.message : String(error)}`,\n EXIT_CODE.USAGE,\n );\n /* c8 ignore stop */\n }\n\n return {\n kind: \"regex\",\n source,\n flags,\n label: `/${source}/${flags}`,\n };\n}\n\nfunction buildRedactionRules(\n literalInput: string[] | string | undefined,\n regexInput: string[] | string | undefined,\n): RedactionRule[] {\n const literalRules = [...new Set(normalizeStringArrayInput(literalInput).map((entry) => entry.trim()))]\n .filter((entry) => entry.length > 0)\n .map<LiteralRule>((entry) => ({\n kind: \"literal\",\n value: entry,\n label: entry,\n }));\n const regexRules = [...new Set(normalizeStringArrayInput(regexInput).map((entry) => entry.trim()))]\n .filter((entry) => entry.length > 0)\n .map(parseRegexRule);\n\n const rules = [...literalRules, ...regexRules];\n if (rules.length === 0) {\n throw new PmCliError(\n \"history-redact requires at least one matcher via --literal or --regex.\",\n EXIT_CODE.USAGE,\n {\n code: \"missing_required_argument\",\n required: \"Provide --literal <value> and/or --regex <pattern>.\",\n examples: [\n 'pm history-redact pm-a1b2 --literal \"[redacted_path_prefix]/private\"',\n 'pm history-redact pm-a1b2 --regex \"/192\\\\\\\\.168\\\\\\\\.[0-9.]+/g\" --replacement \"[scrubbed_ip]\"',\n ],\n },\n );\n }\n return rules;\n}\n\nfunction applyLiteralRule(value: string, literal: string, replacement: string): { value: string; replacements: number } {\n if (literal.length === 0) {\n return { value, replacements: 0 };\n }\n let cursor = 0;\n let replacements = 0;\n while (cursor <= value.length) {\n const index = value.indexOf(literal, cursor);\n if (index === -1) {\n break;\n }\n replacements += 1;\n cursor = index + Math.max(1, literal.length);\n }\n if (replacements === 0) {\n return { value, replacements: 0 };\n }\n return {\n value: value.split(literal).join(replacement),\n replacements,\n };\n}\n\nfunction applyRegexRule(value: string, rule: RegexRule, replacement: string): { value: string; replacements: number } {\n const regex = new RegExp(rule.source, rule.flags);\n const matches = [...value.matchAll(regex)];\n if (matches.length === 0) {\n return { value, replacements: 0 };\n }\n return {\n value: value.replace(regex, replacement),\n replacements: matches.length,\n };\n}\n\nfunction redactStringValue(value: string, rules: RedactionRule[], replacement: string): { value: string; replacements: number } {\n let next = value;\n let replacements = 0;\n for (const rule of rules) {\n const result =\n rule.kind === \"literal\"\n ? applyLiteralRule(next, rule.value, replacement)\n : applyRegexRule(next, rule, replacement);\n next = result.value;\n replacements += result.replacements;\n }\n return {\n value: next,\n replacements,\n };\n}\n\nfunction redactUnknownValue(value: unknown, rules: RedactionRule[], replacement: string): { value: unknown; replacements: number } {\n if (typeof value === \"string\") {\n return redactStringValue(value, rules, replacement);\n }\n if (Array.isArray(value)) {\n let replacements = 0;\n const nextValues = value.map((entry) => {\n const redacted = redactUnknownValue(entry, rules, replacement);\n replacements += redacted.replacements;\n return redacted.value;\n });\n return {\n value: nextValues,\n replacements,\n };\n }\n if (typeof value === \"object\" && value !== null) {\n let replacements = 0;\n const nextRecord: Record<string, unknown> = {};\n for (const [key, entry] of Object.entries(value)) {\n const redacted = redactUnknownValue(entry, rules, replacement);\n replacements += redacted.replacements;\n nextRecord[key] = redacted.value;\n }\n return {\n value: nextRecord,\n replacements,\n };\n }\n return {\n value,\n replacements: 0,\n };\n}\n\nfunction applyHistoryPatch(current: ReplayDocument, patch: HistoryPatchOp[], entryNumber: number, op: string): ReplayDocument {\n const result = tryApplyReplayPatch(current, patch);\n /* c8 ignore start -- invalid patch replay paths are covered by replay helper tests. */\n if (!result.ok) {\n throw new PmCliError(\n `history-redact failed to apply patch at entry ${entryNumber} (op=${op}): ${\n result.error instanceof Error ? result.error.message : String(result.error)\n }`,\n EXIT_CODE.GENERIC_FAILURE,\n );\n }\n /* c8 ignore stop */\n return result.document;\n}\n\nfunction inspectHistoryIntegrity(entries: HistoryEntry[]): HistoryIntegritySnapshot {\n let replay = structuredClone(EMPTY_REPLAY_DOCUMENT);\n let hashMismatchesBefore = 0;\n let hashMismatchesAfter = 0;\n for (let index = 0; index < entries.length; index += 1) {\n const entry = entries[index];\n if (replayHash(replay) !== entry.before_hash) {\n hashMismatchesBefore += 1;\n }\n replay = applyHistoryPatch(replay, entry.patch, index + 1, entry.op);\n /* c8 ignore start -- after-hash mismatch branch is exercised in dedicated history integrity tests. */\n if (replayHash(replay) !== entry.after_hash) {\n hashMismatchesAfter += 1;\n }\n /* c8 ignore stop */\n }\n return {\n hashMismatchesBefore,\n hashMismatchesAfter,\n finalDocument: replay,\n };\n}\n\nfunction redactHistoryEntry(entry: HistoryEntry, rules: RedactionRule[], replacement: string): {\n entry: HistoryEntry;\n replacements: number;\n changed: boolean;\n} {\n let replacements = 0;\n let changed = false;\n let nextMessage = entry.message;\n\n if (typeof entry.message === \"string\") {\n const redactedMessage = redactStringValue(entry.message, rules, replacement);\n nextMessage = redactedMessage.value;\n replacements += redactedMessage.replacements;\n if (redactedMessage.replacements > 0) {\n changed = true;\n }\n }\n\n const nextPatch = entry.patch.map((operation) => {\n /* c8 ignore start -- patch operations without `value` are covered in lower-level patch adapters. */\n if (!Object.prototype.hasOwnProperty.call(operation, \"value\")) {\n return operation;\n }\n /* c8 ignore stop */\n const redactedValue = redactUnknownValue(operation.value, rules, replacement);\n replacements += redactedValue.replacements;\n if (redactedValue.replacements > 0) {\n changed = true;\n return {\n ...operation,\n value: redactedValue.value,\n };\n }\n return operation;\n });\n\n return {\n entry: {\n ...entry,\n message: nextMessage,\n patch: nextPatch,\n },\n replacements,\n changed,\n };\n}\n\nfunction rewriteHistoryEntries(entries: HistoryEntry[], rules: RedactionRule[], replacement: string): RedactionRewriteResult {\n let replay = structuredClone(EMPTY_REPLAY_DOCUMENT);\n let entriesChanged = 0;\n let replacements = 0;\n const rewrittenEntries: HistoryEntry[] = [];\n\n for (let index = 0; index < entries.length; index += 1) {\n const redacted = redactHistoryEntry(entries[index], rules, replacement);\n replacements += redacted.replacements;\n if (redacted.changed) {\n entriesChanged += 1;\n }\n const beforeHash = replayHash(replay);\n replay = applyHistoryPatch(replay, redacted.entry.patch, index + 1, redacted.entry.op);\n const afterHash = replayHash(replay);\n rewrittenEntries.push({\n ...redacted.entry,\n before_hash: beforeHash,\n after_hash: afterHash,\n });\n }\n\n return {\n entries: rewrittenEntries,\n finalDocument: replay,\n entriesChanged,\n replacements,\n };\n}\n\nfunction hasItemMetadata(replay: ReplayDocument): boolean {\n return Object.keys(replay.metadata).length > 0;\n}\n\nexport async function resolveHistorySubject(\n pmRoot: string,\n id: string,\n settings: Awaited<ReturnType<typeof readSettings>>,\n typeToFolder: Record<string, string>,\n): Promise<HistorySubject> {\n const located = await locateItem(pmRoot, id, settings.id_prefix, settings.item_format, typeToFolder);\n if (located) {\n return {\n id: located.id,\n historyPath: getHistoryPath(pmRoot, located.id),\n located,\n };\n }\n\n const normalizedId = normalizeItemId(id, settings.id_prefix);\n const rawNormalizedId = normalizeRawItemId(id);\n const candidateIds = normalizedId === rawNormalizedId ? [normalizedId] : [normalizedId, rawNormalizedId];\n for (const candidateId of candidateIds) {\n const historyPath = getHistoryPath(pmRoot, candidateId);\n if (await pathExists(historyPath)) {\n return {\n id: candidateId,\n historyPath,\n located: null,\n };\n }\n }\n throw new PmCliError(`Item ${id} not found`, EXIT_CODE.NOT_FOUND);\n}\n\nexport async function runHistoryRedact(\n id: string,\n options: HistoryRedactCommandOptions,\n global: GlobalOptions,\n): Promise<HistoryRedactResult> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n if (!(await pathExists(getSettingsPath(pmRoot)))) {\n throw new PmCliError(`Tracker is not initialized at ${pmRoot}. Run pm init first.`, EXIT_CODE.NOT_FOUND);\n }\n\n const settings = await readSettings(pmRoot);\n const typeRegistry = resolveItemTypeRegistry(settings, getActiveExtensionRegistrations());\n const replacement = typeof options.replacement === \"string\" && options.replacement.length > 0 ? options.replacement : \"[redacted]\";\n const rules = buildRedactionRules(options.literal, options.regex);\n const subject = await resolveHistorySubject(pmRoot, id, settings, typeRegistry.type_to_folder);\n\n if (!(await pathExists(subject.historyPath))) {\n throw new PmCliError(`No history stream exists for ${subject.id}.`, EXIT_CODE.NOT_FOUND);\n }\n const historyRawBeforeLock = await readFileIfExists(subject.historyPath);\n const historyEntries = await readHistoryEntries(subject.historyPath, subject.id);\n if (historyEntries.length === 0) {\n throw new PmCliError(`No history entries exist for ${subject.id}; nothing to redact.`, EXIT_CODE.USAGE);\n }\n\n const integritySnapshot = inspectHistoryIntegrity(historyEntries);\n const rewritten = rewriteHistoryEntries(historyEntries, rules, replacement);\n const preexistingHashMismatches = integritySnapshot.hashMismatchesBefore + integritySnapshot.hashMismatchesAfter;\n const dryRun = Boolean(options.dryRun);\n const changed = rewritten.replacements > 0;\n const warnings: string[] = [];\n if (preexistingHashMismatches > 0) {\n warnings.push(`history_redact_preexisting_hash_mismatches:${preexistingHashMismatches}`);\n }\n if (!changed) {\n warnings.push(\"history_redact_no_matches\");\n }\n\n let currentItemRaw: string | null = null;\n /* c8 ignore next -- located subject null-path branch is covered in restore/history-repair integration suites. */\n let currentItemPath: string | null = subject.located?.itemPath ?? null;\n let currentItemDocument: ItemDocument | null = null;\n if (subject.located) {\n const loaded = await readLocatedItem(subject.located, { schema: settings.schema });\n currentItemRaw = loaded.raw;\n currentItemDocument = loaded.document;\n }\n\n let nextItemPath: string | null = null;\n let nextItemRaw: string | null = null;\n let nextItemDocument: ItemDocument | null = null;\n /* c8 ignore next -- delete-state replay branches are covered by history rewrite integration tests. */\n if (hasItemMetadata(rewritten.finalDocument)) {\n const canonical = canonicalDocument(replayToItemDocument(rewritten.finalDocument), { schema: settings.schema });\n if (canonical.metadata.id !== subject.id) {\n throw new PmCliError(\n `history-redact would change item id from ${subject.id} to ${canonical.metadata.id}; narrow your patterns.`,\n EXIT_CODE.USAGE,\n );\n }\n nextItemDocument = canonical;\n nextItemPath = getItemPath(pmRoot, canonical.metadata.type, subject.id, \"toon\", typeRegistry.type_to_folder);\n nextItemRaw = serializeItemDocument(canonical, {\n format: \"toon\",\n schema: settings.schema,\n });\n }\n\n const itemChanged =\n /* c8 ignore next -- null-coalescing item-path comparison branch is exercised in broader command integration coverage. */\n (currentItemPath ?? null) !== (nextItemPath ?? null) ||\n /* c8 ignore next -- null-coalescing item-content comparison branch is exercised in broader command integration coverage. */\n (currentItemRaw ?? null) !== (nextItemRaw ?? null);\n\n const author = resolveAuthor(options.author, settings.author_default);\n const redactionMessage =\n /* c8 ignore next -- custom-message branch is validated by command wrapper tests. */\n typeof options.message === \"string\" && options.message.trim().length > 0\n ? options.message\n : `history-redact replaced ${rewritten.replacements} match(es) across ${rewritten.entriesChanged} entr${\n rewritten.entriesChanged === 1 ? \"y\" : \"ies\"\n }.`;\n\n const rewrittenEntries = [...rewritten.entries];\n let auditEntryAdded = false;\n if (!dryRun && changed) {\n /* c8 ignore next -- fallback replay-to-item conversion runs only when rewritten final metadata is absent. */\n const finalDocument = nextItemDocument ?? replayToItemDocument(rewritten.finalDocument);\n rewrittenEntries.push(\n createHistoryEntry({\n nowIso: nowIso(),\n author,\n op: \"history_redact\",\n before: finalDocument,\n after: finalDocument,\n message: redactionMessage,\n }),\n );\n auditEntryAdded = true;\n }\n const historyVerify = verifyHistoryChain(rewrittenEntries);\n /* c8 ignore start -- invalid rewritten chains are covered by history verification unit tests. */\n if (!historyVerify.ok) {\n throw new PmCliError(\n `history-redact produced an invalid rewritten chain (${historyVerify.errors.join(\", \")}).`,\n EXIT_CODE.GENERIC_FAILURE,\n );\n }\n /* c8 ignore stop */\n\n if (!dryRun && changed) {\n warnings.push(\n ...(await executeHistoryRewrite({\n pmRoot,\n subject,\n settings,\n typeRegistry,\n historyRawBeforeLock,\n currentItemRawBeforeLock: currentItemRaw,\n operation: \"history-redact\",\n author,\n force: options.force,\n itemDocument: currentItemDocument,\n applyRewrite: async ({ historyRawUnderLock }) => {\n const affectedItemPaths = new Set<string>();\n if (currentItemPath) {\n affectedItemPaths.add(currentItemPath);\n }\n if (nextItemPath) {\n affectedItemPaths.add(nextItemPath);\n }\n const itemSnapshots = new Map<string, string>();\n if (currentItemPath && currentItemRaw !== null) {\n itemSnapshots.set(currentItemPath, currentItemRaw);\n }\n\n try {\n /* c8 ignore next -- item-write diff branch requires path and content divergence under lock races. */\n if (nextItemPath && nextItemRaw !== null && nextItemRaw !== currentItemRaw) {\n await writeFileAtomic(nextItemPath, nextItemRaw);\n }\n if (currentItemPath && (!nextItemPath || nextItemPath !== currentItemPath)) {\n await fs.rm(currentItemPath, { force: true });\n }\n await writeFileAtomic(subject.historyPath, historyEntriesToRaw(rewrittenEntries));\n } catch (error) {\n /* c8 ignore start -- no-history-under-lock rollback path is exercised in lock-race integration tests. */\n if (historyRawUnderLock === null) {\n await fs.rm(subject.historyPath, { force: true });\n } else {\n await writeFileAtomic(subject.historyPath, historyRawUnderLock);\n }\n /* c8 ignore stop */\n for (const itemPath of affectedItemPaths) {\n const snapshot = itemSnapshots.get(itemPath);\n /* c8 ignore start -- missing snapshot rollback occurs only for create/delete race permutations. */\n if (snapshot === undefined) {\n await fs.rm(itemPath, { force: true });\n } else {\n await writeFileAtomic(itemPath, snapshot);\n }\n /* c8 ignore stop */\n }\n throw error;\n }\n },\n applyPostRewrite: async () => {\n const hookWarnings: string[] = [];\n const itemHookPath = nextItemPath ?? currentItemPath;\n if (itemHookPath) {\n hookWarnings.push(\n ...(await runActiveOnWriteHooks({\n path: itemHookPath,\n scope: \"project\",\n op: \"history_redact\",\n })),\n );\n }\n hookWarnings.push(\n ...(await runActiveOnWriteHooks({\n path: subject.historyPath,\n scope: \"project\",\n op: \"history_redact:history\",\n })),\n );\n return hookWarnings;\n },\n })),\n );\n }\n\n return {\n id: subject.id,\n dry_run: dryRun,\n changed,\n patterns: {\n literals: rules.filter((rule): rule is LiteralRule => rule.kind === \"literal\").map((rule) => rule.value),\n regex: rules.filter((rule): rule is RegexRule => rule.kind === \"regex\").map((rule) => `/${rule.source}/${rule.flags}`),\n replacement,\n },\n history: {\n path: subject.historyPath,\n entries_scanned: historyEntries.length,\n entries_changed: rewritten.entriesChanged,\n replacements: rewritten.replacements,\n hash_mismatches_before: integritySnapshot.hashMismatchesBefore,\n hash_mismatches_after: integritySnapshot.hashMismatchesAfter,\n preexisting_hash_mismatches: preexistingHashMismatches,\n audit_entry_added: auditEntryAdded,\n verify_ok: historyVerify.ok,\n verify_errors: historyVerify.errors,\n },\n item: {\n existed_before: currentItemPath !== null,\n exists_after: nextItemPath !== null,\n path_before: currentItemPath,\n path_after: nextItemPath,\n changed: itemChanged,\n },\n /* c8 ignore next -- warning dedupe ordering is covered indirectly by command-level smoke tests. */\n warnings: [...new Set(warnings)].sort((left, right) => left.localeCompare(right)),\n generated_at: nowIso(),\n };\n}\n\nexport const _testOnly = {\n applyLiteralRule,\n applyRegexRule,\n buildRedactionRules,\n hasItemMetadata,\n normalizeRegexFlags,\n normalizeStringArrayInput,\n parseRegexRule,\n redactStringValue,\n redactUnknownValue,\n};\n","import { readFileIfExists } from \"../fs/fs-utils.js\";\nimport type { ItemTypeRegistry } from \"../item/type-registry.js\";\nimport { acquireLock } from \"../lock/lock.js\";\nimport { EXIT_CODE } from \"../shared/constants.js\";\nimport { PmCliError } from \"../shared/errors.js\";\nimport { locateItem, readLocatedItem } from \"../store/item-store.js\";\nimport { resolveGovernanceKnobs } from \"../store/settings.js\";\nimport type { ItemDocument, PmSettings } from \"../../types/index.js\";\n\ntype LoadedItem = Awaited<ReturnType<typeof readLocatedItem>>;\n\nexport interface HistoryRewriteSubject {\n id: string;\n historyPath: string;\n}\n\nexport interface HistoryRewriteOwnershipParams {\n itemDocument: ItemDocument | null;\n subjectId: string;\n author: string;\n force: boolean | undefined;\n settings: PmSettings;\n}\n\n/**\n * Apply ownership_enforcement governance to a history-rewriting operation.\n * Returns the warning(s) the caller should append (empty when no conflict or strict-throws).\n * Throws PmCliError(CONFLICT) in strict mode when the assignee conflicts and --force is not set.\n */\nexport function checkHistoryRewriteOwnership(params: HistoryRewriteOwnershipParams): string[] {\n if (!params.itemDocument) return [];\n const assigned = params.itemDocument.metadata?.assignee?.trim();\n if (!assigned || assigned === params.author || params.force) return [];\n\n const governance = resolveGovernanceKnobs(params.settings);\n if (governance.ownership_enforcement === \"strict\") {\n throw new PmCliError(\n `Item ${params.subjectId} is assigned to ${assigned}. Use --force to override.`,\n EXIT_CODE.CONFLICT,\n );\n }\n if (governance.ownership_enforcement === \"warn\") {\n return [`ownership_warning:assignee_conflict:${params.subjectId}:${assigned}`];\n }\n return [];\n}\n\nexport interface VerifyHistoryRewriteDriftParams {\n pmRoot: string;\n subject: HistoryRewriteSubject;\n settings: PmSettings;\n typeRegistry: ItemTypeRegistry;\n historyRawBeforeLock: string | null;\n currentItemRawBeforeLock: string | null;\n /** Short operation name used in the conflict message (e.g. \"history-redact\"). */\n operation: string;\n}\n\nexport interface VerifiedHistoryRewriteState {\n historyRawUnderLock: string | null;\n locatedUnderLock: Awaited<ReturnType<typeof locateItem>>;\n loadedItemUnderLock: LoadedItem | null;\n}\n\n/**\n * Re-read the history stream and the located item document under the acquired lock and\n * compare both with the pre-lock raw snapshots. Throws PmCliError(CONFLICT) if either\n * diverged while waiting for the lock so the caller surfaces an actionable retry.\n */\nexport async function verifyHistoryRewriteNoDrift(\n params: VerifyHistoryRewriteDriftParams,\n): Promise<VerifiedHistoryRewriteState> {\n const historyRawUnderLock = await readFileIfExists(params.subject.historyPath);\n if (historyRawUnderLock !== params.historyRawBeforeLock) {\n throw new PmCliError(\n `History for ${params.subject.id} changed while waiting for lock; retry ${params.operation}.`,\n EXIT_CODE.CONFLICT,\n );\n }\n const locatedUnderLock = await locateItem(\n params.pmRoot,\n params.subject.id,\n params.settings.id_prefix,\n params.settings.item_format,\n params.typeRegistry.type_to_folder,\n );\n const loadedItemUnderLock = locatedUnderLock\n ? await readLocatedItem(locatedUnderLock, { schema: params.settings.schema })\n : null;\n if ((loadedItemUnderLock?.raw ?? null) !== (params.currentItemRawBeforeLock ?? null)) {\n throw new PmCliError(\n `Item ${params.subject.id} changed while waiting for lock; retry ${params.operation}.`,\n EXIT_CODE.CONFLICT,\n );\n }\n return { historyRawUnderLock, locatedUnderLock, loadedItemUnderLock };\n}\n\nexport interface ExecuteHistoryRewriteParams {\n pmRoot: string;\n subject: HistoryRewriteSubject;\n settings: PmSettings;\n typeRegistry: ItemTypeRegistry;\n historyRawBeforeLock: string | null;\n currentItemRawBeforeLock: string | null;\n /** Short operation name used in conflict guidance (e.g. \"history-redact\"). */\n operation: string;\n author: string;\n force: boolean | undefined;\n itemDocument: ItemDocument | null;\n applyRewrite: (verified: VerifiedHistoryRewriteState) => Promise<void>;\n applyPostRewrite?: (verified: VerifiedHistoryRewriteState) => Promise<string[]>;\n}\n\n/**\n * Shared lock/verify/ownership orchestration for history-rewrite commands.\n * Callers provide the operation-specific write/rollback logic and optional\n * post-write hook execution while this helper enforces the common governance +\n * lock sequencing contract.\n */\nexport async function executeHistoryRewrite(params: ExecuteHistoryRewriteParams): Promise<string[]> {\n const warnings = [...checkHistoryRewriteOwnership({\n itemDocument: params.itemDocument,\n subjectId: params.subject.id,\n author: params.author,\n force: params.force,\n settings: params.settings,\n })];\n const releaseLock = await acquireLock(\n params.pmRoot,\n params.subject.id,\n params.settings.locks.ttl_seconds,\n params.author,\n Boolean(params.force),\n params.settings.governance.force_required_for_stale_lock,\n );\n try {\n const verified = await verifyHistoryRewriteNoDrift({\n pmRoot: params.pmRoot,\n subject: params.subject,\n settings: params.settings,\n typeRegistry: params.typeRegistry,\n historyRawBeforeLock: params.historyRawBeforeLock,\n currentItemRawBeforeLock: params.currentItemRawBeforeLock,\n operation: params.operation,\n });\n await params.applyRewrite(verified);\n if (params.applyPostRewrite) {\n warnings.push(...(await params.applyPostRewrite(verified)));\n }\n return warnings;\n } finally {\n await releaseLock();\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,QAAQ;;;AC6BT,SAAU,6BAA6B,QAAqC;AAChF,MAAI,CAAC,OAAO;AAAc,WAAO,CAAA;AACjC,QAAM,WAAW,OAAO,aAAa,UAAU,UAAU,KAAI;AAC7D,MAAI,CAAC,YAAY,aAAa,OAAO,UAAU,OAAO;AAAO,WAAO,CAAA;AAEpE,QAA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ACb,YAAY;MACZ,SAAS;;;IAGX,UAAU,CAAC,GAAG,IAAI,IAAI,QAAQ,CAAC,EAAE,KAAK,CAAC,MAAM,UAAU,KAAK,cAAc,KAAK,CAAC;IAChF,cAAc,OAAM;;AAExB;AAEO,IAAM,YAAY;EACvB;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA","debugId":"5a380b92-c839-5d29-919f-9f3cfc61947e"}
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  EXIT_CODE,
3
3
  PmCliError
4
- } from "./chunk-LFW5NQUP.js";
4
+ } from "./chunk-CHM2VFVL.js";
5
5
 
6
6
  // dist/core/item/parse.js
7
7
  !(function() {
8
8
  try {
9
9
  var e = "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof globalThis ? globalThis : "undefined" != typeof self ? self : {}, n = new e.Error().stack;
10
- n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "d5e00545-4334-546c-8d97-005469be3899");
10
+ n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "cc88ee68-a99b-5f5f-8591-e7762739ba97");
11
11
  } catch (e2) {
12
12
  }
13
13
  })();
@@ -96,10 +96,8 @@ function coerceJsonTagArray(trimmed) {
96
96
  } catch {
97
97
  return null;
98
98
  }
99
- if (!Array.isArray(parsed)) {
100
- return null;
101
- }
102
- return parsed.map((entry) => typeof entry === "string" || typeof entry === "number" || typeof entry === "boolean" ? String(entry).replace(/,/g, " ") : "").filter((entry) => entry.length > 0).join(",");
99
+ const parsedArray = parsed;
100
+ return parsedArray.map((entry) => typeof entry === "string" || typeof entry === "number" || typeof entry === "boolean" ? String(entry).replace(/,/g, " ") : "").filter((entry) => entry.length > 0).join(",");
103
101
  }
104
102
  function normalizeLineEndings(value) {
105
103
  return value.replace(/\r\n/g, "\n");
@@ -113,9 +111,6 @@ function stripCodeFenceEnvelope(value) {
113
111
  if (lines.length < 2) {
114
112
  return value;
115
113
  }
116
- if (!lines[0].startsWith("```")) {
117
- return value;
118
- }
119
114
  if (lines.at(-1)?.trim() !== "```") {
120
115
  return value;
121
116
  }
@@ -224,7 +219,7 @@ ${line}`;
224
219
  }
225
220
  return null;
226
221
  }
227
- return Object.keys(result).length > 0 ? result : null;
222
+ return result;
228
223
  }
229
224
  function parseCsvKv(raw, optionName) {
230
225
  const trimmed = stripCodeFenceEnvelope(raw).trim();
@@ -242,9 +237,6 @@ function parseCsvKv(raw, optionName) {
242
237
  const delimiterIndex = findKeyValueDelimiter(segment);
243
238
  if (delimiterIndex > 0) {
244
239
  const key = segment.slice(0, delimiterIndex).trim();
245
- if (!key) {
246
- throw new PmCliError(buildInvalidKvMessage(raw, optionName), EXIT_CODE.USAGE);
247
- }
248
240
  const value = unquoteValue(segment.slice(delimiterIndex + 1).trim());
249
241
  result[key] = value;
250
242
  activeKey = key;
@@ -256,11 +248,35 @@ function parseCsvKv(raw, optionName) {
256
248
  }
257
249
  throw new PmCliError(buildInvalidKvMessage(raw, optionName), EXIT_CODE.USAGE);
258
250
  }
259
- if (Object.keys(result).length === 0) {
260
- throw new PmCliError(buildInvalidKvMessage(raw, optionName), EXIT_CODE.USAGE);
261
- }
262
251
  return result;
263
252
  }
253
+ var WINDOWS_ABSOLUTE_PATH_PATTERN = /^[A-Za-z]:[\\/]/;
254
+ var GENERIC_LEADING_KV_KEY_PATTERN = /^(?:[-*+]\s+)?[A-Za-z_][A-Za-z0-9_.-]*\s*=/;
255
+ function looksLikeGenericKeyValueEntry(raw) {
256
+ const trimmed = raw.trim();
257
+ if (WINDOWS_ABSOLUTE_PATH_PATTERN.test(trimmed)) {
258
+ return false;
259
+ }
260
+ return GENERIC_LEADING_KV_KEY_PATTERN.test(trimmed);
261
+ }
262
+ function assertNoUnknownCsvKeys(kv, optionName, allowedKeys) {
263
+ const allowed = new Set(allowedKeys.map((key) => key.toLowerCase()));
264
+ const unknownKeys = Object.keys(kv).filter((key) => !allowed.has(key.toLowerCase()));
265
+ if (unknownKeys.length > 0) {
266
+ throw new PmCliError(`${optionName} does not recognize key${unknownKeys.length > 1 ? "s" : ""} ${unknownKeys.map((key) => `"${key}"`).join(", ")}. Allowed keys: ${allowedKeys.join(", ")}.`, EXIT_CODE.USAGE);
267
+ }
268
+ for (const key of Object.keys(kv)) {
269
+ const normalizedKey = key.toLowerCase();
270
+ if (normalizedKey === key) {
271
+ continue;
272
+ }
273
+ if (Object.hasOwn(kv, normalizedKey)) {
274
+ throw new PmCliError(`${optionName} provides key "${key}" more than once after case normalization.`, EXIT_CODE.USAGE);
275
+ }
276
+ kv[normalizedKey] = kv[key];
277
+ delete kv[key];
278
+ }
279
+ }
264
280
  async function readStdinText(optionName) {
265
281
  if (process.stdin.isTTY === true) {
266
282
  throw new PmCliError(`${optionName} value "${STDIN_TOKEN}" requires piped stdin input. Pipe content into the command, or end manual stdin with Ctrl+D (Unix/macOS) or Ctrl+Z then Enter (Windows).`, EXIT_CODE.USAGE);
@@ -335,7 +351,9 @@ export {
335
351
  mergeAdditiveTags,
336
352
  applyTagRemovals,
337
353
  parseCsvKv,
354
+ looksLikeGenericKeyValueEntry,
355
+ assertNoUnknownCsvKeys,
338
356
  createStdinTokenResolver,
339
357
  parseOptionalNumber
340
358
  };
341
- //# sourceMappingURL=chunk-HZOX5BYD.js.map
359
+ //# sourceMappingURL=chunk-OGXEBTX3.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../../core/item/parse.ts"],
4
+ "sourcesContent": ["import { PmCliError } from \"../shared/errors.js\";\nimport { EXIT_CODE } from \"../shared/constants.js\";\n\nconst STDIN_TOKEN = \"-\";\nconst CONTINUABLE_VALUE_KEYS = new Set([\n \"actual_result\",\n \"body\",\n \"cmd\",\n \"command\",\n \"customer_impact\",\n \"description\",\n \"environment\",\n \"expected_result\",\n \"impact\",\n \"location\",\n \"message\",\n \"note\",\n \"outcome\",\n \"repro_steps\",\n \"resolution\",\n \"text\",\n \"title\",\n \"unblock_note\",\n \"value\",\n \"why_now\",\n]);\n\nexport function parseTags(raw: string): string[] {\n const trimmed = raw.trim();\n if (trimmed === \"\") {\n return [];\n }\n const source = coerceJsonTagArray(trimmed) ?? trimmed;\n const tags = source\n .split(\",\")\n .map((tag) => tag.trim())\n .filter(Boolean)\n .map((tag) => tag.toLowerCase());\n return Array.from(new Set(tags)).sort((a, b) => a.localeCompare(b));\n}\n\n/**\n * Merge repeated `--add-tags` / `--remove-tags` values into a single normalized\n * tag list. Each entry can itself be CSV or a JSON array, mirroring the format\n * accepted by `--tags`. Returns a deterministically sorted, deduped list.\n */\nexport function collectTagFlagValues(values: readonly string[] | undefined): string[] {\n if (!Array.isArray(values) || values.length === 0) {\n return [];\n }\n const collected: string[] = [];\n for (const raw of values) {\n if (typeof raw !== \"string\") {\n continue;\n }\n for (const tag of parseTags(raw)) {\n collected.push(tag);\n }\n }\n return Array.from(new Set(collected)).sort((a, b) => a.localeCompare(b));\n}\n\n/**\n * Normalize a base tag list to the canonical form pm stores: trimmed,\n * lowercased, non-empty. Existing front-matter tags are almost always already\n * canonical (parseTags lowercases on write), but legacy or hand-edited `.toon`\n * files can carry mixed-case entries — normalizing here keeps additive and\n * subtractive mutations case-insensitive (so `--add-tags beta` dedupes against\n * an existing `Beta`, and `--remove-tags alpha` removes an existing `Alpha`).\n */\nfunction normalizeBaseTags(baseTags: readonly string[]): string[] {\n // Defensive: front-matter parsed from corrupted/hand-edited `.toon` (or an\n // external SDK caller) could pass a non-array or non-string entries despite\n // the `string[]` type — guard the array and skip non-strings rather than\n // throwing on `.filter`/`.trim()`.\n if (!Array.isArray(baseTags)) {\n return [];\n }\n return baseTags\n .filter((tag): tag is string => typeof tag === \"string\")\n .map((tag) => tag.trim().toLowerCase())\n .filter(Boolean);\n}\n\n/**\n * Apply an additive tag mutation to a base tag list. Used by `pm create` and\n * `pm update` so `--add-tags` extends `--tags` (or the existing tags) without\n * replacing them. Output is sorted + deduped lowercase, matching `parseTags`.\n */\nexport function mergeAdditiveTags(baseTags: readonly string[], add: readonly string[] | undefined): string[] {\n const normalizedBase = normalizeBaseTags(baseTags);\n if (!add || add.length === 0) {\n return Array.from(new Set(normalizedBase)).sort((a, b) => a.localeCompare(b));\n }\n const merged = new Set<string>(normalizedBase);\n for (const tag of collectTagFlagValues(add)) {\n merged.add(tag);\n }\n return Array.from(merged).sort((a, b) => a.localeCompare(b));\n}\n\n/**\n * Apply a subtractive tag mutation to a base tag list. Used by `pm update` so\n * `--remove-tags x,y` prunes those entries without rewriting the full set.\n * Removal is case-insensitive: both the base list and the removal selectors are\n * normalized to canonical lowercase before matching.\n */\nexport function applyTagRemovals(baseTags: readonly string[], remove: readonly string[] | undefined): string[] {\n const normalizedBase = Array.from(new Set(normalizeBaseTags(baseTags))).sort((a, b) => a.localeCompare(b));\n if (!remove || remove.length === 0) {\n return normalizedBase;\n }\n const removeSet = new Set(collectTagFlagValues(remove));\n if (removeSet.size === 0) {\n return normalizedBase;\n }\n return normalizedBase.filter((tag) => !removeSet.has(tag));\n}\n\n// Agents and MCP callers frequently pass --tags as a JSON array (e.g.\n// `--tags '[\"a\",\"b\"]'`). The MCP server normalizes that upstream, but direct\n// CLI invocations used to write the raw bracket string into front matter,\n// silently corrupting tags. Accept JSON arrays of primitives transparently.\nfunction coerceJsonTagArray(trimmed: string): string | null {\n if (!trimmed.startsWith(\"[\")) {\n return null;\n }\n let parsed: unknown;\n try {\n parsed = JSON.parse(trimmed);\n } catch {\n return null;\n }\n const parsedArray = parsed as unknown[];\n return parsedArray\n .map((entry) =>\n typeof entry === \"string\" || typeof entry === \"number\" || typeof entry === \"boolean\"\n ? String(entry).replace(/,/g, \" \")\n : \"\",\n )\n .filter((entry) => entry.length > 0)\n .join(\",\");\n}\n\nfunction normalizeLineEndings(value: string): string {\n return value.replace(/\\r\\n/g, \"\\n\");\n}\n\nfunction stripCodeFenceEnvelope(value: string): string {\n const normalized = normalizeLineEndings(value).trim();\n if (!normalized.startsWith(\"```\")) {\n return value;\n }\n const lines = normalized.split(\"\\n\");\n if (lines.length < 2) {\n return value;\n }\n if (lines.at(-1)?.trim() !== \"```\") {\n return value;\n }\n return lines.slice(1, -1).join(\"\\n\");\n}\n\nfunction splitCsvSegments(raw: string): string[] {\n const segments: string[] = [];\n let current = \"\";\n let inQuotes = false;\n let escaped = false;\n\n for (const char of raw) {\n if (escaped) {\n current += char;\n escaped = false;\n continue;\n }\n if (char === \"\\\\\") {\n current += char;\n escaped = true;\n continue;\n }\n if (char === \"\\\"\") {\n inQuotes = !inQuotes;\n current += char;\n continue;\n }\n if (char === \",\" && !inQuotes) {\n segments.push(current.trim());\n current = \"\";\n continue;\n }\n current += char;\n }\n if (current.trim()) {\n segments.push(current.trim());\n }\n return segments;\n}\n\nfunction unquoteValue(value: string): string {\n const trimmed = value.trim();\n if (trimmed.startsWith(\"\\\"\") && trimmed.endsWith(\"\\\"\")) {\n return trimmed.slice(1, -1).replace(/\\\\\"/g, \"\\\"\");\n }\n return value;\n}\n\nfunction findKeyValueDelimiter(segment: string): number {\n const equalsIndex = segment.indexOf(\"=\");\n const colonIndex = segment.indexOf(\":\");\n const hasEquals = equalsIndex > 0;\n const hasColon = colonIndex > 0;\n if (hasEquals && hasColon) {\n return Math.min(equalsIndex, colonIndex);\n }\n if (hasEquals) {\n return equalsIndex;\n }\n if (hasColon) {\n return colonIndex;\n }\n return -1;\n}\n\nfunction buildOptionSpecificKvGuidance(raw: string, optionName: string): string {\n if (optionName === \"--add\" || optionName === \"--add-glob\") {\n const looksLikePath = /[./\\\\]/.test(raw) || /\\.[a-z]{1,6}$/i.test(raw.trim());\n if (looksLikePath) {\n return 'For file/doc paths use: path=<file-path>[,scope=project|global]. The scope field is optional and defaults to project (example: path=src/api.ts or path=README.md,scope=project). ';\n }\n }\n if (optionName !== \"--event\") {\n return \"\";\n }\n const lowered = raw.toLowerCase();\n const recurrenceHint =\n lowered.includes(\"recur_\") || lowered.includes(\"recurrence\")\n ? ' Recurrence list values must stay in one field and use \"|\" delimiters (for example recur_by_weekday=mon|wed or recur_by_month_day=1|15).'\n : \"\";\n const weekdayAliasHint = lowered.includes(\"recur_byweekday\")\n ? \" Use recur_by_weekday (with underscores) for weekday recurrence filters.\"\n : \"\";\n return `${recurrenceHint}${weekdayAliasHint}`;\n}\n\nfunction buildInvalidKvMessage(raw: string, optionName: string): string {\n const condensed = raw.replaceAll(/\\s+/g, \" \").trim();\n const preview = condensed.length > 160 ? `${condensed.slice(0, 157)}...` : condensed;\n const optionSpecificGuidance = buildOptionSpecificKvGuidance(raw, optionName);\n return (\n `Invalid ${optionName} value \"${preview}\". Expected key=value entries separated by commas. ` +\n optionSpecificGuidance +\n 'Also accepts markdown-style key/value lines (for example \"- path: README.md\"). ' +\n `Use ${optionName} ${STDIN_TOKEN} to read piped stdin input.`\n );\n}\n\nfunction parseMarkdownKeyValueLines(raw: string): Record<string, string> | null {\n const normalized = stripCodeFenceEnvelope(raw).trim();\n if (normalized.length === 0) {\n return null;\n }\n if (!normalized.includes(\"\\n\") && !normalized.startsWith(\"-\") && !normalized.startsWith(\"*\") && !normalized.startsWith(\"+\")) {\n return null;\n }\n\n const result: Record<string, string> = {};\n let activeKey: string | undefined;\n const lines = normalizeLineEndings(normalized)\n .split(\"\\n\")\n .map((line) => line.trim())\n .filter((line) => line.length > 0);\n\n for (const line of lines) {\n const match = line.match(/^(?:[-*+]\\s+)?([a-zA-Z0-9_.-]+)\\s*(=|:)\\s*(.*)$/);\n if (match) {\n const key = match[1].trim();\n result[key] = unquoteValue(match[3].trim());\n activeKey = key;\n continue;\n }\n if (activeKey && CONTINUABLE_VALUE_KEYS.has(activeKey.toLowerCase())) {\n result[activeKey] = `${result[activeKey]}\\n${line}`;\n continue;\n }\n return null;\n }\n\n return result;\n}\n\nexport function parseCsvKv(raw: string, optionName: string): Record<string, string> {\n const trimmed = stripCodeFenceEnvelope(raw).trim();\n if (!trimmed) {\n throw new PmCliError(`${optionName} cannot be empty`, EXIT_CODE.USAGE);\n }\n\n const markdownStyle = parseMarkdownKeyValueLines(trimmed);\n if (markdownStyle) {\n return markdownStyle;\n }\n\n const result: Record<string, string> = {};\n let activeKey: string | undefined;\n const segments = splitCsvSegments(trimmed);\n\n for (const segment of segments) {\n const delimiterIndex = findKeyValueDelimiter(segment);\n if (delimiterIndex > 0) {\n const key = segment.slice(0, delimiterIndex).trim();\n const value = unquoteValue(segment.slice(delimiterIndex + 1).trim());\n result[key] = value;\n activeKey = key;\n continue;\n }\n if (activeKey && CONTINUABLE_VALUE_KEYS.has(activeKey.toLowerCase())) {\n result[activeKey] = `${result[activeKey]},${segment.trim()}`;\n continue;\n }\n throw new PmCliError(buildInvalidKvMessage(raw, optionName), EXIT_CODE.USAGE);\n }\n\n return result;\n}\n\nconst WINDOWS_ABSOLUTE_PATH_PATTERN = /^[A-Za-z]:[\\\\/]/;\nconst GENERIC_LEADING_KV_KEY_PATTERN = /^(?:[-*+]\\s+)?[A-Za-z_][A-Za-z0-9_.-]*\\s*=/;\n\n/**\n * Detect a CSV/markdown entry that opens with a generic `key=` token even when\n * that key is unknown (e.g. a typo like `lable=main,path=README.md`). Callers\n * combine this with their known-key prefix check so a first-key typo is routed\n * through structured parsing and rejected by {@link assertNoUnknownCsvKeys}\n * (GH-258) instead of being silently swallowed as a bare path/value.\n *\n * Windows absolute paths (`C:\\…`) are excluded so a drive-lettered bare path is\n * never misread as a `C=…` key/value entry.\n */\nexport function looksLikeGenericKeyValueEntry(raw: string): boolean {\n const trimmed = raw.trim();\n if (WINDOWS_ABSOLUTE_PATH_PATTERN.test(trimmed)) {\n return false;\n }\n return GENERIC_LEADING_KV_KEY_PATTERN.test(trimmed);\n}\n\n/**\n * Reject any key in a parsed CSV/markdown key/value map that is not part of the\n * caller's allowed-key contract, mirroring the strict `test --add` behavior\n * (see linked-test-parsers). This closes the cross-command consistency defect\n * (GH-258) where structured link/metadata parsers silently DROPPED typoed keys\n * (e.g. `lable=` instead of `label=`), storing data the author never intended.\n *\n * Comparison is case-insensitive so a key the downstream reader would accept\n * (e.g. `Path`) is never falsely rejected; the emitted \"Allowed keys\" list\n * preserves the canonical casing the caller passes in. Recognized keys are then\n * normalized in-place to their lowercase canonical form so downstream readers\n * (`kv.path`, `kv.id`, `kv.at`, …) see the value even when the input used mixed\n * casing — otherwise `Path=README.md` would pass validation yet read back as an\n * undefined `path` and surface a confusing \"requires path\" error. A key that\n * collides with another after normalization (e.g. `path=a,Path=b`) is rejected.\n *\n * Parsers with an intentional plaintext fallback (`--comment`/`--note`/\n * `--learning`, annotation `--add`) deliberately do NOT call this — there an\n * unrecognized key means \"treat the whole entry as plaintext\", not an error.\n */\nexport function assertNoUnknownCsvKeys(\n kv: Record<string, string>,\n optionName: string,\n allowedKeys: readonly string[],\n): void {\n const allowed = new Set(allowedKeys.map((key) => key.toLowerCase()));\n const unknownKeys = Object.keys(kv).filter((key) => !allowed.has(key.toLowerCase()));\n if (unknownKeys.length > 0) {\n throw new PmCliError(\n `${optionName} does not recognize key${unknownKeys.length > 1 ? \"s\" : \"\"} ${unknownKeys\n .map((key) => `\"${key}\"`)\n .join(\", \")}. Allowed keys: ${allowedKeys.join(\", \")}.`,\n EXIT_CODE.USAGE,\n );\n }\n for (const key of Object.keys(kv)) {\n const normalizedKey = key.toLowerCase();\n if (normalizedKey === key) {\n continue;\n }\n if (Object.hasOwn(kv, normalizedKey)) {\n throw new PmCliError(\n `${optionName} provides key \"${key}\" more than once after case normalization.`,\n EXIT_CODE.USAGE,\n );\n }\n kv[normalizedKey] = kv[key];\n delete kv[key];\n }\n}\n\nasync function readStdinText(optionName: string): Promise<string> {\n if (process.stdin.isTTY === true) {\n throw new PmCliError(\n `${optionName} value \"${STDIN_TOKEN}\" requires piped stdin input. Pipe content into the command, or end manual stdin with Ctrl+D (Unix/macOS) or Ctrl+Z then Enter (Windows).`,\n EXIT_CODE.USAGE,\n );\n }\n process.stdin.setEncoding(\"utf8\");\n return await new Promise<string>((resolve, reject) => {\n let input = \"\";\n process.stdin.on(\"data\", (chunk: string) => {\n input += chunk;\n });\n process.stdin.on(\"end\", () => {\n resolve(normalizeLineEndings(input));\n });\n process.stdin.on(\"error\", (error) => {\n reject(error);\n });\n });\n}\n\nexport interface StdinTokenResolver {\n resolveValue(value: string | undefined, optionName: string): Promise<string | undefined>;\n resolveList(values: string[] | undefined, optionName: string): Promise<string[] | undefined>;\n}\n\nexport function createStdinTokenResolver(): StdinTokenResolver {\n let stdinValuePromise: Promise<string> | undefined;\n let stdinConsumerOption: string | undefined;\n\n const consumeStdin = async (optionName: string): Promise<string> => {\n if (stdinConsumerOption && stdinConsumerOption !== optionName) {\n throw new PmCliError(\n `Only one option may use \"${STDIN_TOKEN}\" stdin token per command invocation. Already used by ${stdinConsumerOption}.`,\n EXIT_CODE.USAGE,\n );\n }\n stdinConsumerOption = optionName;\n if (!stdinValuePromise) {\n stdinValuePromise = readStdinText(optionName);\n }\n return await stdinValuePromise;\n };\n\n const resolveValue = async (value: string | undefined, optionName: string): Promise<string | undefined> => {\n if (value === undefined) {\n return undefined;\n }\n if (value.trim() !== STDIN_TOKEN) {\n return value;\n }\n return await consumeStdin(optionName);\n };\n\n const resolveList = async (values: string[] | undefined, optionName: string): Promise<string[] | undefined> => {\n if (!values) {\n return undefined;\n }\n const tokenIndexes = values\n .map((entry, index) => (entry.trim() === STDIN_TOKEN ? index : -1))\n .filter((index) => index >= 0);\n if (tokenIndexes.length === 0) {\n return values;\n }\n if (tokenIndexes.length > 1) {\n throw new PmCliError(\n `${optionName} accepts \"${STDIN_TOKEN}\" stdin token at most once per command invocation`,\n EXIT_CODE.USAGE,\n );\n }\n const stdinValue = await consumeStdin(optionName);\n const next = [...values];\n next[tokenIndexes[0]] = stdinValue;\n return next;\n };\n\n return {\n resolveValue,\n resolveList,\n };\n}\n\nexport function parseOptionalNumber(raw: string, optionName: string): number {\n const value = Number(raw);\n if (!Number.isFinite(value)) {\n throw new PmCliError(`Invalid ${optionName} value \"${raw}\"`, EXIT_CODE.USAGE);\n }\n return value;\n}\n\nexport const _testOnly = {\n coer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QAAM,QAAQ,OAAO,GAAG;AACxB,MAAI,CAAC,OAAO,SAAS,KAAK,GAAG;AAC3B,UAAM,IAAI,WAAW,WAAW,UAAU,WAAW,GAAG,KAAK,UAAU,KAAK;EAC9E;AACA,SAAO;AACT;",
6
+ "names": []
7
+ }
@@ -1,12 +1,12 @@
1
1
 
2
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="eef197b0-99c4-5e16-b890-90482bb8d6d6")}catch(e){}}();
2
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="e76ec835-15fe-5a06-b713-4557c1e8bede")}catch(e){}}();
3
3
  import {
4
4
  EXIT_CODE,
5
5
  runActiveCommandOverride,
6
6
  runActiveRendererOverride,
7
7
  runActiveServiceOverrideSync,
8
8
  setActiveCommandResult
9
- } from "./chunk-S2CDTRJ6.js";
9
+ } from "./chunk-SJCMTOEU.js";
10
10
 
11
11
  // dist/core/output/mutation-projection.js
12
12
  var CHANGED_FIELDS_KEY = "changed_fields";
@@ -334,6 +334,6 @@ export {
334
334
  printResult,
335
335
  printError
336
336
  };
337
- //# sourceMappingURL=chunk-LOAR5TKX.js.map
337
+ //# sourceMappingURL=chunk-OOIH6J5T.js.map
338
338
 
339
- //# debugId=eef197b0-99c4-5e16-b890-90482bb8d6d6
339
+ //# debugId=e76ec835-15fe-5a06-b713-4557c1e8bede