@hawkeyexl/manni 4.13.0 → 4.15.0

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 (293) hide show
  1. package/README.md +1 -1
  2. package/dist/batch-OMDKRGUE.js +48 -0
  3. package/dist/build-YCY5MUHA.js +37 -0
  4. package/dist/calibrate-RN2NJ4FS.js +43 -0
  5. package/dist/capture-2WYROZKA.js +39 -0
  6. package/dist/check-KRVWHF7E.js +33 -0
  7. package/dist/{check-NBN2YK2J.js → check-LVUTWAGR.js} +33 -32
  8. package/dist/{check-NBN2YK2J.js.map → check-LVUTWAGR.js.map} +1 -1
  9. package/dist/check-MR7IG7IP.js +36 -0
  10. package/dist/{check-LU5YC3L4.js → check-OIRJ6OBW.js} +15 -14
  11. package/dist/{chunk-J5NOWIJ3.js → chunk-3CSEHHKB.js} +14 -8
  12. package/dist/{chunk-J5NOWIJ3.js.map → chunk-3CSEHHKB.js.map} +1 -1
  13. package/dist/{chunk-7RNONVHI.js → chunk-3EJVJDMX.js} +9 -9
  14. package/dist/{chunk-LSFXNAHU.js → chunk-3WQMMLIO.js} +129 -59
  15. package/dist/chunk-3WQMMLIO.js.map +1 -0
  16. package/dist/{chunk-OREHJQNN.js → chunk-46OWIAAX.js} +5 -4
  17. package/dist/{chunk-OREHJQNN.js.map → chunk-46OWIAAX.js.map} +1 -1
  18. package/dist/{chunk-LNGSE7V2.js → chunk-476DMDJ5.js} +132 -27
  19. package/dist/chunk-476DMDJ5.js.map +1 -0
  20. package/dist/{chunk-EQ7E6HMG.js → chunk-4MYW2D2U.js} +14 -16
  21. package/dist/chunk-4MYW2D2U.js.map +1 -0
  22. package/dist/{chunk-NTEYYYKL.js → chunk-525KMBZS.js} +16 -22
  23. package/dist/chunk-525KMBZS.js.map +1 -0
  24. package/dist/{chunk-HIEGOW7X.js → chunk-57DHX65T.js} +5 -79
  25. package/dist/chunk-57DHX65T.js.map +1 -0
  26. package/dist/{chunk-PCE7QHXJ.js → chunk-5D24C6WM.js} +6 -1
  27. package/dist/chunk-5D24C6WM.js.map +1 -0
  28. package/dist/{chunk-DQOM3DEU.js → chunk-6DYFWAZA.js} +563 -359
  29. package/dist/chunk-6DYFWAZA.js.map +1 -0
  30. package/dist/{chunk-CU57HT2E.js → chunk-6WJUZQQX.js} +2 -2
  31. package/dist/chunk-7EKXSSEO.js +81 -0
  32. package/dist/chunk-7EKXSSEO.js.map +1 -0
  33. package/dist/{chunk-ULDV2LUI.js → chunk-7SVFBJBE.js} +10 -4
  34. package/dist/chunk-7SVFBJBE.js.map +1 -0
  35. package/dist/{chunk-QKT67PFE.js → chunk-7XHW5DZA.js} +9 -9
  36. package/dist/{chunk-TDCOKKMI.js → chunk-AL4HRKSZ.js} +3 -3
  37. package/dist/{chunk-OTJOBZJ5.js → chunk-B2242FYO.js} +2 -1
  38. package/dist/chunk-B2242FYO.js.map +1 -0
  39. package/dist/chunk-BREAC43H.js +85 -0
  40. package/dist/chunk-BREAC43H.js.map +1 -0
  41. package/dist/{chunk-HKTGHLBA.js → chunk-C37OVJ35.js} +2 -2
  42. package/dist/{chunk-HKTGHLBA.js.map → chunk-C37OVJ35.js.map} +1 -1
  43. package/dist/{chunk-YQV75FIL.js → chunk-CFMI74TP.js} +3 -3
  44. package/dist/{chunk-BMBAAPGN.js → chunk-CWGBRWP7.js} +33 -18
  45. package/dist/chunk-CWGBRWP7.js.map +1 -0
  46. package/dist/chunk-DN4LCWSA.js +83 -0
  47. package/dist/chunk-DN4LCWSA.js.map +1 -0
  48. package/dist/{chunk-JEUFYSFQ.js → chunk-DW22KCLN.js} +118 -75
  49. package/dist/chunk-DW22KCLN.js.map +1 -0
  50. package/dist/{chunk-PCGBXHSE.js → chunk-FEEO7ET6.js} +5 -5
  51. package/dist/{chunk-CODWRUAD.js → chunk-FYWQS35G.js} +7 -5
  52. package/dist/chunk-FYWQS35G.js.map +1 -0
  53. package/dist/{chunk-3O6U4ICM.js → chunk-GLQCSDFS.js} +3 -3
  54. package/dist/{chunk-BQXY76JB.js → chunk-GUTAKJIF.js} +148 -92
  55. package/dist/chunk-GUTAKJIF.js.map +1 -0
  56. package/dist/{chunk-WVXCN5DS.js → chunk-GZHBMMDC.js} +78 -14
  57. package/dist/chunk-GZHBMMDC.js.map +1 -0
  58. package/dist/{chunk-52WO7ESI.js → chunk-IE5PXI6M.js} +6 -5
  59. package/dist/chunk-IE5PXI6M.js.map +1 -0
  60. package/dist/{chunk-ZXRAE55H.js → chunk-IGRXQC3H.js} +2 -2
  61. package/dist/{chunk-U6IHLEWT.js → chunk-JCTHXG33.js} +2 -2
  62. package/dist/{chunk-NSAW7U42.js → chunk-JHE3CYWS.js} +58 -10
  63. package/dist/chunk-JHE3CYWS.js.map +1 -0
  64. package/dist/{chunk-6ZFJWUUH.js → chunk-JNMY7KZG.js} +2 -2
  65. package/dist/chunk-JQPZKWIP.js +76 -0
  66. package/dist/chunk-JQPZKWIP.js.map +1 -0
  67. package/dist/{chunk-OBXCJZ6R.js → chunk-JTATFPWB.js} +28 -17
  68. package/dist/chunk-JTATFPWB.js.map +1 -0
  69. package/dist/{chunk-3HUCB4Z3.js → chunk-JULE3EU3.js} +10 -7
  70. package/dist/chunk-JULE3EU3.js.map +1 -0
  71. package/dist/{chunk-TQ3W6RKG.js → chunk-KCXQXKOL.js} +3 -3
  72. package/dist/{chunk-VYBYUQIP.js → chunk-KN37BXVY.js} +88 -7
  73. package/dist/chunk-KN37BXVY.js.map +1 -0
  74. package/dist/{chunk-OUAH7XF2.js → chunk-MAOX3524.js} +2 -2
  75. package/dist/chunk-MC7U5IH4.js +126 -0
  76. package/dist/chunk-MC7U5IH4.js.map +1 -0
  77. package/dist/{chunk-OYIWF3B2.js → chunk-NIQ2JSZO.js} +29 -20
  78. package/dist/chunk-NIQ2JSZO.js.map +1 -0
  79. package/dist/{chunk-HY6ROJTH.js → chunk-OFOIBV5J.js} +86 -10
  80. package/dist/chunk-OFOIBV5J.js.map +1 -0
  81. package/dist/{chunk-TZOYZK2E.js → chunk-OZUPJB4J.js} +2 -2
  82. package/dist/{chunk-N6A6DJUO.js → chunk-Q2VOXKAQ.js} +6 -7
  83. package/dist/chunk-Q2VOXKAQ.js.map +1 -0
  84. package/dist/{chunk-GWI6JPTT.js → chunk-Q62Q7CDI.js} +88 -8
  85. package/dist/chunk-Q62Q7CDI.js.map +1 -0
  86. package/dist/{chunk-PA7CMQGD.js → chunk-QDO5JFFV.js} +11 -5
  87. package/dist/chunk-QDO5JFFV.js.map +1 -0
  88. package/dist/{chunk-VNYXK7TM.js → chunk-QEJ4GH25.js} +8 -8
  89. package/dist/chunk-QEJ4GH25.js.map +1 -0
  90. package/dist/chunk-QK6VYJHV.js +26 -0
  91. package/dist/chunk-QK6VYJHV.js.map +1 -0
  92. package/dist/chunk-QS2Z3SWL.js +21 -0
  93. package/dist/chunk-QS2Z3SWL.js.map +1 -0
  94. package/dist/{chunk-NWUXRV6N.js → chunk-QS3K57OJ.js} +10 -8
  95. package/dist/chunk-QS3K57OJ.js.map +1 -0
  96. package/dist/{chunk-OKMTUAWO.js → chunk-QSPH4F56.js} +5 -5
  97. package/dist/{chunk-3XGTNN3M.js → chunk-RGRNAQG5.js} +12 -124
  98. package/dist/chunk-RGRNAQG5.js.map +1 -0
  99. package/dist/{chunk-E6BVUDGY.js → chunk-SLGCRXHM.js} +4 -4
  100. package/dist/{chunk-KE2F7QES.js → chunk-SVF3WCC7.js} +6 -6
  101. package/dist/{chunk-IGQMBHFY.js → chunk-T62SFCQY.js} +88 -12
  102. package/dist/chunk-T62SFCQY.js.map +1 -0
  103. package/dist/{chunk-SCLXVTFZ.js → chunk-TKINOTVS.js} +1 -1
  104. package/dist/chunk-TKINOTVS.js.map +1 -0
  105. package/dist/{chunk-VOXOBUTX.js → chunk-TXZJESES.js} +5 -5
  106. package/dist/chunk-UPUJJOKB.js +236 -0
  107. package/dist/chunk-UPUJJOKB.js.map +1 -0
  108. package/dist/{chunk-7JPL3CUC.js → chunk-URGALOZY.js} +2 -2
  109. package/dist/{chunk-X4MPUD4B.js → chunk-UVLQRP6O.js} +53 -13
  110. package/dist/chunk-UVLQRP6O.js.map +1 -0
  111. package/dist/{chunk-CWXZ2MRT.js → chunk-VHJ72YCD.js} +4 -3
  112. package/dist/chunk-VHJ72YCD.js.map +1 -0
  113. package/dist/{chunk-PAU352SV.js → chunk-W4GTMOJW.js} +2 -2
  114. package/dist/{chunk-SE4JN5XN.js → chunk-WDENIUC7.js} +3 -1
  115. package/dist/chunk-WDENIUC7.js.map +1 -0
  116. package/dist/{chunk-3BVDFQ6Y.js → chunk-Y3GWQBJP.js} +5 -5
  117. package/dist/{chunk-YZ4TJLZQ.js → chunk-YT5HKJWV.js} +497 -18
  118. package/dist/chunk-YT5HKJWV.js.map +1 -0
  119. package/dist/{chunk-UQMLCIRX.js → chunk-Z6PZKXSP.js} +6 -6
  120. package/dist/{chunk-JUL2PRQN.js → chunk-ZC2MZZR5.js} +207 -79
  121. package/dist/chunk-ZC2MZZR5.js.map +1 -0
  122. package/dist/{chunk-UKZNLVJW.js → chunk-ZINZTHWO.js} +4 -2
  123. package/dist/chunk-ZINZTHWO.js.map +1 -0
  124. package/dist/{cli-4JHQCPHU.js → cli-33E3B2FK.js} +3 -3
  125. package/dist/{cli-G66X7YMP.js → cli-7JV4RM66.js} +23 -22
  126. package/dist/{cli-G66X7YMP.js.map → cli-7JV4RM66.js.map} +1 -1
  127. package/dist/{cli-L5B2RVV2.js → cli-B4DTJ2KC.js} +31 -29
  128. package/dist/{cli-L5B2RVV2.js.map → cli-B4DTJ2KC.js.map} +1 -1
  129. package/dist/{cli-ECVT4YXR.js → cli-D4WXCDTS.js} +20 -19
  130. package/dist/{cli-ECVT4YXR.js.map → cli-D4WXCDTS.js.map} +1 -1
  131. package/dist/{cli-7DETHSNW.js → cli-DDLLZHZW.js} +90 -84
  132. package/dist/cli-DDLLZHZW.js.map +1 -0
  133. package/dist/{cli-KYTCJYXK.js → cli-EVACAD7K.js} +317 -28
  134. package/dist/cli-EVACAD7K.js.map +1 -0
  135. package/dist/{cli-H5LVGOVT.js → cli-LIKI7WPR.js} +384 -248
  136. package/dist/cli-LIKI7WPR.js.map +1 -0
  137. package/dist/{cli-AZKWTCFV.js → cli-MWUFAS2X.js} +11 -11
  138. package/dist/{cli-DGFLJ2DD.js → cli-OKPRTVG6.js} +69 -26
  139. package/dist/cli-OKPRTVG6.js.map +1 -0
  140. package/dist/{cli-RP5E7XHC.js → cli-QEPVGLQ3.js} +20 -18
  141. package/dist/{cli-RP5E7XHC.js.map → cli-QEPVGLQ3.js.map} +1 -1
  142. package/dist/{cli-BW5VOFOZ.js → cli-VP6JTPFS.js} +11 -10
  143. package/dist/{cli-BW5VOFOZ.js.map → cli-VP6JTPFS.js.map} +1 -1
  144. package/dist/cli.js +14 -14
  145. package/dist/{config-JJW75SBX.js → config-7I5CHHRZ.js} +6 -6
  146. package/dist/docmeta.js +10 -10
  147. package/dist/github-DV57TW5L.js +32 -0
  148. package/dist/github-SGX2EARO.js +36 -0
  149. package/dist/graph/runtime.js.map +1 -1
  150. package/dist/index.d.ts +222 -45
  151. package/dist/index.js +138 -132
  152. package/dist/index.js.map +1 -1
  153. package/dist/{json-7WV7KL6H.js → json-5EQCGVCV.js} +4 -2
  154. package/dist/{json-LCVPMEAM.js → json-SHPUCD64.js} +15 -13
  155. package/dist/{labels-OQXBVM4A.js → labels-3GCGYYV3.js} +14 -12
  156. package/dist/{labels-OQXBVM4A.js.map → labels-3GCGYYV3.js.map} +1 -1
  157. package/dist/lint-RE4DMI6E.js +35 -0
  158. package/dist/list-F56MEJXR.js +36 -0
  159. package/dist/list-ZR3KY556.js +34 -0
  160. package/dist/{page-XPX5XJZE.js → page-G7XSO4FD.js} +13 -12
  161. package/dist/{picker-3XF36MJF.js → picker-FPUC5UGM.js} +3 -3
  162. package/dist/{prepare-VMBIQYAM.js → prepare-WHMWP7BG.js} +21 -20
  163. package/dist/{prepare-VMBIQYAM.js.map → prepare-WHMWP7BG.js.map} +1 -1
  164. package/dist/{pretty-KSTZMBUF.js → pretty-VTJVXWRK.js} +15 -13
  165. package/dist/{pretty-KG6TMOEI.js → pretty-YVRRWBWN.js} +23 -16
  166. package/dist/{provider-LBX4IXGX.js → provider-JY2I3VLF.js} +3 -3
  167. package/dist/{release-VV3UTKE5.js → release-Z3ASYZ3S.js} +3 -3
  168. package/dist/{reporters-26H3N2KW.js → reporters-FSXJ42EB.js} +6 -5
  169. package/dist/{reporters-AQU4W3KY.js → reporters-G5R4SURQ.js} +6 -6
  170. package/dist/{reporters-FBYLPKD4.js → reporters-MHPY4HRA.js} +15 -14
  171. package/dist/run-FSYOYEPR.js +39 -0
  172. package/dist/sarif-HBQIDY7T.js +31 -0
  173. package/dist/sarif-RRUFJZUL.js +37 -0
  174. package/dist/{term-SI3VM6EM.js → term-ABHGACYE.js} +58 -109
  175. package/dist/term-ABHGACYE.js.map +1 -0
  176. package/dist/types-VMOT7RAL.js +12 -0
  177. package/dist/types-VMOT7RAL.js.map +1 -0
  178. package/dist/{validate-NQO7TFSN.js → validate-DXYUUGUD.js} +6 -6
  179. package/dist/validate-DXYUUGUD.js.map +1 -0
  180. package/package.json +1 -1
  181. package/plugin/manni/.claude-plugin/plugin.json +1 -1
  182. package/plugin/manni/skills/check/SKILL.md +2 -2
  183. package/plugin/manni/skills/evals/SKILL.md +1 -1
  184. package/plugin/manni/skills/fix/SKILL.md +95 -16
  185. package/plugin/manni/skills/setup/SKILL.md +1 -1
  186. package/shapes/graph/shapes-1.1.1.ttl +953 -0
  187. package/dist/batch-OB2FXT47.js +0 -46
  188. package/dist/build-4BL24BG3.js +0 -36
  189. package/dist/calibrate-AEDJ7N7G.js +0 -41
  190. package/dist/capture-TP3P4YNL.js +0 -38
  191. package/dist/check-5IYH42KS.js +0 -34
  192. package/dist/check-S55MH66H.js +0 -30
  193. package/dist/chunk-3HUCB4Z3.js.map +0 -1
  194. package/dist/chunk-3XGTNN3M.js.map +0 -1
  195. package/dist/chunk-52WO7ESI.js.map +0 -1
  196. package/dist/chunk-BMBAAPGN.js.map +0 -1
  197. package/dist/chunk-BQXY76JB.js.map +0 -1
  198. package/dist/chunk-CODWRUAD.js.map +0 -1
  199. package/dist/chunk-CWXZ2MRT.js.map +0 -1
  200. package/dist/chunk-DQOM3DEU.js.map +0 -1
  201. package/dist/chunk-EQ7E6HMG.js.map +0 -1
  202. package/dist/chunk-GWI6JPTT.js.map +0 -1
  203. package/dist/chunk-HIEGOW7X.js.map +0 -1
  204. package/dist/chunk-HY6ROJTH.js.map +0 -1
  205. package/dist/chunk-IGQMBHFY.js.map +0 -1
  206. package/dist/chunk-JEUFYSFQ.js.map +0 -1
  207. package/dist/chunk-JUL2PRQN.js.map +0 -1
  208. package/dist/chunk-LNGSE7V2.js.map +0 -1
  209. package/dist/chunk-LSFXNAHU.js.map +0 -1
  210. package/dist/chunk-MNH7QO4Z.js +0 -15
  211. package/dist/chunk-MNH7QO4Z.js.map +0 -1
  212. package/dist/chunk-N6A6DJUO.js.map +0 -1
  213. package/dist/chunk-NSAW7U42.js.map +0 -1
  214. package/dist/chunk-NTEYYYKL.js.map +0 -1
  215. package/dist/chunk-NWUXRV6N.js.map +0 -1
  216. package/dist/chunk-OBXCJZ6R.js.map +0 -1
  217. package/dist/chunk-OTJOBZJ5.js.map +0 -1
  218. package/dist/chunk-OYIWF3B2.js.map +0 -1
  219. package/dist/chunk-PA7CMQGD.js.map +0 -1
  220. package/dist/chunk-PCE7QHXJ.js.map +0 -1
  221. package/dist/chunk-SCLXVTFZ.js.map +0 -1
  222. package/dist/chunk-SE4JN5XN.js.map +0 -1
  223. package/dist/chunk-UKZNLVJW.js.map +0 -1
  224. package/dist/chunk-ULDV2LUI.js.map +0 -1
  225. package/dist/chunk-VNYXK7TM.js.map +0 -1
  226. package/dist/chunk-VYBYUQIP.js.map +0 -1
  227. package/dist/chunk-WVXCN5DS.js.map +0 -1
  228. package/dist/chunk-X4MPUD4B.js.map +0 -1
  229. package/dist/chunk-Y6M4JFKG.js +0 -117
  230. package/dist/chunk-Y6M4JFKG.js.map +0 -1
  231. package/dist/chunk-YZ4TJLZQ.js.map +0 -1
  232. package/dist/cli-7DETHSNW.js.map +0 -1
  233. package/dist/cli-DGFLJ2DD.js.map +0 -1
  234. package/dist/cli-H5LVGOVT.js.map +0 -1
  235. package/dist/cli-KYTCJYXK.js.map +0 -1
  236. package/dist/github-DJQ4MWNZ.js +0 -35
  237. package/dist/github-UWTDM2J2.js +0 -30
  238. package/dist/lint-O7XRHKFP.js +0 -34
  239. package/dist/list-OOOCLOAL.js +0 -35
  240. package/dist/list-OYQ5XPN2.js +0 -32
  241. package/dist/run-KUGTU3TT.js +0 -37
  242. package/dist/term-SI3VM6EM.js.map +0 -1
  243. package/dist/types-Y6TXHM7M.js +0 -10
  244. /package/dist/{batch-OB2FXT47.js.map → batch-OMDKRGUE.js.map} +0 -0
  245. /package/dist/{build-4BL24BG3.js.map → build-YCY5MUHA.js.map} +0 -0
  246. /package/dist/{calibrate-AEDJ7N7G.js.map → calibrate-RN2NJ4FS.js.map} +0 -0
  247. /package/dist/{capture-TP3P4YNL.js.map → capture-2WYROZKA.js.map} +0 -0
  248. /package/dist/{check-5IYH42KS.js.map → check-KRVWHF7E.js.map} +0 -0
  249. /package/dist/{check-LU5YC3L4.js.map → check-MR7IG7IP.js.map} +0 -0
  250. /package/dist/{check-S55MH66H.js.map → check-OIRJ6OBW.js.map} +0 -0
  251. /package/dist/{chunk-7RNONVHI.js.map → chunk-3EJVJDMX.js.map} +0 -0
  252. /package/dist/{chunk-CU57HT2E.js.map → chunk-6WJUZQQX.js.map} +0 -0
  253. /package/dist/{chunk-QKT67PFE.js.map → chunk-7XHW5DZA.js.map} +0 -0
  254. /package/dist/{chunk-TDCOKKMI.js.map → chunk-AL4HRKSZ.js.map} +0 -0
  255. /package/dist/{chunk-YQV75FIL.js.map → chunk-CFMI74TP.js.map} +0 -0
  256. /package/dist/{chunk-PCGBXHSE.js.map → chunk-FEEO7ET6.js.map} +0 -0
  257. /package/dist/{chunk-3O6U4ICM.js.map → chunk-GLQCSDFS.js.map} +0 -0
  258. /package/dist/{chunk-ZXRAE55H.js.map → chunk-IGRXQC3H.js.map} +0 -0
  259. /package/dist/{chunk-U6IHLEWT.js.map → chunk-JCTHXG33.js.map} +0 -0
  260. /package/dist/{chunk-6ZFJWUUH.js.map → chunk-JNMY7KZG.js.map} +0 -0
  261. /package/dist/{chunk-TQ3W6RKG.js.map → chunk-KCXQXKOL.js.map} +0 -0
  262. /package/dist/{chunk-OUAH7XF2.js.map → chunk-MAOX3524.js.map} +0 -0
  263. /package/dist/{chunk-TZOYZK2E.js.map → chunk-OZUPJB4J.js.map} +0 -0
  264. /package/dist/{chunk-OKMTUAWO.js.map → chunk-QSPH4F56.js.map} +0 -0
  265. /package/dist/{chunk-E6BVUDGY.js.map → chunk-SLGCRXHM.js.map} +0 -0
  266. /package/dist/{chunk-KE2F7QES.js.map → chunk-SVF3WCC7.js.map} +0 -0
  267. /package/dist/{chunk-VOXOBUTX.js.map → chunk-TXZJESES.js.map} +0 -0
  268. /package/dist/{chunk-7JPL3CUC.js.map → chunk-URGALOZY.js.map} +0 -0
  269. /package/dist/{chunk-PAU352SV.js.map → chunk-W4GTMOJW.js.map} +0 -0
  270. /package/dist/{chunk-3BVDFQ6Y.js.map → chunk-Y3GWQBJP.js.map} +0 -0
  271. /package/dist/{chunk-UQMLCIRX.js.map → chunk-Z6PZKXSP.js.map} +0 -0
  272. /package/dist/{cli-4JHQCPHU.js.map → cli-33E3B2FK.js.map} +0 -0
  273. /package/dist/{cli-AZKWTCFV.js.map → cli-MWUFAS2X.js.map} +0 -0
  274. /package/dist/{config-JJW75SBX.js.map → config-7I5CHHRZ.js.map} +0 -0
  275. /package/dist/{github-DJQ4MWNZ.js.map → github-DV57TW5L.js.map} +0 -0
  276. /package/dist/{github-UWTDM2J2.js.map → github-SGX2EARO.js.map} +0 -0
  277. /package/dist/{json-7WV7KL6H.js.map → json-5EQCGVCV.js.map} +0 -0
  278. /package/dist/{json-LCVPMEAM.js.map → json-SHPUCD64.js.map} +0 -0
  279. /package/dist/{lint-O7XRHKFP.js.map → lint-RE4DMI6E.js.map} +0 -0
  280. /package/dist/{list-OOOCLOAL.js.map → list-F56MEJXR.js.map} +0 -0
  281. /package/dist/{list-OYQ5XPN2.js.map → list-ZR3KY556.js.map} +0 -0
  282. /package/dist/{page-XPX5XJZE.js.map → page-G7XSO4FD.js.map} +0 -0
  283. /package/dist/{picker-3XF36MJF.js.map → picker-FPUC5UGM.js.map} +0 -0
  284. /package/dist/{pretty-KG6TMOEI.js.map → pretty-VTJVXWRK.js.map} +0 -0
  285. /package/dist/{pretty-KSTZMBUF.js.map → pretty-YVRRWBWN.js.map} +0 -0
  286. /package/dist/{provider-LBX4IXGX.js.map → provider-JY2I3VLF.js.map} +0 -0
  287. /package/dist/{release-VV3UTKE5.js.map → release-Z3ASYZ3S.js.map} +0 -0
  288. /package/dist/{reporters-26H3N2KW.js.map → reporters-FSXJ42EB.js.map} +0 -0
  289. /package/dist/{reporters-AQU4W3KY.js.map → reporters-G5R4SURQ.js.map} +0 -0
  290. /package/dist/{reporters-FBYLPKD4.js.map → reporters-MHPY4HRA.js.map} +0 -0
  291. /package/dist/{run-KUGTU3TT.js.map → run-FSYOYEPR.js.map} +0 -0
  292. /package/dist/{types-Y6TXHM7M.js.map → sarif-HBQIDY7T.js.map} +0 -0
  293. /package/dist/{validate-NQO7TFSN.js.map → sarif-RRUFJZUL.js.map} +0 -0
@@ -3,25 +3,37 @@ import {
3
3
  CITATIONS_KEY,
4
4
  GIT_UNAVAILABLE_COMMIT,
5
5
  SHALLOW_RECOMMIT,
6
+ arrivalOf,
6
7
  assertNoOrphanJoins,
7
8
  assertNoOrphans,
9
+ blobReader,
8
10
  buildSourceIndex,
9
11
  checkCitations,
10
12
  claimWords,
13
+ classifyCitation,
14
+ commitGraph,
15
+ createSourceCache,
11
16
  encryptSourcePath,
17
+ firstParentLog,
12
18
  gitClient,
13
19
  historyOf,
14
20
  joinHits,
21
+ loadCitationSidecars,
22
+ parseCiteConfig,
15
23
  prepareRun,
24
+ readCiteConfigFile,
16
25
  readSource,
17
26
  readTarget,
18
27
  resolveCiteRun,
28
+ resolveSourcePath,
19
29
  sayNotices,
20
30
  sharesSentence,
21
31
  sidecarsFor,
22
32
  sourceIndexFor,
33
+ tagCommits,
34
+ topLevel,
23
35
  wordShare
24
- } from "./chunk-DQOM3DEU.js";
36
+ } from "./chunk-6DYFWAZA.js";
25
37
  import {
26
38
  applyMarkerMoves,
27
39
  blockMatches,
@@ -30,11 +42,13 @@ import {
30
42
  noUnitAt,
31
43
  normalizeWhitespace,
32
44
  otherClaimSpans,
45
+ remedyFor,
46
+ shortCommit,
33
47
  shortSrc,
34
48
  spellAt,
35
49
  spellElsewhere,
36
50
  unitAt
37
- } from "./chunk-WVXCN5DS.js";
51
+ } from "./chunk-GZHBMMDC.js";
38
52
  import {
39
53
  ANY_FENCE,
40
54
  CiteError,
@@ -61,10 +75,10 @@ import {
61
75
  spellSource,
62
76
  tooWide,
63
77
  unitHolding
64
- } from "./chunk-X4MPUD4B.js";
78
+ } from "./chunk-UVLQRP6O.js";
65
79
  import {
66
80
  ensureEncryptionKey
67
- } from "./chunk-IGQMBHFY.js";
81
+ } from "./chunk-T62SFCQY.js";
68
82
  import {
69
83
  ENCRYPTION_KEY_ENV,
70
84
  STDIN_REQUIRES_AS,
@@ -84,18 +98,27 @@ import {
84
98
  splitLines,
85
99
  toBodyLines,
86
100
  toFileLines
87
- } from "./chunk-LNGSE7V2.js";
101
+ } from "./chunk-476DMDJ5.js";
88
102
  import {
89
103
  DocmetaError,
90
104
  STDIN_LABEL,
91
105
  STDIN_TOKEN,
106
+ classifyRef,
92
107
  extractorByName,
93
108
  locateFrontmatter,
94
109
  writeFileAtomic
95
- } from "./chunk-HY6ROJTH.js";
110
+ } from "./chunk-OFOIBV5J.js";
96
111
  import {
97
- isEncryptedValue
98
- } from "./chunk-OTJOBZJ5.js";
112
+ SEVERITIES
113
+ } from "./chunk-77AINBYM.js";
114
+ import {
115
+ hasPagePlaceholder,
116
+ isEncryptedValue,
117
+ pageManifestPath
118
+ } from "./chunk-B2242FYO.js";
119
+ import {
120
+ parseDuration
121
+ } from "./chunk-VM7VAFJW.js";
99
122
 
100
123
  // src/cite/commands/add.ts
101
124
  import { readFile as readFile2 } from "node:fs/promises";
@@ -617,7 +640,7 @@ function splice(text, options) {
617
640
  throw error;
618
641
  }
619
642
  }
620
- function itemLine(text, entry, index, join) {
643
+ function itemLine(text, entry, index, join3) {
621
644
  const lc = new LineCounter();
622
645
  const doc = parseDocument(text, { lineCounter: lc, uniqueKeys: false });
623
646
  if (doc.errors.length > 0) return void 0;
@@ -625,7 +648,7 @@ function itemLine(text, entry, index, join) {
625
648
  if (!isMap(root)) return void 0;
626
649
  const same = (key) => {
627
650
  const spelled = isScalar(key) ? String(key.value) : String(key);
628
- return join === "path" ? posix.normalize(spelled) === posix.normalize(entry) : spelled === entry;
651
+ return join3 === "path" ? posix.normalize(spelled) === posix.normalize(entry) : spelled === entry;
629
652
  };
630
653
  const pair = root.items.find((p) => same(p.key));
631
654
  const value = pair?.value;
@@ -650,7 +673,7 @@ async function readPageFile(path, label) {
650
673
  try {
651
674
  return await readFile2(path, "utf8");
652
675
  } catch (error) {
653
- if (isEnoent(error)) throw new CiteError(`File not found: "${label}".`);
676
+ if (isEnoent(error)) throw new CiteError(`File not found: "${label}". Check the path. Named paths resolve from the working directory.`);
654
677
  throw error;
655
678
  }
656
679
  }
@@ -990,8 +1013,457 @@ async function runAdd(opts) {
990
1013
  return result;
991
1014
  }
992
1015
 
1016
+ // src/cite/commands/history.ts
1017
+ import { realpath } from "node:fs/promises";
1018
+ import { join as join2, relative as relative3, resolve as resolve3, sep as sep2 } from "node:path";
1019
+
1020
+ // src/cite/core/timeline.ts
1021
+ import { mkdtemp, rm } from "node:fs/promises";
1022
+ import { tmpdir } from "node:os";
1023
+ import { dirname, isAbsolute, join, posix as posix2, relative as relative2, resolve as resolve2, sep } from "node:path";
1024
+ function trackRenames(commits, pages, start) {
1025
+ const paths = new Map(pages.map((page) => [page.label, page.path]));
1026
+ const renames = /* @__PURE__ */ new Map();
1027
+ for (let i = commits.length - 1; i > start; i--) {
1028
+ const from = /* @__PURE__ */ new Map();
1029
+ for (const change of commits[i]?.changes ?? []) {
1030
+ if (change.from !== void 0) from.set(change.path, change.from);
1031
+ }
1032
+ if (from.size === 0) continue;
1033
+ for (const [label, path] of paths) {
1034
+ const old = from.get(path);
1035
+ if (old === void 0) continue;
1036
+ const at = renames.get(i) ?? [];
1037
+ at.push({ label, to: path });
1038
+ renames.set(i, at);
1039
+ paths.set(label, old);
1040
+ }
1041
+ }
1042
+ return { paths, renames };
1043
+ }
1044
+ var toPosix2 = (path) => path.split(sep).join("/");
1045
+ var isFile = (leaf) => leaf.mode !== "120000" && leaf.mode !== "160000";
1046
+ function ruleOf(status) {
1047
+ if (status === "changed" || status === "missing" || status === "never-true") return `source-${status}`;
1048
+ return void 0;
1049
+ }
1050
+ async function buildTimeline(input) {
1051
+ const commits = await firstParentLog(input.top);
1052
+ const head = commits[commits.length - 1];
1053
+ const since = input.within === void 0 || head === void 0 ? void 0 : head.time - input.within;
1054
+ const bound = since === void 0 ? 0 : commits.findIndex((commit) => commit.time >= since);
1055
+ let start = bound === -1 ? commits.length : bound;
1056
+ const { paths, renames } = trackRenames(commits, input.pages, start);
1057
+ const blobs = blobReader(input.top);
1058
+ const snap = await mkdtemp(join(tmpdir(), "manni-cite-history-"));
1059
+ try {
1060
+ const walk = new Walk(input, blobs, snap, paths);
1061
+ const tree = /* @__PURE__ */ new Map();
1062
+ let unread = false;
1063
+ for (const [i, commit] of commits.entries()) {
1064
+ for (const change of commit.changes) {
1065
+ if (change.blob === void 0) tree.delete(change.path);
1066
+ else tree.set(change.path, { blob: change.blob, ...change.mode === void 0 ? {} : { mode: change.mode } });
1067
+ }
1068
+ if (i < start) continue;
1069
+ for (const { label, to } of renames.get(i) ?? []) paths.set(label, to);
1070
+ if (!await walk.read(i, commit, tree, i === start)) {
1071
+ walk.reset();
1072
+ start = i + 1;
1073
+ unread = true;
1074
+ }
1075
+ }
1076
+ return {
1077
+ commits,
1078
+ start,
1079
+ windows: walk.windows(),
1080
+ citations: walk.seen.size,
1081
+ encrypted: walk.encrypted.size,
1082
+ unread
1083
+ };
1084
+ } finally {
1085
+ blobs.close();
1086
+ await rm(snap, { recursive: true, force: true });
1087
+ }
1088
+ }
1089
+ var Walk = class {
1090
+ constructor(input, blobs, snap, paths) {
1091
+ this.input = input;
1092
+ this.blobs = blobs;
1093
+ this.snap = snap;
1094
+ this.paths = paths;
1095
+ const rel = toPosix2(relative2(input.top, input.root));
1096
+ this.prefix = rel === "" ? "" : `${rel}/`;
1097
+ }
1098
+ input;
1099
+ blobs;
1100
+ snap;
1101
+ paths;
1102
+ seen = /* @__PURE__ */ new Set();
1103
+ encrypted = /* @__PURE__ */ new Set();
1104
+ open = /* @__PURE__ */ new Map();
1105
+ closed = [];
1106
+ states = /* @__PURE__ */ new Map();
1107
+ pages = /* @__PURE__ */ new Map();
1108
+ /** What each scratch path holds now, by repository path. */
1109
+ written = /* @__PURE__ */ new Map();
1110
+ configBlob = null;
1111
+ config = null;
1112
+ prefix;
1113
+ /** Forget everything read so far: the history before this point is unread. */
1114
+ reset() {
1115
+ this.open.clear();
1116
+ this.closed = [];
1117
+ this.states.clear();
1118
+ this.pages.clear();
1119
+ this.seen.clear();
1120
+ this.encrypted.clear();
1121
+ this.configBlob = null;
1122
+ }
1123
+ windows() {
1124
+ const strip = ({ pinAtOpen: _, ...window }) => window;
1125
+ return [...this.closed, ...[...this.open.values()].map(strip)];
1126
+ }
1127
+ /** Read one commit. False when its config or citation manifests do not load. */
1128
+ async read(i, commit, tree, first) {
1129
+ const configBlob = this.input.config === void 0 ? void 0 : tree.get(this.input.config)?.blob;
1130
+ if (configBlob !== this.configBlob) {
1131
+ if (!await this.loadConfig(configBlob)) return false;
1132
+ this.configBlob = configBlob;
1133
+ this.pages.clear();
1134
+ }
1135
+ if (!await this.readPages(tree)) return false;
1136
+ await this.classify(i, commit, tree, first);
1137
+ return true;
1138
+ }
1139
+ async loadConfig(blob) {
1140
+ const at = this.input.config;
1141
+ if (blob === void 0 || at === void 0) {
1142
+ this.config = null;
1143
+ return true;
1144
+ }
1145
+ await this.sync(at, blob);
1146
+ const abs = join(this.snap, at);
1147
+ try {
1148
+ const file = await readCiteConfigFile(abs, dirname(abs));
1149
+ if (file !== null) parseCiteConfig(file.value, file.source);
1150
+ this.config = file;
1151
+ return true;
1152
+ } catch {
1153
+ return false;
1154
+ }
1155
+ }
1156
+ /** Write a repository path's blob to the scratch directory, or remove it. */
1157
+ async sync(path, blob) {
1158
+ if (this.written.get(path) === blob) return;
1159
+ const abs = join(this.snap, path);
1160
+ if (blob === void 0) {
1161
+ await rm(abs, { force: true });
1162
+ this.written.delete(path);
1163
+ return;
1164
+ }
1165
+ await writeFileAtomic(abs, await this.blobs.read(blob), { createParents: true });
1166
+ this.written.set(path, blob);
1167
+ }
1168
+ /** The repository paths of the manifests that may keep a page's citations at this commit. */
1169
+ manifestsFor(pagePath) {
1170
+ const config = this.config;
1171
+ if (config === null) return [];
1172
+ const out = [];
1173
+ for (const collection of config.collections) {
1174
+ for (const manifest of collection.externalMetadata) {
1175
+ if (manifest.keys !== void 0 && !manifest.keys.includes(CITATIONS_KEY)) continue;
1176
+ if (classifyRef(manifest.file).kind === "url") continue;
1177
+ const abs = hasPagePlaceholder(manifest.file) ? pageManifestPath(manifest.file, config.dir, join(this.snap, pagePath)) : { abs: isAbsolute(manifest.file) ? manifest.file : resolve2(config.dir, manifest.file) };
1178
+ if (!("abs" in abs)) continue;
1179
+ const rel = toPosix2(relative2(this.snap, abs.abs));
1180
+ if (rel.startsWith("../") || isAbsolute(rel)) continue;
1181
+ out.push(rel);
1182
+ }
1183
+ }
1184
+ return out;
1185
+ }
1186
+ /** Re-read the entries of every page whose text, manifests or config changed. False when the manifests do not load. */
1187
+ async readPages(tree) {
1188
+ const dirty = [];
1189
+ for (const page of this.input.pages) {
1190
+ const path = this.paths.get(page.label) ?? page.path;
1191
+ const blob = tree.get(path)?.blob;
1192
+ const manifests = blob === void 0 ? [] : this.manifestsFor(path);
1193
+ const key = [String(this.configBlob), path, String(blob), ...manifests.map((m) => `${m}:${String(tree.get(m)?.blob)}`)].join("\0");
1194
+ if (this.pages.get(page.label)?.key === key) continue;
1195
+ if (blob === void 0) this.pages.set(page.label, { key, entries: [] });
1196
+ else dirty.push({ label: page.label, path, blob, key, manifests });
1197
+ }
1198
+ if (dirty.length === 0) return true;
1199
+ const config = this.config;
1200
+ const base = join(this.snap, this.input.base);
1201
+ let sidecars = null;
1202
+ if (config !== null && config.collections.length > 0) {
1203
+ for (const manifest of new Set(dirty.flatMap((page) => page.manifests))) {
1204
+ await this.sync(manifest, tree.get(manifest)?.blob);
1205
+ }
1206
+ try {
1207
+ sidecars = await loadCitationSidecars({
1208
+ collections: config.collections,
1209
+ configDir: config.dir,
1210
+ base,
1211
+ configSource: config.source,
1212
+ ...this.input.key === void 0 ? {} : { key: this.input.key },
1213
+ pages: dirty.map((page) => join(this.snap, page.path))
1214
+ });
1215
+ } catch {
1216
+ return false;
1217
+ }
1218
+ }
1219
+ for (const page of dirty) {
1220
+ const label = toPosix2(relative2(base, join(this.snap, page.path)));
1221
+ const before = this.pages.get(page.label)?.entries ?? [];
1222
+ try {
1223
+ const content = await this.blobs.read(page.blob);
1224
+ const setup = await sidecars?.forPage(label, content, this.input.format);
1225
+ const owner = setup?.owner;
1226
+ const read = readPage(label, content, {
1227
+ ...this.input.format === void 0 ? {} : { format: this.input.format },
1228
+ ...owner === void 0 ? {} : { owned: { file: owner.file, collection: owner.collection } },
1229
+ ...owner === void 0 || setup?.citations === void 0 ? {} : { citations: setup.citations }
1230
+ });
1231
+ this.pages.set(page.label, { key: page.key, entries: read.citations });
1232
+ } catch {
1233
+ this.pages.set(page.label, { key: page.key, entries: before });
1234
+ }
1235
+ }
1236
+ return true;
1237
+ }
1238
+ /** The index and client a commit's classification reads through, built once per commit when first needed. */
1239
+ atCommit(commit, tree) {
1240
+ const { prefix } = this;
1241
+ let files;
1242
+ const leaf = (path) => {
1243
+ const found = tree.get(prefix + path);
1244
+ return found !== void 0 && isFile(found) ? found : void 0;
1245
+ };
1246
+ const index = {
1247
+ files: () => files ??= [...tree.entries()].filter(([path, found]) => path.startsWith(prefix) && isFile(found)).map(([path]) => path.slice(prefix.length)).sort(),
1248
+ has: (path) => leaf(path) !== void 0,
1249
+ read: async (path) => {
1250
+ const found = leaf(path);
1251
+ if (found === void 0) return void 0;
1252
+ try {
1253
+ return await this.blobs.read(found.blob);
1254
+ } catch {
1255
+ return void 0;
1256
+ }
1257
+ }
1258
+ };
1259
+ return {
1260
+ root: this.input.root,
1261
+ index,
1262
+ git: gitClient(this.input.root, commit.sha),
1263
+ cache: createSourceCache(),
1264
+ ...this.input.key === void 0 ? {} : { key: this.input.key }
1265
+ };
1266
+ }
1267
+ async classify(i, commit, tree, first) {
1268
+ let options;
1269
+ const present = /* @__PURE__ */ new Set();
1270
+ for (const page of this.input.pages) {
1271
+ const path = this.paths.get(page.label) ?? page.path;
1272
+ for (const entry of this.pages.get(page.label)?.entries ?? []) {
1273
+ const { source } = entry.citation;
1274
+ const id = entry.citation.id ?? `/citations/${String(entry.origin.index)}`;
1275
+ const key = `${page.label}\0${id}`;
1276
+ if (present.has(key)) continue;
1277
+ const range = sourceRange(source);
1278
+ const resolved = resolveSourcePath(range, this.input.key);
1279
+ if ("reason" in resolved && resolved.reason === "no-key") {
1280
+ this.encrypted.add(key);
1281
+ continue;
1282
+ }
1283
+ present.add(key);
1284
+ this.seen.add(key);
1285
+ const pin = JSON.stringify([source.file, source.lines ?? null, source.integrity]);
1286
+ const blob = "path" in resolved ? tree.get(this.prefix + resolved.path)?.blob : void 0;
1287
+ const held = this.states.get(key);
1288
+ let status;
1289
+ if (held !== void 0 && held.stable && held.pin === pin && held.blob === blob) {
1290
+ status = held.status;
1291
+ } else {
1292
+ options ??= this.atCommit(commit, tree);
1293
+ const end = await classifyCitation(entry, options);
1294
+ status = end.status;
1295
+ const own = (src) => parseSrc(src).path === range.path;
1296
+ const stable = status === "current" || status === "moved" && own(end.newSrc ?? "") || status === "moved-ambiguous" && (end.candidates ?? []).every(own);
1297
+ this.states.set(key, { pin, blob, status, stable });
1298
+ }
1299
+ const rule = ruleOf(status);
1300
+ const window = this.open.get(key);
1301
+ if (rule !== void 0 && window === void 0) {
1302
+ this.open.set(key, {
1303
+ page: page.label,
1304
+ id,
1305
+ index: entry.origin.index,
1306
+ source: spellSource(source),
1307
+ rule,
1308
+ opened: i,
1309
+ bounded: first,
1310
+ paths: [path],
1311
+ pinAtOpen: pin
1312
+ });
1313
+ } else if (rule !== void 0 && window !== void 0) {
1314
+ if (window.paths[window.paths.length - 1] !== path) window.paths.push(path);
1315
+ } else if (window !== void 0) {
1316
+ this.close(key, window, i, pin === window.pinAtOpen ? "source-restored" : "re-pinned");
1317
+ }
1318
+ }
1319
+ }
1320
+ for (const [key, window] of this.open) {
1321
+ if (!present.has(key)) this.close(key, window, i, "removed");
1322
+ }
1323
+ }
1324
+ close(key, window, at, by) {
1325
+ this.open.delete(key);
1326
+ const { pinAtOpen: _, ...done } = window;
1327
+ this.closed.push({ ...done, closed: { at, by } });
1328
+ }
1329
+ };
1330
+ function repoPath(top, abs) {
1331
+ return posix2.normalize(toPosix2(relative2(top, abs)));
1332
+ }
1333
+
1334
+ // src/cite/commands/history.ts
1335
+ var HISTORY_STDIN_REFUSAL = "cite history reads each page's past from git, and stdin has none. Name the page's path instead of -.";
1336
+ var HISTORY_SHALLOW_REFUSAL = "this clone is shallow, so cite history would start at its oldest commit. Fetch the full history with fetch-depth: 0, or git fetch --unshallow.";
1337
+ function notInGitRefusal(root) {
1338
+ return `cite history reads git, and ${root} is not inside a git repository.`;
1339
+ }
1340
+ function noCommitsRefusal(root) {
1341
+ return `cite history reads git, and ${root} has no commits yet.`;
1342
+ }
1343
+ function unreadNotice(sha) {
1344
+ return `history before ${shortCommit(sha)} is unread: its config or citation manifests do not load under this version. Windows open there are marked bounded.`;
1345
+ }
1346
+ function encryptedNotice(count) {
1347
+ const what = count === 1 ? "1 encrypted citation was" : `${String(count)} encrypted citations were`;
1348
+ return `${what} skipped: no encryption key. Set MANNI_ENCRYPTION_KEY or encryptionKey: to include them.`;
1349
+ }
1350
+ function isoOf(seconds) {
1351
+ return new Date(seconds * 1e3).toISOString().replace(/\.\d{3}Z$/, "Z");
1352
+ }
1353
+ var toPosix3 = (path) => path.split(sep2).join("/");
1354
+ async function runHistory(opts) {
1355
+ const within = opts.newerThan === void 0 ? void 0 : parseDuration(opts.newerThan, (message) => new CiteError(message)) / 1e3;
1356
+ if (opts.inputs.includes(STDIN_TOKEN)) throw new CiteError(HISTORY_STDIN_REFUSAL);
1357
+ const prepared = await prepareRun({ ...opts, checkSources: true }, "read", "read", { resolve: false });
1358
+ const { run, files } = prepared;
1359
+ const top = await topLevel(run.root);
1360
+ if (top === null) throw new CiteError(notInGitRefusal(run.root));
1361
+ if (await prepared.git.head() === null) throw new CiteError(noCommitsRefusal(run.root));
1362
+ if (await prepared.git.shallow?.()) throw new CiteError(HISTORY_SHALLOW_REFUSAL);
1363
+ const realTop = await realpath(top);
1364
+ const base = await realpath(run.base);
1365
+ const pages = await Promise.all(
1366
+ files.map(async (file) => ({ label: file, path: repoPath(realTop, await realpath(resolve3(run.base, file))) }))
1367
+ );
1368
+ const timeline = await buildTimeline({
1369
+ top: realTop,
1370
+ root: await realpath(run.root),
1371
+ pages,
1372
+ ...run.configPath === void 0 ? {} : { config: repoPath(realTop, await realpath(run.configPath)) },
1373
+ base: repoPath(realTop, base),
1374
+ ...run.key === void 0 ? {} : { key: run.key },
1375
+ ...prepared.forced === void 0 ? {} : { format: prepared.forced.name },
1376
+ ...within === void 0 ? {} : { within }
1377
+ });
1378
+ const { commits, start } = timeline;
1379
+ const head = commits[commits.length - 1];
1380
+ if (head === void 0) throw new Error("history walk returned no commits for an existing HEAD");
1381
+ if (timeline.unread) opts.onNotice?.(unreadNotice((commits[start] ?? head).sha));
1382
+ if (timeline.encrypted > 0) opts.onNotice?.(encryptedNotice(timeline.encrypted));
1383
+ const releasesOf = await releaseFinder(realTop);
1384
+ const severity = resolveSeverity(run.config?.severity);
1385
+ const at = (i) => {
1386
+ const commit = commits[i] ?? head;
1387
+ return { commit: commit.sha, date: isoOf(commit.time), subject: commit.subject };
1388
+ };
1389
+ const label = (path) => toPosix3(relative3(base, join2(realTop, path)));
1390
+ const staleWindow = (window, level) => {
1391
+ const opened = commits[window.opened] ?? head;
1392
+ const closed = window.closed === void 0 ? void 0 : commits[window.closed.at] ?? head;
1393
+ const home = pages.find((page) => page.label === window.page);
1394
+ if (home === void 0) throw new Error(`window for unknown page: ${window.page}`);
1395
+ const now = label(home.path);
1396
+ return {
1397
+ id: window.id,
1398
+ source: window.source,
1399
+ rule: window.rule,
1400
+ severity: level,
1401
+ opened: { ...at(window.opened), bounded: window.bounded },
1402
+ closed: window.closed === void 0 ? null : { ...at(window.closed.at), by: window.closed.by },
1403
+ seconds: (closed ?? head).time - opened.time,
1404
+ releases: releasesOf(opened.sha, closed?.sha),
1405
+ formerly: [...new Set(window.paths.map(label))].filter((path) => path !== now)
1406
+ };
1407
+ };
1408
+ const byPage = new Map(files.map((file) => [file, []]));
1409
+ const ordered = [...timeline.windows].sort((a, b) => a.opened - b.opened || a.index - b.index);
1410
+ for (const window of ordered) {
1411
+ const level = severity[window.rule];
1412
+ if (level === "off") continue;
1413
+ byPage.get(window.page)?.push(staleWindow(window, level));
1414
+ }
1415
+ const out = [...byPage.entries()].sort(([a], [b]) => a < b ? -1 : a > b ? 1 : 0).map(([file, windows]) => ({ file, windows }));
1416
+ const all = out.flatMap((page) => page.windows);
1417
+ const bySeverity = Object.fromEntries(SEVERITIES.map((s) => [s, 0]));
1418
+ for (const window of all) bySeverity[window.severity] += 1;
1419
+ const shipped = new Set(all.flatMap((window) => window.releases));
1420
+ const first = commits[start] ?? head;
1421
+ return {
1422
+ summary: {
1423
+ head: head.sha,
1424
+ walked: { commits: commits.length - start, from: isoOf(first.time), to: isoOf(head.time) },
1425
+ files: files.length,
1426
+ citations: timeline.citations,
1427
+ windows: all.length,
1428
+ open: all.filter((window) => window.closed === null).length,
1429
+ staleSeconds: all.reduce((sum, window) => sum + window.seconds, 0),
1430
+ bySeverity,
1431
+ releases: releasesOf.order([...shipped]),
1432
+ skipped: { encrypted: timeline.encrypted }
1433
+ },
1434
+ pages: out
1435
+ };
1436
+ }
1437
+ async function releaseFinder(top) {
1438
+ const graph = await commitGraph(top);
1439
+ const tags = (await tagCommits(top)).filter((tag) => graph.has(tag.commit));
1440
+ const ancestry = /* @__PURE__ */ new Map();
1441
+ const ancestorsOf = (commit) => {
1442
+ const held = ancestry.get(commit);
1443
+ if (held !== void 0) return held;
1444
+ const seen = /* @__PURE__ */ new Set();
1445
+ const stack = [commit];
1446
+ for (let next = stack.pop(); next !== void 0; next = stack.pop()) {
1447
+ if (seen.has(next)) continue;
1448
+ seen.add(next);
1449
+ stack.push(...graph.get(next)?.parents ?? []);
1450
+ }
1451
+ ancestry.set(commit, seen);
1452
+ return seen;
1453
+ };
1454
+ const time = (name) => graph.get(tags.find((tag) => tag.name === name)?.commit ?? "")?.time ?? 0;
1455
+ const order = (names) => [...names].sort((a, b) => time(a) - time(b) || (a < b ? -1 : a > b ? 1 : 0));
1456
+ const find = (opened, closed) => order(
1457
+ tags.filter((tag) => {
1458
+ const contains = ancestorsOf(tag.commit);
1459
+ return contains.has(opened) && (closed === void 0 || !contains.has(closed));
1460
+ }).map((tag) => tag.name)
1461
+ );
1462
+ return Object.assign(find, { order });
1463
+ }
1464
+
993
1465
  // src/cite/commands/remove.ts
994
- import { resolve as resolve2 } from "node:path";
1466
+ import { resolve as resolve4 } from "node:path";
995
1467
  var POINTER = /^\/citations\/(0|[1-9][0-9]*)$/;
996
1468
  function entryCount(n) {
997
1469
  return `${String(n)} ${n === 1 ? "entry" : "entries"}`;
@@ -1159,7 +1631,7 @@ async function runRemove(opts) {
1159
1631
  };
1160
1632
  if (usingStdin) await removeOne(STDIN_LABEL, opts.stdinContent ?? "");
1161
1633
  for (const file of files) {
1162
- await removeOne(file, await readTarget(run, file), resolve2(run.base, file));
1634
+ await removeOne(file, await readTarget(run, file), resolve4(run.base, file));
1163
1635
  }
1164
1636
  assertNoOrphanJoins(prepared, hits);
1165
1637
  const missing = only.find((value) => !matched.has(value));
@@ -1189,7 +1661,7 @@ async function runRemove(opts) {
1189
1661
  }
1190
1662
 
1191
1663
  // src/cite/commands/update.ts
1192
- import { resolve as resolve3 } from "node:path";
1664
+ import { resolve as resolve5 } from "node:path";
1193
1665
  function sayNoUnit(reason) {
1194
1666
  switch (reason) {
1195
1667
  case "outside":
@@ -1706,7 +2178,9 @@ async function runUpdate(opts) {
1706
2178
  because = "not-contained";
1707
2179
  }
1708
2180
  const now = await historyOf(git, head, path, range, pin, key, void 0);
1709
- return now.kind === "original" ? { commit: head, because } : void 0;
2181
+ if (now.kind !== "original") return void 0;
2182
+ const arrived = await arrivalOf(git, path, range, pin, key);
2183
+ return { commit: arrived ?? head, because };
1710
2184
  };
1711
2185
  const plansFor = async (result, entry, page, lines, lineNow, declined) => {
1712
2186
  const out = [];
@@ -2077,7 +2551,11 @@ async function runUpdate(opts) {
2077
2551
  }
2078
2552
  const turned = finding.index === void 0 ? void 0 : declined.get(finding.index);
2079
2553
  const why = turned?.rule === finding.rule ? turned.why : void 0;
2080
- return why === void 0 ? finding : { ...finding, message: `${finding.message} ${why}` };
2554
+ if (why === void 0) return finding;
2555
+ const result = report.citations.find((r) => r.origin.index === finding.index);
2556
+ const remedy = remedyFor(finding.rule, result);
2557
+ const said = remedy !== void 0 && finding.message.endsWith(` ${remedy}`) ? finding.message.slice(0, -(remedy.length + 1)) : finding.message;
2558
+ return { ...finding, message: `${said} ${why}` };
2081
2559
  });
2082
2560
  const diff = after === content ? "" : unifiedDiff(label, content, after);
2083
2561
  const written = after !== content && path !== void 0 && opts.dryRun !== true;
@@ -2097,7 +2575,7 @@ async function runUpdate(opts) {
2097
2575
  const reports = [];
2098
2576
  if (usingStdin) reports.push(await updateOne(STDIN_LABEL, opts.stdinContent ?? ""));
2099
2577
  for (const file of files) {
2100
- reports.push(await updateOne(file, await readTarget(run, file), resolve3(run.base, file)));
2578
+ reports.push(await updateOne(file, await readTarget(run, file), resolve5(run.base, file)));
2101
2579
  }
2102
2580
  assertNoOrphanJoins(prepared, hits);
2103
2581
  const write = opts.dryRun !== true;
@@ -2157,7 +2635,8 @@ export {
2157
2635
  splice,
2158
2636
  itemLine,
2159
2637
  runAdd,
2638
+ runHistory,
2160
2639
  runRemove,
2161
2640
  runUpdate
2162
2641
  };
2163
- //# sourceMappingURL=chunk-YZ4TJLZQ.js.map
2642
+ //# sourceMappingURL=chunk-YT5HKJWV.js.map