@moberg_hr/work-tree 2.9.3 → 2.11.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 (372) hide show
  1. package/dist/{account-NG75VLRU.js → account-Q5Y3YKI7.js} +83 -100
  2. package/dist/account-Q5Y3YKI7.js.map +1 -0
  3. package/dist/{add-repo-EDU3QEYI.js → add-repo-L4ZTGBLO.js} +35 -31
  4. package/dist/{add-repo-EDU3QEYI.js.map → add-repo-L4ZTGBLO.js.map} +1 -1
  5. package/dist/{answer-MHOJ2J6S.js → answer-GNR4ZBWV.js} +18 -15
  6. package/dist/{answer-MHOJ2J6S.js.map → answer-GNR4ZBWV.js.map} +1 -1
  7. package/dist/{attach-37JOJ4C3.js → attach-QNSDKRW7.js} +27 -21
  8. package/dist/{attach-37JOJ4C3.js.map → attach-QNSDKRW7.js.map} +1 -1
  9. package/dist/bin.js +5 -5
  10. package/dist/{block-D5CAR53T.js → block-3YUIMA62.js} +23 -15
  11. package/dist/block-3YUIMA62.js.map +1 -0
  12. package/dist/{broadcast-LLYHUWXA.js → broadcast-DR3JFINO.js} +13 -11
  13. package/dist/{broadcast-LLYHUWXA.js.map → broadcast-DR3JFINO.js.map} +1 -1
  14. package/dist/{catchup-2SL3JGA7.js → catchup-YG2UOZBL.js} +19 -17
  15. package/dist/{catchup-2SL3JGA7.js.map → catchup-YG2UOZBL.js.map} +1 -1
  16. package/dist/{chunk-P6BHOAQG.js → chunk-246OTVRR.js} +2 -2
  17. package/dist/{chunk-KSUOVFO3.js → chunk-26YZYL77.js} +16 -9
  18. package/dist/chunk-26YZYL77.js.map +1 -0
  19. package/dist/{chunk-TPSFJSO7.js → chunk-2KN5ECHJ.js} +13 -10
  20. package/dist/chunk-2KN5ECHJ.js.map +1 -0
  21. package/dist/chunk-2QLLPZ2L.js +59 -0
  22. package/dist/chunk-2QLLPZ2L.js.map +1 -0
  23. package/dist/chunk-2ZQRD73B.js +376 -0
  24. package/dist/chunk-2ZQRD73B.js.map +1 -0
  25. package/dist/{chunk-GNGXYXBC.js → chunk-33XSEAHO.js} +2 -2
  26. package/dist/{chunk-IPGH7TXJ.js → chunk-4CNBSPNL.js} +2 -2
  27. package/dist/{chunk-J36ULZBO.js → chunk-4K4S53KX.js} +2 -2
  28. package/dist/chunk-5PAMO6OG.js +9 -0
  29. package/dist/{chunk-NWIVXGSL.js.map → chunk-5PAMO6OG.js.map} +1 -1
  30. package/dist/chunk-63ZLPXRL.js +199 -0
  31. package/dist/chunk-63ZLPXRL.js.map +1 -0
  32. package/dist/{chunk-P2HOLCBF.js → chunk-6UTH3A76.js} +18 -2
  33. package/dist/{chunk-P2HOLCBF.js.map → chunk-6UTH3A76.js.map} +1 -1
  34. package/dist/{chunk-5QGCF3PS.js → chunk-7DUGVGUZ.js} +2 -2
  35. package/dist/chunk-7E5XPDKX.js +22 -0
  36. package/dist/chunk-7E5XPDKX.js.map +1 -0
  37. package/dist/{chunk-6FVYSW3E.js → chunk-7NNGYM3G.js} +21 -6
  38. package/dist/chunk-7NNGYM3G.js.map +1 -0
  39. package/dist/{chunk-DQCUYCMX.js → chunk-7NNOGTMC.js} +3 -3
  40. package/dist/{chunk-OMIMK3LB.js → chunk-7OFVXQSM.js} +2 -2
  41. package/dist/chunk-7QNVFVG6.js +196 -0
  42. package/dist/chunk-7QNVFVG6.js.map +1 -0
  43. package/dist/chunk-7RHC5U7X.js +1578 -0
  44. package/dist/chunk-7RHC5U7X.js.map +1 -0
  45. package/dist/{chunk-KUCMJHQW.js → chunk-AHYCZUPI.js} +2 -2
  46. package/dist/chunk-B6MWNZCN.js +415 -0
  47. package/dist/chunk-B6MWNZCN.js.map +1 -0
  48. package/dist/{chunk-CCTALU3C.js → chunk-BLGCU4HT.js} +2 -2
  49. package/dist/{chunk-RCGFHJM7.js → chunk-CBCOVIXZ.js} +2 -2
  50. package/dist/{chunk-WTQ2QCAG.js → chunk-CDYCZ3PR.js} +4 -5
  51. package/dist/chunk-CDYCZ3PR.js.map +1 -0
  52. package/dist/{chunk-HCVONKJI.js → chunk-CR4LUAP4.js} +15 -17
  53. package/dist/{chunk-HCVONKJI.js.map → chunk-CR4LUAP4.js.map} +1 -1
  54. package/dist/{chunk-ZXHMC7UO.js → chunk-D2J3AD6L.js} +3 -5
  55. package/dist/chunk-D2J3AD6L.js.map +1 -0
  56. package/dist/chunk-DAKJTB6N.js +76 -0
  57. package/dist/chunk-DAKJTB6N.js.map +1 -0
  58. package/dist/{chunk-3N3UQEC4.js → chunk-DCCC7LEP.js} +4 -3
  59. package/dist/chunk-DCCC7LEP.js.map +1 -0
  60. package/dist/{chunk-S3BAD4IR.js → chunk-DGVCN7HB.js} +2 -2
  61. package/dist/chunk-DMGNJ73M.js +84 -0
  62. package/dist/chunk-DMGNJ73M.js.map +1 -0
  63. package/dist/{chunk-QL36KN7X.js → chunk-DYQQLUSB.js} +3 -3
  64. package/dist/{chunk-IWJXFNM4.js → chunk-DZ4LX2EK.js} +16 -24
  65. package/dist/chunk-DZ4LX2EK.js.map +1 -0
  66. package/dist/{chunk-3C3BKZ3H.js → chunk-EDIHBLZY.js} +51 -29
  67. package/dist/chunk-EDIHBLZY.js.map +1 -0
  68. package/dist/chunk-EL3XL2OC.js +150 -0
  69. package/dist/chunk-EL3XL2OC.js.map +1 -0
  70. package/dist/{chunk-T7AFYEQ7.js → chunk-F2CDUWZU.js} +5 -5
  71. package/dist/chunk-F2NOCGMA.js +243 -0
  72. package/dist/chunk-F2NOCGMA.js.map +1 -0
  73. package/dist/chunk-FGPXMAYU.js +25 -0
  74. package/dist/chunk-FGPXMAYU.js.map +1 -0
  75. package/dist/{chunk-ICJPVSRY.js → chunk-FLHMFRZB.js} +51 -51
  76. package/dist/chunk-FLHMFRZB.js.map +1 -0
  77. package/dist/{chunk-CLBQ7ZC4.js → chunk-FR7B7QH6.js} +3 -3
  78. package/dist/chunk-FZHFD2AY.js +27 -0
  79. package/dist/chunk-FZHFD2AY.js.map +1 -0
  80. package/dist/{chunk-7OUIZ2YQ.js → chunk-G4QUJO7W.js} +56 -58
  81. package/dist/chunk-G4QUJO7W.js.map +1 -0
  82. package/dist/{chunk-26OVU2AE.js → chunk-G4ZR5YZL.js} +8 -8
  83. package/dist/{chunk-P4EQWC5W.js → chunk-GG4VKPAX.js} +2 -2
  84. package/dist/{chunk-INQQGV2G.js → chunk-GZNF6762.js} +4 -4
  85. package/dist/{chunk-QHTXLCG7.js → chunk-H3LP3Z4U.js} +19 -13
  86. package/dist/chunk-H3LP3Z4U.js.map +1 -0
  87. package/dist/{chunk-6E2I2FBJ.js → chunk-HJKYE57I.js} +22 -22
  88. package/dist/{chunk-CYWI3ZW7.js → chunk-I5FZXDCO.js} +4 -4
  89. package/dist/{chunk-5WM24P5N.js → chunk-I6MILNM5.js} +2 -2
  90. package/dist/chunk-I6MILNM5.js.map +1 -0
  91. package/dist/{chunk-BSP2Z7B7.js → chunk-IQ4MITHC.js} +6 -6
  92. package/dist/chunk-J3GEINBH.js +307 -0
  93. package/dist/chunk-J3GEINBH.js.map +1 -0
  94. package/dist/{chunk-WXE7D44E.js → chunk-JCFCEJ2D.js} +8 -8
  95. package/dist/chunk-JCFCEJ2D.js.map +1 -0
  96. package/dist/{chunk-WXMWZRBH.js → chunk-JF25PSYF.js} +24 -8
  97. package/dist/chunk-JF25PSYF.js.map +1 -0
  98. package/dist/{chunk-SG5LUMGE.js → chunk-JNBMANFM.js} +6 -3
  99. package/dist/chunk-JNBMANFM.js.map +1 -0
  100. package/dist/chunk-JVE2JFLV.js +15 -0
  101. package/dist/chunk-JVE2JFLV.js.map +1 -0
  102. package/dist/{chunk-RGUSVBGN.js → chunk-JVHHSKBJ.js} +2 -2
  103. package/dist/chunk-KSVYR4G2.js +47 -0
  104. package/dist/chunk-KSVYR4G2.js.map +1 -0
  105. package/dist/{chunk-RYNBBSLY.js → chunk-KWHHB737.js} +6 -8
  106. package/dist/chunk-KWHHB737.js.map +1 -0
  107. package/dist/{chunk-MG5TTLYZ.js → chunk-LHM3GB5K.js} +3 -3
  108. package/dist/{chunk-PSUJZUYX.js → chunk-LM2T5OR3.js} +3 -2
  109. package/dist/{chunk-GRLKPVTP.js → chunk-LQNHIMJM.js} +56 -81
  110. package/dist/chunk-LQNHIMJM.js.map +1 -0
  111. package/dist/{chunk-UBOKRHNV.js → chunk-MKJH2D4V.js} +2 -2
  112. package/dist/{chunk-HMK3INUS.js → chunk-MQCDFSVF.js} +2 -2
  113. package/dist/{chunk-VJ7SVDED.js → chunk-MSJWQC7H.js} +6 -4
  114. package/dist/chunk-MSJWQC7H.js.map +1 -0
  115. package/dist/chunk-MXOHW4U2.js +187 -0
  116. package/dist/chunk-MXOHW4U2.js.map +1 -0
  117. package/dist/{chunk-VUAVPBFR.js → chunk-N4W34U3I.js} +78 -60
  118. package/dist/chunk-N4W34U3I.js.map +1 -0
  119. package/dist/{chunk-72IBYKIY.js → chunk-NFWSJFYY.js} +16 -5
  120. package/dist/chunk-NFWSJFYY.js.map +1 -0
  121. package/dist/{chunk-2JNW2AQ2.js → chunk-O5ZJY5BT.js} +32 -4
  122. package/dist/chunk-O5ZJY5BT.js.map +1 -0
  123. package/dist/{chunk-CMO5YUZR.js → chunk-OY46QHLX.js} +4 -4
  124. package/dist/{chunk-OTAZOIXK.js → chunk-PKQROEFP.js} +2 -2
  125. package/dist/{chunk-4NITDMDH.js → chunk-PPZP7CA7.js} +9 -186
  126. package/dist/chunk-PPZP7CA7.js.map +1 -0
  127. package/dist/chunk-QBI6K23L.js +50 -0
  128. package/dist/chunk-QBI6K23L.js.map +1 -0
  129. package/dist/{chunk-AAYWHIIT.js → chunk-QLFJNYBV.js} +9 -56
  130. package/dist/chunk-QLFJNYBV.js.map +1 -0
  131. package/dist/{chunk-PRDRRU2B.js → chunk-R5JCCRGD.js} +5 -5
  132. package/dist/{chunk-X4AXKO3A.js → chunk-RGLIW45S.js} +2 -2
  133. package/dist/{chunk-YYBXQBW2.js → chunk-RUYTU2WJ.js} +17 -3
  134. package/dist/chunk-RUYTU2WJ.js.map +1 -0
  135. package/dist/chunk-S3CTXKSN.js +17 -0
  136. package/dist/chunk-S3CTXKSN.js.map +1 -0
  137. package/dist/chunk-SJBEIYLK.js +16 -0
  138. package/dist/chunk-SJBEIYLK.js.map +1 -0
  139. package/dist/{chunk-WC534PXU.js → chunk-SPP7MA3D.js} +36 -25
  140. package/dist/chunk-SPP7MA3D.js.map +1 -0
  141. package/dist/{chunk-RFINYWID.js → chunk-TEL27NRC.js} +16 -6
  142. package/dist/chunk-TEL27NRC.js.map +1 -0
  143. package/dist/{chunk-ATED7SAH.js → chunk-TEVCBUEN.js} +36 -25
  144. package/dist/chunk-TEVCBUEN.js.map +1 -0
  145. package/dist/{chunk-QSOEMCWQ.js → chunk-URGHBFB3.js} +18 -11
  146. package/dist/chunk-URGHBFB3.js.map +1 -0
  147. package/dist/{chunk-S3FMTEFR.js → chunk-VAMLU5VH.js} +13 -6
  148. package/dist/chunk-VAMLU5VH.js.map +1 -0
  149. package/dist/{chunk-ZI2KXTKM.js → chunk-VJ5XMYXE.js} +6 -10
  150. package/dist/chunk-VJ5XMYXE.js.map +1 -0
  151. package/dist/{chunk-QEVYCCKD.js → chunk-VRQKIIC2.js} +12 -34
  152. package/dist/chunk-VRQKIIC2.js.map +1 -0
  153. package/dist/{chunk-63VY4YJM.js → chunk-W7MGB3Q2.js} +34 -9
  154. package/dist/chunk-W7MGB3Q2.js.map +1 -0
  155. package/dist/{chunk-HEPBANFJ.js → chunk-X3RHLYGI.js} +93 -196
  156. package/dist/chunk-X3RHLYGI.js.map +1 -0
  157. package/dist/chunk-YKQLHFY4.js +1478 -0
  158. package/dist/chunk-YKQLHFY4.js.map +1 -0
  159. package/dist/chunk-YPXFDJ76.js +71 -0
  160. package/dist/chunk-YPXFDJ76.js.map +1 -0
  161. package/dist/{chunk-XVNRP7XE.js → chunk-YQBBFX7D.js} +11 -11
  162. package/dist/{chunk-37XQIG7F.js → chunk-ZG2M4ECW.js} +569 -55
  163. package/dist/chunk-ZG2M4ECW.js.map +1 -0
  164. package/dist/{cleanup-5PSLKZLF.js → cleanup-X7G66SPY.js} +49 -37
  165. package/dist/{cleanup-5PSLKZLF.js.map → cleanup-X7G66SPY.js.map} +1 -1
  166. package/dist/cli-RJVX6HVT.js +19 -0
  167. package/dist/{command-hook-installer-7Q7UD7AU.js → command-hook-installer-GMQ4IVDE.js} +3 -3
  168. package/dist/{completion-MXX5TRIV.js → completion-IAH7WRKJ.js} +3 -2
  169. package/dist/{completion-MXX5TRIV.js.map → completion-IAH7WRKJ.js.map} +1 -1
  170. package/dist/{config-6MSITKGB.js → config-ZBU5PHMG.js} +18 -15
  171. package/dist/{config-6MSITKGB.js.map → config-ZBU5PHMG.js.map} +1 -1
  172. package/dist/{diff-Q7MV6YGJ.js → diff-ADSD4SNQ.js} +25 -22
  173. package/dist/{diff-Q7MV6YGJ.js.map → diff-ADSD4SNQ.js.map} +1 -1
  174. package/dist/{digest-KUMVYXKZ.js → digest-ORN6JFNE.js} +15 -13
  175. package/dist/{digest-KUMVYXKZ.js.map → digest-ORN6JFNE.js.map} +1 -1
  176. package/dist/{fork-OFENISEM.js → fork-VWHAU76U.js} +44 -31
  177. package/dist/{fork-OFENISEM.js.map → fork-VWHAU76U.js.map} +1 -1
  178. package/dist/{history-5WKRWARZ.js → history-PP7RHA2V.js} +14 -12
  179. package/dist/{hook-ARS32DG2.js → hook-6AL5LIQO.js} +56 -22
  180. package/dist/hook-6AL5LIQO.js.map +1 -0
  181. package/dist/{hydrate-LCT6DVB3.js → hydrate-JW5MIWLZ.js} +16 -14
  182. package/dist/{hydrate-LCT6DVB3.js.map → hydrate-JW5MIWLZ.js.map} +1 -1
  183. package/dist/{init-FJKPEY5N.js → init-SIIKJF3K.js} +29 -21
  184. package/dist/{init-FJKPEY5N.js.map → init-SIIKJF3K.js.map} +1 -1
  185. package/dist/install-skills-KS6N4U6L.js +22 -0
  186. package/dist/install-skills-bin.js +10 -8
  187. package/dist/install-skills-bin.js.map +1 -1
  188. package/dist/{list-GTKP5FAW.js → list-UTQF7KHP.js} +17 -15
  189. package/dist/{list-GTKP5FAW.js.map → list-UTQF7KHP.js.map} +1 -1
  190. package/dist/{move-GOCLEFGZ.js → move-P6WOVUGF.js} +35 -26
  191. package/dist/{move-GOCLEFGZ.js.map → move-P6WOVUGF.js.map} +1 -1
  192. package/dist/{note-B7TQBXQF.js → note-GEFCZKMT.js} +16 -14
  193. package/dist/{note-B7TQBXQF.js.map → note-GEFCZKMT.js.map} +1 -1
  194. package/dist/{overlaps-UKQHIJMU.js → overlaps-QMI2RJSG.js} +23 -13
  195. package/dist/{overlaps-UKQHIJMU.js.map → overlaps-QMI2RJSG.js.map} +1 -1
  196. package/dist/{pin-UZZCDK7M.js → pin-ZALBX2XK.js} +16 -14
  197. package/dist/{pin-UZZCDK7M.js.map → pin-ZALBX2XK.js.map} +1 -1
  198. package/dist/{pr-NU2ME2XW.js → pr-D3EZ7C5H.js} +48 -23
  199. package/dist/pr-D3EZ7C5H.js.map +1 -0
  200. package/dist/{prune-IZGEYTSB.js → prune-ZCOBL7IB.js} +47 -35
  201. package/dist/{prune-IZGEYTSB.js.map → prune-ZCOBL7IB.js.map} +1 -1
  202. package/dist/{pty-host-AWDIKPQN.js → pty-host-UCM6GV42.js} +104 -40
  203. package/dist/pty-host-UCM6GV42.js.map +1 -0
  204. package/dist/{read-U6GBGA5E.js → read-NHRSGZI4.js} +15 -13
  205. package/dist/{read-U6GBGA5E.js.map → read-NHRSGZI4.js.map} +1 -1
  206. package/dist/{recent-2DUMLUDG.js → recent-V4JVL4Y2.js} +36 -27
  207. package/dist/recent-V4JVL4Y2.js.map +1 -0
  208. package/dist/{remove-OXUP4O33.js → remove-YNO2I3HR.js} +51 -39
  209. package/dist/{remove-OXUP4O33.js.map → remove-YNO2I3HR.js.map} +1 -1
  210. package/dist/{restart-QEW4DJC3.js → restart-6YKAD7QQ.js} +19 -17
  211. package/dist/{restart-QEW4DJC3.js.map → restart-6YKAD7QQ.js.map} +1 -1
  212. package/dist/{resume-K45IT4QO.js → resume-PNZ7BRXJ.js} +36 -21
  213. package/dist/resume-PNZ7BRXJ.js.map +1 -0
  214. package/dist/review-now-HHQIBVUS.js +22 -0
  215. package/dist/review-now-HHQIBVUS.js.map +1 -0
  216. package/dist/{run-42LORGPS.js → run-3QYP7GBN.js} +23 -17
  217. package/dist/run-3QYP7GBN.js.map +1 -0
  218. package/dist/{screen-2TLIUH3G.js → screen-I6N6FKMF.js} +16 -14
  219. package/dist/{screen-2TLIUH3G.js.map → screen-I6N6FKMF.js.map} +1 -1
  220. package/dist/{search-7E4B2KX6.js → search-MLLK3ZCW.js} +12 -10
  221. package/dist/{search-7E4B2KX6.js.map → search-MLLK3ZCW.js.map} +1 -1
  222. package/dist/{section-OVA5VD7L.js → section-EQOZ36FS.js} +16 -14
  223. package/dist/{section-OVA5VD7L.js.map → section-EQOZ36FS.js.map} +1 -1
  224. package/dist/{send-BJY5CYLO.js → send-LET73FB6.js} +21 -18
  225. package/dist/send-LET73FB6.js.map +1 -0
  226. package/dist/{sessions-4A24ZORW.js → sessions-MDOJJZCK.js} +60 -25
  227. package/dist/sessions-MDOJJZCK.js.map +1 -0
  228. package/dist/{snooze-WIVKB3GH.js → snooze-TNA7QTXS.js} +15 -13
  229. package/dist/{snooze-WIVKB3GH.js.map → snooze-TNA7QTXS.js.map} +1 -1
  230. package/dist/{start-G6GR533S.js → start-OV6LZJ2V.js} +16 -14
  231. package/dist/{start-G6GR533S.js.map → start-OV6LZJ2V.js.map} +1 -1
  232. package/dist/{state-S3DGLT4J.js → state-BR43ONIH.js} +18 -6
  233. package/dist/state-BR43ONIH.js.map +1 -0
  234. package/dist/{status-BTAWY6JQ.js → status-HDDGCX4J.js} +40 -15
  235. package/dist/status-HDDGCX4J.js.map +1 -0
  236. package/dist/{statusline-WLXEU5DM.js → statusline-WKKYCH7O.js} +13 -12
  237. package/dist/{statusline-WLXEU5DM.js.map → statusline-WKKYCH7O.js.map} +1 -1
  238. package/dist/{statusline-hook-OVWHHFBV.js → statusline-hook-K7KPN2H6.js} +6 -5
  239. package/dist/{statusline-hook-OVWHHFBV.js.map → statusline-hook-K7KPN2H6.js.map} +1 -1
  240. package/dist/{stop-FN6EPFJ4.js → stop-3TJWZBJB.js} +16 -14
  241. package/dist/{stop-FN6EPFJ4.js.map → stop-3TJWZBJB.js.map} +1 -1
  242. package/dist/{sync-T3BSHX6Q.js → sync-67AOBEYR.js} +47 -35
  243. package/dist/{sync-T3BSHX6Q.js.map → sync-67AOBEYR.js.map} +1 -1
  244. package/dist/{time-5CH5O5MZ.js → time-F6SLY6HR.js} +17 -15
  245. package/dist/{time-5CH5O5MZ.js.map → time-F6SLY6HR.js.map} +1 -1
  246. package/dist/{time-actions-XEUQ3UF7.js → time-actions-YOXF5WC7.js} +6 -5
  247. package/dist/{timesheet-FMQKPS5S.js → timesheet-QUEDQSJ2.js} +26 -17
  248. package/dist/{timesheet-FMQKPS5S.js.map → timesheet-QUEDQSJ2.js.map} +1 -1
  249. package/dist/{todo-23COLGR2.js → todo-TALKJYK6.js} +5 -5
  250. package/dist/{tree-T33VU473.js → tree-FOOQBNVW.js} +66 -47
  251. package/dist/tree-FOOQBNVW.js.map +1 -0
  252. package/dist/{update-PJRSKQZ2.js → update-5O3I5P4N.js} +26 -16
  253. package/dist/{update-PJRSKQZ2.js.map → update-5O3I5P4N.js.map} +1 -1
  254. package/dist/{usage-TL66LWO4.js → usage-DVKHDT5J.js} +15 -13
  255. package/dist/{usage-TL66LWO4.js.map → usage-DVKHDT5J.js.map} +1 -1
  256. package/dist/version-TVT6GSRF.js +115 -0
  257. package/dist/version-TVT6GSRF.js.map +1 -0
  258. package/dist/{wait-YIEJO6YM.js → wait-5HZZPKNM.js} +18 -15
  259. package/dist/{wait-YIEJO6YM.js.map → wait-5HZZPKNM.js.map} +1 -1
  260. package/dist/wd-bin.js +7 -7
  261. package/dist/web/assets/{PtyView-DnDd6jLI.js → PtyView-DIGlBtjg.js} +2 -2
  262. package/dist/web/assets/{PtyView-DnDd6jLI.js.map → PtyView-DIGlBtjg.js.map} +1 -1
  263. package/dist/web/assets/index-CpqiTeqj.css +1 -0
  264. package/dist/web/assets/index-Cx0PMo6D.js +126 -0
  265. package/dist/web/assets/index-Cx0PMo6D.js.map +1 -0
  266. package/dist/web/index.html +2 -2
  267. package/dist/{web-IYUNJMQD.js → web-T7UPV3QY.js} +5158 -1822
  268. package/dist/web-T7UPV3QY.js.map +1 -0
  269. package/npm-shrinkwrap.json +2 -2
  270. package/package.json +1 -1
  271. package/plugins/work-tree/skills/wd-review/SKILL.md +1 -1
  272. package/plugins/work-tree/skills/work-sessions/SKILL.md +2 -2
  273. package/dist/account-NG75VLRU.js.map +0 -1
  274. package/dist/block-D5CAR53T.js.map +0 -1
  275. package/dist/chunk-2JNW2AQ2.js.map +0 -1
  276. package/dist/chunk-37XQIG7F.js.map +0 -1
  277. package/dist/chunk-3C3BKZ3H.js.map +0 -1
  278. package/dist/chunk-3GIH4WTA.js +0 -314
  279. package/dist/chunk-3GIH4WTA.js.map +0 -1
  280. package/dist/chunk-3N3UQEC4.js.map +0 -1
  281. package/dist/chunk-4NITDMDH.js.map +0 -1
  282. package/dist/chunk-5WM24P5N.js.map +0 -1
  283. package/dist/chunk-63VY4YJM.js.map +0 -1
  284. package/dist/chunk-6FVYSW3E.js.map +0 -1
  285. package/dist/chunk-72IBYKIY.js.map +0 -1
  286. package/dist/chunk-7OUIZ2YQ.js.map +0 -1
  287. package/dist/chunk-AAYWHIIT.js.map +0 -1
  288. package/dist/chunk-ATED7SAH.js.map +0 -1
  289. package/dist/chunk-GRLKPVTP.js.map +0 -1
  290. package/dist/chunk-HEPBANFJ.js.map +0 -1
  291. package/dist/chunk-ICJPVSRY.js.map +0 -1
  292. package/dist/chunk-IWJXFNM4.js.map +0 -1
  293. package/dist/chunk-KSUOVFO3.js.map +0 -1
  294. package/dist/chunk-NWIVXGSL.js +0 -9
  295. package/dist/chunk-PTWVOT7A.js +0 -551
  296. package/dist/chunk-PTWVOT7A.js.map +0 -1
  297. package/dist/chunk-QEVYCCKD.js.map +0 -1
  298. package/dist/chunk-QHTXLCG7.js.map +0 -1
  299. package/dist/chunk-QSOEMCWQ.js.map +0 -1
  300. package/dist/chunk-RCYI7SRA.js +0 -15
  301. package/dist/chunk-RCYI7SRA.js.map +0 -1
  302. package/dist/chunk-RFINYWID.js.map +0 -1
  303. package/dist/chunk-RYNBBSLY.js.map +0 -1
  304. package/dist/chunk-S3FMTEFR.js.map +0 -1
  305. package/dist/chunk-SG5LUMGE.js.map +0 -1
  306. package/dist/chunk-TPSFJSO7.js.map +0 -1
  307. package/dist/chunk-VJ7SVDED.js.map +0 -1
  308. package/dist/chunk-VTLDYH3C.js +0 -227
  309. package/dist/chunk-VTLDYH3C.js.map +0 -1
  310. package/dist/chunk-VUAVPBFR.js.map +0 -1
  311. package/dist/chunk-WC534PXU.js.map +0 -1
  312. package/dist/chunk-WTQ2QCAG.js.map +0 -1
  313. package/dist/chunk-WXE7D44E.js.map +0 -1
  314. package/dist/chunk-WXMWZRBH.js.map +0 -1
  315. package/dist/chunk-YYBXQBW2.js.map +0 -1
  316. package/dist/chunk-ZDMJPEBO.js +0 -31
  317. package/dist/chunk-ZDMJPEBO.js.map +0 -1
  318. package/dist/chunk-ZI2KXTKM.js.map +0 -1
  319. package/dist/chunk-ZXHMC7UO.js.map +0 -1
  320. package/dist/cli-AF7636FA.js +0 -19
  321. package/dist/hook-ARS32DG2.js.map +0 -1
  322. package/dist/install-skills-UYAFVJBA.js +0 -20
  323. package/dist/pr-NU2ME2XW.js.map +0 -1
  324. package/dist/pty-host-AWDIKPQN.js.map +0 -1
  325. package/dist/recent-2DUMLUDG.js.map +0 -1
  326. package/dist/resume-K45IT4QO.js.map +0 -1
  327. package/dist/run-42LORGPS.js.map +0 -1
  328. package/dist/send-BJY5CYLO.js.map +0 -1
  329. package/dist/sessions-4A24ZORW.js.map +0 -1
  330. package/dist/state-S3DGLT4J.js.map +0 -1
  331. package/dist/status-BTAWY6JQ.js.map +0 -1
  332. package/dist/tree-T33VU473.js.map +0 -1
  333. package/dist/web/assets/index-DxozAoUO.css +0 -1
  334. package/dist/web/assets/index-InmdAx6g.js +0 -120
  335. package/dist/web/assets/index-InmdAx6g.js.map +0 -1
  336. package/dist/web-IYUNJMQD.js.map +0 -1
  337. /package/dist/{chunk-P6BHOAQG.js.map → chunk-246OTVRR.js.map} +0 -0
  338. /package/dist/{chunk-GNGXYXBC.js.map → chunk-33XSEAHO.js.map} +0 -0
  339. /package/dist/{chunk-IPGH7TXJ.js.map → chunk-4CNBSPNL.js.map} +0 -0
  340. /package/dist/{chunk-J36ULZBO.js.map → chunk-4K4S53KX.js.map} +0 -0
  341. /package/dist/{chunk-5QGCF3PS.js.map → chunk-7DUGVGUZ.js.map} +0 -0
  342. /package/dist/{chunk-DQCUYCMX.js.map → chunk-7NNOGTMC.js.map} +0 -0
  343. /package/dist/{chunk-OMIMK3LB.js.map → chunk-7OFVXQSM.js.map} +0 -0
  344. /package/dist/{chunk-KUCMJHQW.js.map → chunk-AHYCZUPI.js.map} +0 -0
  345. /package/dist/{chunk-CCTALU3C.js.map → chunk-BLGCU4HT.js.map} +0 -0
  346. /package/dist/{chunk-RCGFHJM7.js.map → chunk-CBCOVIXZ.js.map} +0 -0
  347. /package/dist/{chunk-S3BAD4IR.js.map → chunk-DGVCN7HB.js.map} +0 -0
  348. /package/dist/{chunk-QL36KN7X.js.map → chunk-DYQQLUSB.js.map} +0 -0
  349. /package/dist/{chunk-T7AFYEQ7.js.map → chunk-F2CDUWZU.js.map} +0 -0
  350. /package/dist/{chunk-CLBQ7ZC4.js.map → chunk-FR7B7QH6.js.map} +0 -0
  351. /package/dist/{chunk-26OVU2AE.js.map → chunk-G4ZR5YZL.js.map} +0 -0
  352. /package/dist/{chunk-P4EQWC5W.js.map → chunk-GG4VKPAX.js.map} +0 -0
  353. /package/dist/{chunk-INQQGV2G.js.map → chunk-GZNF6762.js.map} +0 -0
  354. /package/dist/{chunk-6E2I2FBJ.js.map → chunk-HJKYE57I.js.map} +0 -0
  355. /package/dist/{chunk-CYWI3ZW7.js.map → chunk-I5FZXDCO.js.map} +0 -0
  356. /package/dist/{chunk-BSP2Z7B7.js.map → chunk-IQ4MITHC.js.map} +0 -0
  357. /package/dist/{chunk-RGUSVBGN.js.map → chunk-JVHHSKBJ.js.map} +0 -0
  358. /package/dist/{chunk-MG5TTLYZ.js.map → chunk-LHM3GB5K.js.map} +0 -0
  359. /package/dist/{chunk-PSUJZUYX.js.map → chunk-LM2T5OR3.js.map} +0 -0
  360. /package/dist/{chunk-UBOKRHNV.js.map → chunk-MKJH2D4V.js.map} +0 -0
  361. /package/dist/{chunk-HMK3INUS.js.map → chunk-MQCDFSVF.js.map} +0 -0
  362. /package/dist/{chunk-CMO5YUZR.js.map → chunk-OY46QHLX.js.map} +0 -0
  363. /package/dist/{chunk-OTAZOIXK.js.map → chunk-PKQROEFP.js.map} +0 -0
  364. /package/dist/{chunk-PRDRRU2B.js.map → chunk-R5JCCRGD.js.map} +0 -0
  365. /package/dist/{chunk-X4AXKO3A.js.map → chunk-RGLIW45S.js.map} +0 -0
  366. /package/dist/{chunk-XVNRP7XE.js.map → chunk-YQBBFX7D.js.map} +0 -0
  367. /package/dist/{cli-AF7636FA.js.map → cli-RJVX6HVT.js.map} +0 -0
  368. /package/dist/{command-hook-installer-7Q7UD7AU.js.map → command-hook-installer-GMQ4IVDE.js.map} +0 -0
  369. /package/dist/{history-5WKRWARZ.js.map → history-PP7RHA2V.js.map} +0 -0
  370. /package/dist/{install-skills-UYAFVJBA.js.map → install-skills-KS6N4U6L.js.map} +0 -0
  371. /package/dist/{time-actions-XEUQ3UF7.js.map → time-actions-YOXF5WC7.js.map} +0 -0
  372. /package/dist/{todo-23COLGR2.js.map → todo-TALKJYK6.js.map} +0 -0
@@ -8,30 +8,31 @@ import {
8
8
  sessionIdFor,
9
9
  tx,
10
10
  withDb
11
- } from "./chunk-YYBXQBW2.js";
11
+ } from "./chunk-RUYTU2WJ.js";
12
12
  import {
13
13
  agentFor,
14
14
  agentOf,
15
15
  agentToRecord,
16
16
  readJsonlTail
17
- } from "./chunk-VUAVPBFR.js";
17
+ } from "./chunk-N4W34U3I.js";
18
18
  import {
19
19
  loadConfig
20
- } from "./chunk-2JNW2AQ2.js";
20
+ } from "./chunk-O5ZJY5BT.js";
21
21
  import {
22
22
  bootTime,
23
23
  isPidAlive,
24
24
  killTree,
25
25
  processName
26
- } from "./chunk-4NITDMDH.js";
26
+ } from "./chunk-63ZLPXRL.js";
27
27
  import {
28
+ shellEnv,
28
29
  spawn_default
29
- } from "./chunk-RCYI7SRA.js";
30
+ } from "./chunk-EL3XL2OC.js";
30
31
  import {
31
32
  atomicWriteFile,
32
33
  ensureFile,
33
34
  withFileLock
34
- } from "./chunk-ZXHMC7UO.js";
35
+ } from "./chunk-D2J3AD6L.js";
35
36
  import {
36
37
  report
37
38
  } from "./chunk-AU27USPZ.js";
@@ -41,8 +42,8 @@ import {
41
42
  } from "./chunk-6THUVP6T.js";
42
43
 
43
44
  // src/core/sessions/history.ts
44
- import fs10 from "fs";
45
- import path10 from "path";
45
+ import fs11 from "fs";
46
+ import path11 from "path";
46
47
 
47
48
  // src/core/sessions/session-activity.ts
48
49
  var ACTIVE_MS = 3e4;
@@ -136,7 +137,7 @@ async function allocateFreePort(seedKey, config, sessions, probe = isPortFree) {
136
137
  }
137
138
 
138
139
  // src/core/sessions/session-store.ts
139
- import fs9 from "fs";
140
+ import fs10 from "fs";
140
141
 
141
142
  // src/core/api-types.ts
142
143
  var ARCHIVED_BY = ["you", "shipped", "pr-merged", "cleanup"];
@@ -409,7 +410,9 @@ var RANK = {
409
410
  closed: 9
410
411
  };
411
412
  function prStageOf(repos) {
412
- const withPr = repos.filter((r) => !!r.pr);
413
+ const withPr = repos.flatMap(
414
+ (r) => r.pr ? [{ name: r.name, pr: r.pr }, ...(r.also ?? []).map((a) => ({ name: r.name, pr: a.pr }))] : []
415
+ );
413
416
  if (!withPr.length) return null;
414
417
  const open = withPr.filter((r) => r.pr.state === "OPEN");
415
418
  const shown = open.length ? open : withPr;
@@ -436,6 +439,23 @@ function prStageOf(repos) {
436
439
  key: `${kind}:${shown.map((r) => `${r.name}@${r.pr.headSha}`).join(",")}`
437
440
  };
438
441
  }
442
+ function stageRepos(repos) {
443
+ return repos.map((r) => {
444
+ const all = [
445
+ ...r.pr ? [{ ...r.branch ? { branch: r.branch } : {}, pr: r.pr }] : [],
446
+ ...(r.otherPrs ?? []).filter((o) => !r.pr || o.pr.url !== r.pr.url)
447
+ ];
448
+ const open = all.filter((x) => x.pr.state === "OPEN").sort((a, b) => b.pr.number - a.pr.number);
449
+ const chosen = open[0] ?? all.find((x) => x.pr === r.pr) ?? [...all].sort((a, b) => b.pr.number - a.pr.number)[0] ?? null;
450
+ return {
451
+ name: r.name,
452
+ pr: chosen?.pr ?? null,
453
+ ...chosen?.branch ? { branch: chosen.branch } : {},
454
+ also: open.filter((x) => x !== chosen),
455
+ earlier: all.filter((x) => x !== chosen && x.pr.state !== "OPEN").sort((a, b) => b.pr.number - a.pr.number)
456
+ };
457
+ });
458
+ }
439
459
  function cleanStageRef(raw) {
440
460
  const o = raw;
441
461
  if (!o || typeof o !== "object" || typeof o.key !== "string" || !o.key || o.key.length > 2e3) return null;
@@ -1224,6 +1244,7 @@ function restoreArchivedTranscripts(s, root = archiveRoot(), restoreDir = (x) =>
1224
1244
  import fs5 from "fs";
1225
1245
  import path4 from "path";
1226
1246
  import zlib2 from "zlib";
1247
+ import { promisify } from "util";
1227
1248
 
1228
1249
  // src/core/archive/archive-search.ts
1229
1250
  var SNIPPET_CHARS = 220;
@@ -1269,12 +1290,311 @@ function matchingLines(raw, words, jsonWords, max, entries) {
1269
1290
  return out;
1270
1291
  }
1271
1292
 
1293
+ // src/core/hosts/github/origin.ts
1294
+ var GITHUB_THREAD_ID = /^PRRT_[A-Za-z0-9_-]{4,120}$/;
1295
+ function onGithub(origin) {
1296
+ return /(^|[@/.])github\.com[:/]/i.test(origin);
1297
+ }
1298
+ function githubRepoId(origin) {
1299
+ if (!onGithub(origin)) return null;
1300
+ const m = /[:/]([^/:]+)\/([^/]+?)(?:\.git)?\/?$/.exec(origin.trim());
1301
+ return m ? `${m[1]}/${m[2]}`.toLowerCase() : null;
1302
+ }
1303
+ function parseGithubPrUrl(text) {
1304
+ const m = /^(?:https?:\/\/)?(?:www\.)?github\.com\/([\w.-]+)\/([\w.-]+)\/pull\/(\d+)(?:[/?#].*)?$/i.exec(text.trim());
1305
+ if (!m) return null;
1306
+ const number = Number(m[3]);
1307
+ return {
1308
+ repoId: `${m[1]}/${m[2]}`.toLowerCase(),
1309
+ number,
1310
+ url: `https://github.com/${m[1]}/${m[2]}/pull/${number}`,
1311
+ label: `${m[2]}#${number}`
1312
+ };
1313
+ }
1314
+
1315
+ // src/core/hosts/azure/origin.ts
1316
+ var dec = (s) => {
1317
+ try {
1318
+ return decodeURIComponent(s);
1319
+ } catch {
1320
+ return s;
1321
+ }
1322
+ };
1323
+ var strip = (s) => s.replace(/\.git$/, "").replace(/\/+$/, "");
1324
+ var ORG_NAME = /^[A-Za-z0-9][A-Za-z0-9-]{0,49}$/;
1325
+ var PART_NAME = /^[^\\/:*?"'<>;#$*{},+=[\]|%&^!\x00-\x1f\x7f]{1,128}$/;
1326
+ var azureNameOk = (org, project, repo) => ORG_NAME.test(org) && PART_NAME.test(project) && PART_NAME.test(repo) && project.trim() === project && repo.trim() === repo;
1327
+ function azureOrgOf(orgUrl) {
1328
+ const m = /^https:\/\/dev\.azure\.com\/([^/]+)$/.exec(orgUrl) ?? /^https:\/\/([^./]+)\.visualstudio\.com$/.exec(orgUrl);
1329
+ return m && ORG_NAME.test(m[1]) ? m[1] : null;
1330
+ }
1331
+ function repoOf(org, project, repo, orgUrl) {
1332
+ const r = { org: dec(org), project: dec(project), repo: dec(strip(repo)), orgUrl };
1333
+ return azureNameOk(r.org, r.project, r.repo) && azureOrgOf(orgUrl) === r.org ? r : null;
1334
+ }
1335
+ function parseAzureOrigin(origin) {
1336
+ const o = origin.trim();
1337
+ let m = /^https?:\/\/(?:[^@/]+@)?dev\.azure\.com\/([^/]+)\/([^/]+)\/_git\/([^/?#]+)/i.exec(o);
1338
+ if (m) return repoOf(m[1], m[2], m[3], `https://dev.azure.com/${m[1]}`);
1339
+ m = /^https?:\/\/(?:[^@/]+@)?([^./]+)\.visualstudio\.com\/(?:DefaultCollection\/)?([^/]+)\/_git\/([^/?#]+)/i.exec(o);
1340
+ if (m) return repoOf(m[1], m[2], m[3], `https://${m[1]}.visualstudio.com`);
1341
+ m = /^(?:ssh:\/\/)?[^@]+@ssh\.dev\.azure\.com[:/]v3\/([^/]+)\/([^/]+)\/([^/]+)$/i.exec(o);
1342
+ if (m) return repoOf(m[1], m[2], m[3], `https://dev.azure.com/${m[1]}`);
1343
+ m = /^(?:ssh:\/\/)?[^@]+@vs-ssh\.visualstudio\.com[:/]v3\/([^/]+)\/([^/]+)\/([^/]+)$/i.exec(o);
1344
+ if (m) return repoOf(m[1], m[2], m[3], `https://${m[1]}.visualstudio.com`);
1345
+ return null;
1346
+ }
1347
+ var onAzure = (origin) => parseAzureOrigin(origin) !== null;
1348
+ function azureRepoId(origin) {
1349
+ const r = parseAzureOrigin(origin);
1350
+ return r ? `${r.org}/${r.project}/${r.repo}`.toLowerCase() : null;
1351
+ }
1352
+ function azureWebUrl(r) {
1353
+ return `${r.orgUrl}/${encodeURIComponent(r.project)}/_git/${encodeURIComponent(r.repo)}`;
1354
+ }
1355
+ function parseAzurePrUrl(text) {
1356
+ const t = text.trim();
1357
+ const m = /^(https?:\/\/[^?#]+\/_git\/[^/?#]+)\/pullrequest\/(\d+)(?:[/?#].*)?$/i.exec(t);
1358
+ if (!m) return null;
1359
+ const repo = parseAzureOrigin(m[1]);
1360
+ if (!repo) return null;
1361
+ const number = Number(m[2]);
1362
+ return {
1363
+ repoId: `${repo.org}/${repo.project}/${repo.repo}`.toLowerCase(),
1364
+ number,
1365
+ url: `${azureWebUrl(repo)}/pullrequest/${number}`,
1366
+ label: `${repo.repo}!${number}`,
1367
+ repo
1368
+ };
1369
+ }
1370
+ var AZURE_THREAD_ID = /^AZT_[A-Za-z0-9_-]{2,400}_\d{1,9}_\d{1,9}$/;
1371
+ var b64url = (s) => {
1372
+ const bytes = new TextEncoder().encode(s);
1373
+ let bin = "";
1374
+ for (const b of bytes) bin += String.fromCharCode(b);
1375
+ return btoa(bin).replace(/\+/g, "-").replace(/\//g, "_").replace(/=+$/, "");
1376
+ };
1377
+ var unb64url = (s) => {
1378
+ const bin = atob(s.replace(/-/g, "+").replace(/_/g, "/"));
1379
+ return new TextDecoder().decode(Uint8Array.from(bin, (c) => c.charCodeAt(0)));
1380
+ };
1381
+ function azureThreadRepoId(id) {
1382
+ const t = parseAzureThreadId(id);
1383
+ const org = t ? azureOrgOf(t.repo.orgUrl) : null;
1384
+ return t && org ? `${org}/${t.repo.project}/${t.repo.repo}`.toLowerCase() : null;
1385
+ }
1386
+ function azureThreadId(r, pr, thread) {
1387
+ return `AZT_${b64url(JSON.stringify([r.orgUrl, r.project, r.repo]))}_${pr}_${thread}`;
1388
+ }
1389
+ function parseAzureThreadId(id) {
1390
+ if (!AZURE_THREAD_ID.test(id)) return null;
1391
+ const m = /^AZT_(.+)_(\d+)_(\d+)$/.exec(id);
1392
+ if (!m) return null;
1393
+ try {
1394
+ const v = JSON.parse(unb64url(m[1]));
1395
+ if (!Array.isArray(v) || v.length !== 3 || !v.every((x) => typeof x === "string")) return null;
1396
+ const [orgUrl, project, repo] = v;
1397
+ const back = parseAzureOrigin(azureWebUrl({ orgUrl, project, repo }));
1398
+ if (!back || back.orgUrl !== orgUrl || back.project !== project || back.repo !== repo) return null;
1399
+ return { repo: { orgUrl, project, repo }, pr: Number(m[2]), thread: Number(m[3]) };
1400
+ } catch {
1401
+ return null;
1402
+ }
1403
+ }
1404
+
1405
+ // src/core/hosts/github/commands.ts
1406
+ var githubCommands = {
1407
+ host: "GitHub",
1408
+ cli: "gh",
1409
+ view: (n) => `gh pr view ${n}`,
1410
+ comments: (n) => `gh pr view ${n} --comments`,
1411
+ diff: (n) => `gh pr diff ${n}`,
1412
+ checks: (n) => `gh pr checks ${n}`,
1413
+ failedLog: "gh run view <run-id> --log-failed",
1414
+ checkout: (n, detach) => `gh pr checkout ${n}${detach ? " --detach" : ""}`,
1415
+ create: "gh pr create"
1416
+ };
1417
+
1418
+ // src/core/hosts/azure/commands.ts
1419
+ var azureCommands = {
1420
+ host: "Azure DevOps",
1421
+ cli: "az",
1422
+ view: (n) => `az repos pr show --id ${n}`,
1423
+ comments: (n) => `az repos pr show --id ${n} (and its threads: az devops invoke --area git --resource pullRequestThreads)`,
1424
+ diff: (n) => `git fetch origin refs/pull/${n}/merge && git diff FETCH_HEAD^1 FETCH_HEAD`,
1425
+ checks: (n) => `az repos pr policy list --id ${n}`,
1426
+ failedLog: "az pipelines runs show --id <run-id>",
1427
+ checkout: (n) => `az repos pr checkout --id ${n}`,
1428
+ create: "az repos pr create"
1429
+ };
1430
+
1431
+ // src/core/hosts/commands.ts
1432
+ var TABLE = { github: githubCommands, azure: azureCommands };
1433
+ var DEFAULT_HOST = "github";
1434
+ function commandsFor(hostId) {
1435
+ return TABLE[hostId ?? DEFAULT_HOST] ?? TABLE[DEFAULT_HOST];
1436
+ }
1437
+ function hostName(hostId) {
1438
+ return commandsFor(hostId).host;
1439
+ }
1440
+
1441
+ // src/core/hosts/links.ts
1442
+ var PARSERS = [
1443
+ { host: "github", parse: parseGithubPrUrl },
1444
+ {
1445
+ host: "azure",
1446
+ parse: (t) => {
1447
+ const l = parseAzurePrUrl(t);
1448
+ return l ? { repoId: l.repoId, number: l.number, url: l.url, label: l.label } : null;
1449
+ }
1450
+ }
1451
+ ];
1452
+ function parsePrLink(text) {
1453
+ for (const p of PARSERS) {
1454
+ const link = p.parse(text);
1455
+ if (link) return { ...link, host: p.host };
1456
+ }
1457
+ return null;
1458
+ }
1459
+
1460
+ // src/core/pr/session-prs.ts
1461
+ var MAX_SESSION_PRS = 100;
1462
+ var isIso = (v) => typeof v === "string" && Number.isFinite(Date.parse(v));
1463
+ var SOURCES = ["agent", "branch"];
1464
+ function isShipPr(v) {
1465
+ const p = v;
1466
+ return !!p && typeof p === "object" && typeof p.number === "number" && typeof p.url === "string" && (p.state === "OPEN" || p.state === "MERGED" || p.state === "CLOSED") && typeof p.isDraft === "boolean" && typeof p.mergeStateStatus === "string" && (p.checks === "pass" || p.checks === "fail" || p.checks === "pending" || p.checks === "none") && typeof p.headSha === "string";
1467
+ }
1468
+ function cleanSessionPrs(raw) {
1469
+ const o = raw;
1470
+ if (!o || typeof o !== "object" || !Array.isArray(o.prs)) return null;
1471
+ const prs = [];
1472
+ for (const x of o.prs) {
1473
+ const r = x;
1474
+ if (!r || typeof r !== "object" || typeof r.url !== "string" || !r.url) continue;
1475
+ if (typeof r.number !== "number" || !Number.isInteger(r.number) || r.number <= 0) continue;
1476
+ if (typeof r.repoId !== "string" || !isIso(r.firstSeen) || !Array.isArray(r.sources)) continue;
1477
+ const sources = r.sources.filter((s) => SOURCES.includes(s));
1478
+ if (!sources.length) continue;
1479
+ prs.push({
1480
+ url: r.url,
1481
+ number: r.number,
1482
+ repoId: r.repoId,
1483
+ ...typeof r.branch === "string" && r.branch ? { branch: r.branch } : {},
1484
+ sources,
1485
+ firstSeen: r.firstSeen,
1486
+ ...isShipPr(r.final) && r.final.state !== "OPEN" ? { final: r.final } : {}
1487
+ });
1488
+ }
1489
+ return { prs, ...isIso(o.scanned) ? { scanned: o.scanned } : {} };
1490
+ }
1491
+ function normal(s) {
1492
+ const link = parsePrLink(s.url);
1493
+ if (link && link.number === s.number) return { url: link.url, repoId: link.repoId };
1494
+ return { url: s.url, repoId: s.repoId ?? "" };
1495
+ }
1496
+ function withPrSightings(rec, seen, now, opts = {}) {
1497
+ const base = rec ?? { prs: [] };
1498
+ let changed = !rec || opts.scanned === true && !base.scanned;
1499
+ const prs = base.prs.map((p) => ({ ...p, sources: [...p.sources] }));
1500
+ for (const s of seen) {
1501
+ if (!Number.isInteger(s.number) || s.number <= 0 || !s.url) continue;
1502
+ const { url, repoId } = normal(s);
1503
+ const p = prs.find((x) => x.url === url);
1504
+ if (!p) {
1505
+ prs.push({
1506
+ url,
1507
+ number: s.number,
1508
+ repoId,
1509
+ ...s.branch ? { branch: s.branch } : {},
1510
+ sources: [s.source],
1511
+ firstSeen: isIso(s.at) ? s.at : now.toISOString()
1512
+ });
1513
+ changed = true;
1514
+ continue;
1515
+ }
1516
+ if (!p.sources.includes(s.source)) {
1517
+ p.sources.push(s.source);
1518
+ changed = true;
1519
+ }
1520
+ if (s.branch && !p.branch) {
1521
+ p.branch = s.branch;
1522
+ changed = true;
1523
+ }
1524
+ if (!p.repoId && repoId) {
1525
+ p.repoId = repoId;
1526
+ changed = true;
1527
+ }
1528
+ if (isIso(s.at) && Date.parse(s.at) < Date.parse(p.firstSeen)) {
1529
+ p.firstSeen = s.at;
1530
+ changed = true;
1531
+ }
1532
+ }
1533
+ if (!changed) return base;
1534
+ return { prs: trim(prs), ...base.scanned ? { scanned: base.scanned } : opts.scanned ? { scanned: now.toISOString() } : {} };
1535
+ }
1536
+ function trim(prs) {
1537
+ if (prs.length <= MAX_SESSION_PRS) return prs;
1538
+ const finished = prs.filter((p) => p.final).sort((a, b) => Date.parse(b.firstSeen) - Date.parse(a.firstSeen));
1539
+ const drop = new Set(finished.slice(Math.max(0, MAX_SESSION_PRS - (prs.length - finished.length))));
1540
+ return prs.filter((p) => !drop.has(p));
1541
+ }
1542
+ function withPrLooks(rec, looks) {
1543
+ let changed = false;
1544
+ const prs = rec.prs.map((p) => {
1545
+ const look = looks.find((l) => l.url === p.url || l.pr.url === p.url);
1546
+ if (!look) return p;
1547
+ const next = { ...p };
1548
+ if (look.branch && !p.branch) {
1549
+ next.branch = look.branch;
1550
+ changed = true;
1551
+ }
1552
+ if (look.pr.state !== "OPEN" && !p.final) {
1553
+ next.final = look.pr;
1554
+ changed = true;
1555
+ }
1556
+ return next;
1557
+ });
1558
+ return changed ? { ...rec, prs } : rec;
1559
+ }
1560
+ function readRow2(d, sessionId) {
1561
+ const row = d.prepare("SELECT data FROM session_prs WHERE session_id = ?").get(sessionId);
1562
+ return row ? cleanSessionPrs(json.parse(row.data)) : null;
1563
+ }
1564
+ function writeRow(d, sessionId, rec) {
1565
+ d.prepare("INSERT OR REPLACE INTO session_prs (session_id, data) VALUES (?, ?)").run(sessionId, JSON.stringify(rec));
1566
+ }
1567
+ function readSessionPrs(sessionId) {
1568
+ return withDb((d) => readRow2(d, sessionId));
1569
+ }
1570
+ function noteSessionPrs(sessionId, seen, now = /* @__PURE__ */ new Date(), opts = {}) {
1571
+ return tx((d) => {
1572
+ const old = readRow2(d, sessionId);
1573
+ const next = withPrSightings(old, seen, now, opts);
1574
+ if (next !== old) writeRow(d, sessionId, next);
1575
+ return next;
1576
+ });
1577
+ }
1578
+ function notePrLooks(sessionId, looks) {
1579
+ if (!looks.length) return;
1580
+ tx((d) => {
1581
+ const old = readRow2(d, sessionId);
1582
+ if (!old) return;
1583
+ const next = withPrLooks(old, looks);
1584
+ if (next !== old) writeRow(d, sessionId, next);
1585
+ });
1586
+ }
1587
+
1272
1588
  // src/core/conversations/conversation-store.ts
1589
+ var gunzip = promisify(zlib2.gunzip);
1273
1590
  var conversationRoot = () => path4.join(getConfigDir(), "conversations");
1274
1591
  var conversationDirFor = (id, root = conversationRoot()) => path4.join(root, id);
1275
- async function syncConversation(s, root = conversationRoot(), sources = agentOf(s).conversation?.files(s) ?? []) {
1276
- const dir = conversationDirFor(sessionIdFor(s), root);
1592
+ async function syncConversation(s, root = conversationRoot(), sources = agentOf(s).conversation?.files(s) ?? [], prLinks = agentOf(s).conversation?.prLinks) {
1593
+ const id = sessionIdFor(s);
1594
+ const dir = conversationDirFor(id, root);
1277
1595
  const out = { files: 0, bytes: 0 };
1596
+ const found = [];
1597
+ const scan = prLinks ? lineScanner((text) => found.push(...prLinks(text))) : null;
1278
1598
  for (const src of sources) {
1279
1599
  const dest = path4.join(dir, path4.basename(src.file));
1280
1600
  const packed = await packedState(dest, src.mtimeMs);
@@ -1297,13 +1617,87 @@ async function syncConversation(s, root = conversationRoot(), sources = agentOf(
1297
1617
  await fs5.promises.copyFile(src.file, dest);
1298
1618
  out.bytes += src.size;
1299
1619
  } else {
1300
- out.bytes += await appendRange(src.file, dest, have, src.size);
1620
+ const feed = scan?.file();
1621
+ out.bytes += await appendRange(src.file, dest, have, src.size, feed);
1622
+ feed?.end();
1301
1623
  }
1302
1624
  await fs5.promises.utimes(dest, /* @__PURE__ */ new Date(), new Date(src.mtimeMs)).catch(() => void 0);
1303
1625
  out.files++;
1304
1626
  }
1627
+ if (prLinks) {
1628
+ const prs = await notePrLinks(s, id, dir, found, prLinks);
1629
+ if (prs) out.prs = prs;
1630
+ }
1305
1631
  return out;
1306
1632
  }
1633
+ function lineScanner(onLines) {
1634
+ return {
1635
+ file() {
1636
+ let carry = "";
1637
+ return {
1638
+ push(buf) {
1639
+ const text = carry + buf.toString("utf8");
1640
+ const nl = text.lastIndexOf("\n");
1641
+ if (nl < 0) {
1642
+ carry = text.length > 1e6 ? "" : text;
1643
+ return;
1644
+ }
1645
+ onLines(text.slice(0, nl));
1646
+ carry = text.slice(nl + 1);
1647
+ },
1648
+ end() {
1649
+ if (carry) onLines(carry);
1650
+ carry = "";
1651
+ }
1652
+ };
1653
+ }
1654
+ };
1655
+ }
1656
+ async function notePrLinks(s, id, dir, found, prLinks) {
1657
+ if (s.archivedAt) return 0;
1658
+ const whole = rescanPrLinks.has(id) || !readSessionPrs(id)?.scanned;
1659
+ const links = [...found];
1660
+ let readAll = true;
1661
+ if (whole) {
1662
+ const names = await fs5.promises.readdir(dir).catch((err) => {
1663
+ if (err.code !== "ENOENT") readAll = false;
1664
+ return [];
1665
+ });
1666
+ for (const n of names.filter((x) => x.endsWith(".jsonl") || x.endsWith(".jsonl.gz"))) {
1667
+ try {
1668
+ const buf = await fs5.promises.readFile(path4.join(dir, n));
1669
+ links.push(...prLinks((n.endsWith(".gz") ? await gunzip(buf) : buf).toString("utf8")));
1670
+ } catch (err) {
1671
+ if (err.code !== "ENOENT") readAll = false;
1672
+ }
1673
+ }
1674
+ }
1675
+ if (!links.length && !whole) return 0;
1676
+ try {
1677
+ notedPrLinks(id, links, whole && readAll);
1678
+ } catch (err) {
1679
+ rescanPrLinks.add(id);
1680
+ report("warn", `couldn't keep the PRs named in ${id}'s conversation (${err.message}); read again at the next sync`);
1681
+ return 0;
1682
+ }
1683
+ if (whole && readAll) rescanPrLinks.delete(id);
1684
+ return new Set(links.map((l) => l.url)).size;
1685
+ }
1686
+ var rescanPrLinks = /* @__PURE__ */ new Set();
1687
+ function notedPrLinks(id, links, scanned) {
1688
+ noteSessionPrs(
1689
+ id,
1690
+ links.map((l) => ({
1691
+ url: l.url,
1692
+ number: l.number,
1693
+ ...l.repo ? { repoId: l.repo.toLowerCase() } : {},
1694
+ source: "agent",
1695
+ ...l.at ? { at: l.at } : {}
1696
+ })),
1697
+ /* @__PURE__ */ new Date(),
1698
+ scanned ? { scanned: true } : {}
1699
+ );
1700
+ }
1307
1701
  async function packedState(dest, srcMtimeMs) {
1308
1702
  try {
1309
1703
  const st = await fs5.promises.stat(`${dest}.gz`);
@@ -1355,7 +1749,7 @@ async function compressQuietCopies(root = conversationRoot(), now = Date.now(),
1355
1749
  }
1356
1750
  return out;
1357
1751
  }
1358
- async function appendRange(src, dest, from, to) {
1752
+ async function appendRange(src, dest, from, to, feed) {
1359
1753
  await (await fs5.promises.open(dest, "a")).close();
1360
1754
  const [inp, out] = [await fs5.promises.open(src, "r"), await fs5.promises.open(dest, "r+")];
1361
1755
  try {
@@ -1366,6 +1760,7 @@ async function appendRange(src, dest, from, to) {
1366
1760
  const { bytesRead } = await inp.read(buf, 0, buf.length, pos);
1367
1761
  if (bytesRead === 0) break;
1368
1762
  await out.write(buf, 0, bytesRead, pos);
1763
+ feed?.push(buf.subarray(0, bytesRead));
1369
1764
  done += bytesRead;
1370
1765
  }
1371
1766
  return done;
@@ -1590,7 +1985,8 @@ function startDev(id, session, config) {
1590
1985
  detached: process.platform !== "win32",
1591
1986
  windowsHide: true,
1592
1987
  stdio: ["ignore", log, log],
1593
- env: { ...process.env, PORT: String(session.port) }
1988
+ // Windows: a bare name in the command is PATH's, never the worktree's (a branch's script runs by its path: shell-env.ts).
1989
+ env: shellEnv({ ...process.env, PORT: String(session.port) })
1594
1990
  });
1595
1991
  child.on("error", () => {
1596
1992
  });
@@ -1648,22 +2044,103 @@ function devLogTail(id, maxBytes = 64 * 1024) {
1648
2044
  }
1649
2045
 
1650
2046
  // src/core/diff/checkpoint.ts
1651
- import fs7 from "fs";
2047
+ import fs8 from "fs";
1652
2048
  import os2 from "os";
2049
+ import path8 from "path";
2050
+
2051
+ // src/core/git/git-head.ts
2052
+ import fs7 from "fs";
1653
2053
  import path7 from "path";
2054
+ function checkedOutBranch(checkout) {
2055
+ try {
2056
+ const dirs = gitDirs(checkout);
2057
+ return dirs ? branchFromHead(fs7.readFileSync(path7.join(dirs.gitDir, "HEAD"), "utf8")) : null;
2058
+ } catch {
2059
+ return null;
2060
+ }
2061
+ }
2062
+ function workingBranch(checkout) {
2063
+ const name = checkedOutBranch(checkout);
2064
+ if (name) return name;
2065
+ const dirs = gitDirs(checkout);
2066
+ if (!dirs) return null;
2067
+ for (const folder of ["rebase-merge", "rebase-apply"]) {
2068
+ try {
2069
+ const b = branchFromHead(`ref: ${fs7.readFileSync(path7.join(dirs.gitDir, folder, "head-name"), "utf8").trim()}`);
2070
+ if (b) return b;
2071
+ } catch {
2072
+ }
2073
+ }
2074
+ return null;
2075
+ }
2076
+ function gitDirs(checkout) {
2077
+ try {
2078
+ const dotGit = path7.join(checkout, ".git");
2079
+ if (!fs7.statSync(dotGit).isFile()) return { gitDir: dotGit, commonDir: dotGit };
2080
+ const m = /^gitdir:\s*(.+?)\s*$/m.exec(fs7.readFileSync(dotGit, "utf8"));
2081
+ if (!m) return null;
2082
+ const gitDir = path7.resolve(checkout, m[1]);
2083
+ let commonDir = gitDir;
2084
+ try {
2085
+ commonDir = path7.resolve(gitDir, fs7.readFileSync(path7.join(gitDir, "commondir"), "utf8").trim());
2086
+ } catch {
2087
+ }
2088
+ return { gitDir, commonDir };
2089
+ } catch {
2090
+ return null;
2091
+ }
2092
+ }
2093
+ function refShaFromFiles(checkout, ref) {
2094
+ const dirs = gitDirs(checkout);
2095
+ if (!dirs) return null;
2096
+ const sha = (s) => /^[0-9a-f]{40,64}$/.test(s) ? s : null;
2097
+ let name = ref;
2098
+ if (ref === "HEAD") {
2099
+ let head;
2100
+ try {
2101
+ head = fs7.readFileSync(path7.join(dirs.gitDir, "HEAD"), "utf8").trim();
2102
+ } catch {
2103
+ return null;
2104
+ }
2105
+ const m = /^ref:\s*(refs\/heads\/.+)$/.exec(head);
2106
+ if (!m) return sha(head);
2107
+ name = m[1];
2108
+ }
2109
+ try {
2110
+ return sha(fs7.readFileSync(path7.join(dirs.commonDir, ...name.split("/")), "utf8").trim());
2111
+ } catch {
2112
+ }
2113
+ try {
2114
+ for (const line of fs7.readFileSync(path7.join(dirs.commonDir, "packed-refs"), "utf8").split(/\r?\n/)) {
2115
+ const [s, r] = line.split(" ");
2116
+ if (r === name) return sha(s);
2117
+ }
2118
+ } catch {
2119
+ }
2120
+ return null;
2121
+ }
2122
+ function branchFromHead(head) {
2123
+ const m = /^ref:\s*refs\/heads\/(.+?)\s*$/m.exec(head);
2124
+ return m ? m[1] : null;
2125
+ }
2126
+
2127
+ // src/core/diff/checkpoint.ts
2128
+ function branchesOf(repos) {
2129
+ return Object.fromEntries(repos.map((r) => [r.name, workingBranch(r.root)]));
2130
+ }
1654
2131
  function manifestPath(scopeHash) {
1655
- const dir = path7.join(os2.homedir(), ".work", "diffs");
1656
- fs7.mkdirSync(dir, { recursive: true });
1657
- return path7.join(dir, `${scopeHash}.checkpoints.json`);
2132
+ const dir = path8.join(os2.homedir(), ".work", "diffs");
2133
+ fs8.mkdirSync(dir, { recursive: true });
2134
+ return path8.join(dir, `${scopeHash}.checkpoints.json`);
1658
2135
  }
1659
2136
  function emptyManifest(scopeHash) {
1660
2137
  return { version: 1, scopeHash, entries: [] };
1661
2138
  }
1662
2139
  function loadManifest(scopeHash) {
1663
2140
  const file = manifestPath(scopeHash);
1664
- if (!fs7.existsSync(file)) return emptyManifest(scopeHash);
2141
+ if (!fs8.existsSync(file)) return emptyManifest(scopeHash);
1665
2142
  try {
1666
- const raw = fs7.readFileSync(file, "utf-8");
2143
+ const raw = fs8.readFileSync(file, "utf-8");
1667
2144
  const parsed = JSON.parse(raw);
1668
2145
  if (parsed.version !== 1 || !Array.isArray(parsed.entries)) {
1669
2146
  return emptyManifest(scopeHash);
@@ -1746,7 +2223,8 @@ async function takeCheckpoint(scopeHash, repos, opts = {}) {
1746
2223
  const entry = {
1747
2224
  id: nextId,
1748
2225
  ts: (/* @__PURE__ */ new Date()).toISOString(),
1749
- repos: captured
2226
+ repos: captured,
2227
+ branches: branchesOf(repos)
1750
2228
  };
1751
2229
  const label = opts.label ?? (isFirst ? "Initial" : void 0);
1752
2230
  if (label) entry.label = label;
@@ -1800,6 +2278,7 @@ async function updateCheckpoint(scopeHash, repos, id) {
1800
2278
  return { status: "unchanged" };
1801
2279
  }
1802
2280
  entry.repos = captured;
2281
+ entry.branches = branchesOf(repos);
1803
2282
  entry.ts = (/* @__PURE__ */ new Date()).toISOString();
1804
2283
  delete entry.label;
1805
2284
  atomicWriteFile(file, JSON.stringify(manifest, null, 2));
@@ -1829,7 +2308,8 @@ async function resetBaseline(scopeHash, repos) {
1829
2308
  id: 0,
1830
2309
  ts: (/* @__PURE__ */ new Date()).toISOString(),
1831
2310
  label: "Initial",
1832
- repos: captured
2311
+ repos: captured,
2312
+ branches: branchesOf(repos)
1833
2313
  };
1834
2314
  const manifest = {
1835
2315
  version: 1,
@@ -1866,6 +2346,12 @@ async function headAdvancedSinceInitial(scopeHash, repos) {
1866
2346
  }
1867
2347
  return false;
1868
2348
  }
2349
+ function switchedBranch(turn, repo) {
2350
+ if (!turn.branches || !(repo.name in turn.branches)) return false;
2351
+ const was = turn.branches[repo.name];
2352
+ const now = workingBranch(repo.root);
2353
+ return !!was && !!now && was !== now;
2354
+ }
1869
2355
  async function headBroughtInOtherWork(scopeHash, repos) {
1870
2356
  const entries = loadManifest(scopeHash).entries;
1871
2357
  if (entries.length === 0) return false;
@@ -1881,6 +2367,7 @@ async function headBroughtInOtherWork(scopeHash, repos) {
1881
2367
  const broughtIn = async (repo) => {
1882
2368
  const snap = newest.repos[repo.name];
1883
2369
  if (!snap) return false;
2370
+ if (switchedBranch(newest, repo)) return false;
1884
2371
  const was = await run(repo.root, ["rev-parse", "--verify", "--quiet", `${snap}^`]);
1885
2372
  const now = await run(repo.root, ["rev-parse", "--verify", "--quiet", "HEAD"]);
1886
2373
  if (!was.ok || !now.ok || !was.out || was.out === now.out) return false;
@@ -1909,21 +2396,21 @@ function clearCheckpoints(scopeHash, repoRoots) {
1909
2396
  }
1910
2397
  }
1911
2398
  const file = manifestPath(scopeHash);
1912
- if (fs7.existsSync(file)) {
2399
+ if (fs8.existsSync(file)) {
1913
2400
  try {
1914
- fs7.unlinkSync(file);
2401
+ fs8.unlinkSync(file);
1915
2402
  } catch {
1916
2403
  }
1917
2404
  }
1918
2405
  }
1919
2406
 
1920
2407
  // src/core/diff/scope-manager.ts
1921
- import path9 from "path";
2408
+ import path10 from "path";
1922
2409
  import crypto2 from "crypto";
1923
2410
 
1924
2411
  // src/core/platform/fs-watcher.ts
1925
- import fs8 from "fs";
1926
- import path8 from "path";
2412
+ import fs9 from "fs";
2413
+ import path9 from "path";
1927
2414
  import { createRequire } from "module";
1928
2415
  var loadChokidar = () => createRequire(import.meta.url)("chokidar");
1929
2416
  var IGNORED_DIRS = /* @__PURE__ */ new Set([
@@ -1949,7 +2436,7 @@ var IGNORED_DIRS = /* @__PURE__ */ new Set([
1949
2436
  ]);
1950
2437
  function isIgnoredWatchPath(roots, filePath) {
1951
2438
  for (const root of roots) {
1952
- const rel = path8.relative(root, filePath).replace(/\\/g, "/");
2439
+ const rel = path9.relative(root, filePath).replace(/\\/g, "/");
1953
2440
  if (rel === "" || rel.startsWith("../")) continue;
1954
2441
  if (rel.split("/").some((seg) => IGNORED_DIRS.has(seg))) return true;
1955
2442
  }
@@ -1971,8 +2458,8 @@ function createFsWatcher(opts) {
1971
2458
  };
1972
2459
  if (SUPPORTS_RECURSIVE_WATCH) {
1973
2460
  const watchers = opts.roots.map((root) => {
1974
- const w = fs8.watch(root, { recursive: true }, (_event, filename) => {
1975
- if (filename && isIgnoredWatchPath([root], path8.join(root, filename.toString()))) {
2461
+ const w = fs9.watch(root, { recursive: true }, (_event, filename) => {
2462
+ if (filename && isIgnoredWatchPath([root], path9.join(root, filename.toString()))) {
1976
2463
  return;
1977
2464
  }
1978
2465
  fire();
@@ -2023,7 +2510,7 @@ var ScopePathRejectedError = class extends Error {
2023
2510
  }
2024
2511
  };
2025
2512
  function normaliseForCompare(p) {
2026
- return path9.resolve(p).replace(/\\/g, "/").toLowerCase();
2513
+ return path10.resolve(p).replace(/\\/g, "/").toLowerCase();
2027
2514
  }
2028
2515
  function rejectedPaths(normalised) {
2029
2516
  const config = loadConfig();
@@ -2038,7 +2525,7 @@ function rejectedPaths(normalised) {
2038
2525
  });
2039
2526
  }
2040
2527
  function registerScope(paths, label) {
2041
- const normalised = paths.map((p) => path9.resolve(p));
2528
+ const normalised = paths.map((p) => path10.resolve(p));
2042
2529
  const rejected = rejectedPaths(normalised);
2043
2530
  if (rejected.length > 0) throw new ScopePathRejectedError(rejected);
2044
2531
  const hash = hashFor(normalised);
@@ -2052,7 +2539,7 @@ function registerScope(paths, label) {
2052
2539
  const scope = {
2053
2540
  hash,
2054
2541
  paths: normalised,
2055
- label: label ?? path9.basename(normalised[0]),
2542
+ label: label ?? path10.basename(normalised[0]),
2056
2543
  createdAt: (/* @__PURE__ */ new Date()).toISOString(),
2057
2544
  ended: false
2058
2545
  };
@@ -2078,17 +2565,17 @@ function reviveScope(hash) {
2078
2565
  return true;
2079
2566
  }
2080
2567
  function scopesToSweep(scopes2, sessionPaths) {
2081
- const owned = new Set(sessionPaths.map((paths) => hashFor(paths.map((p) => path9.resolve(p)))));
2568
+ const owned = new Set(sessionPaths.map((paths) => hashFor(paths.map((p) => path10.resolve(p)))));
2082
2569
  return scopes2.filter((s) => !owned.has(s.hash));
2083
2570
  }
2084
2571
  function sessionOwnsScope(hash, sessionPaths) {
2085
- return sessionPaths.some((paths) => hashFor(paths.map((p) => path9.resolve(p))) === hash);
2572
+ return sessionPaths.some((paths) => hashFor(paths.map((p) => path10.resolve(p))) === hash);
2086
2573
  }
2087
2574
  function findScope(paths) {
2088
2575
  return getScope(scopeHashForPaths(paths));
2089
2576
  }
2090
2577
  function scopeHashForPaths(paths) {
2091
- return hashFor(paths.map((p) => path9.resolve(p)));
2578
+ return hashFor(paths.map((p) => path10.resolve(p)));
2092
2579
  }
2093
2580
  function getScope(hash) {
2094
2581
  return scopes.get(hash)?.scope ?? null;
@@ -2171,7 +2658,7 @@ function clearSessionCheckpoints(s) {
2171
2658
  try {
2172
2659
  const cfg = loadConfig();
2173
2660
  const aliases = sessionAliases(s, cfg);
2174
- const roots = aliases.map((a) => cfg?.repos[a]).filter((r) => !!r && fs9.existsSync(r));
2661
+ const roots = aliases.map((a) => cfg?.repos[a]).filter((r) => !!r && fs10.existsSync(r));
2175
2662
  clearCheckpoints(scopeHashForPaths(s.paths), roots);
2176
2663
  if (s.branch !== void 0) for (const r of roots) dropSessionSaves(r, sessionIdFor({ target: s.target, branch: s.branch }));
2177
2664
  } catch (err) {
@@ -2181,7 +2668,7 @@ function clearSessionCheckpoints(s) {
2181
2668
  function removeSessionFiles(id) {
2182
2669
  for (const p of sessionStatePaths(id)) {
2183
2670
  try {
2184
- fs9.rmSync(p, { force: true, recursive: true });
2671
+ fs10.rmSync(p, { force: true, recursive: true });
2185
2672
  } catch (err) {
2186
2673
  logSwallowed(`purge ${p}`, err);
2187
2674
  }
@@ -2196,7 +2683,7 @@ var recordAgent = (account) => {
2196
2683
  return { ...agent ? { agent } : {}, ...accounts ? { account: account || accounts.defaultName() } : {} };
2197
2684
  };
2198
2685
  function getHistoryPath() {
2199
- return path10.join(getConfigDir(), "history.json");
2686
+ return path11.join(getConfigDir(), "history.json");
2200
2687
  }
2201
2688
  function valid(s) {
2202
2689
  const x = s;
@@ -2221,7 +2708,7 @@ function appendSessionRepo(id, alias, worktree, from, config, imports = false) {
2221
2708
  const s = r ? json.parse(r.data) : null;
2222
2709
  if (!valid(s)) return null;
2223
2710
  const own = sessionRepos(s, config);
2224
- const unknown = own.filter((x) => x.guessed).map((x) => path10.basename(x.path));
2711
+ const unknown = own.filter((x) => x.guessed).map((x) => path11.basename(x.path));
2225
2712
  if (unknown.length) throw new Error(`no repo of its group is in ${unknown.join(", ")}, so its repos can't be recorded`);
2226
2713
  const repos = own.map((x) => x.alias);
2227
2714
  const before = [...s.paths];
@@ -2291,6 +2778,14 @@ function touchSession(target, branch) {
2291
2778
  putRow(d, s);
2292
2779
  });
2293
2780
  }
2781
+ function clearLaunchedUnsafe(target, branch) {
2782
+ tx((d) => {
2783
+ const s = getRow(d, target, branch);
2784
+ if (!s || s.launchedUnsafe === void 0) return;
2785
+ delete s.launchedUnsafe;
2786
+ putRow(d, s);
2787
+ });
2788
+ }
2294
2789
  async function upsertSession(target, isGroup, branch, paths, jiraKey, baseBranch, port, repos, account) {
2295
2790
  tx((d) => {
2296
2791
  const existing = getRow(d, target, branch);
@@ -2363,7 +2858,7 @@ async function upsertSessionWithPort(target, isGroup, branch, paths, config, jir
2363
2858
  }
2364
2859
  const done = tx((d) => {
2365
2860
  if (port !== void 0 && getRow(d, target, branch)?.port === void 0) {
2366
- const taken = rows(d).some((s) => sessionIdFor(s) !== id && s.port === port && s.paths.some((p) => fs10.existsSync(p)));
2861
+ const taken = rows(d).some((s) => sessionIdFor(s) !== id && s.port === port && s.paths.some((p) => fs11.existsSync(p)));
2367
2862
  if (taken) return null;
2368
2863
  }
2369
2864
  return { port: write(d, port) };
@@ -2372,15 +2867,6 @@ async function upsertSessionWithPort(target, isGroup, branch, paths, config, jir
2372
2867
  }
2373
2868
  return tx((d) => ({ port: write(d, void 0) }));
2374
2869
  }
2375
- function recordLaunch(target, branch, opts) {
2376
- tx((d) => {
2377
- const s = getRow(d, target, branch);
2378
- if (!s) return;
2379
- if (opts.unsafe) s.launchedUnsafe = true;
2380
- else delete s.launchedUnsafe;
2381
- putRow(d, s);
2382
- });
2383
- }
2384
2870
  async function setSessionArchived(target, branch, archived) {
2385
2871
  return tx((d) => {
2386
2872
  const s = getRow(d, target, branch);
@@ -2449,7 +2935,7 @@ function pruneStaleEntries(sessions) {
2449
2935
  const kept = [];
2450
2936
  let pruned = 0;
2451
2937
  for (const session of sessions) {
2452
- const anyPathExists = session.paths.some((p) => fs10.existsSync(p));
2938
+ const anyPathExists = session.paths.some((p) => fs11.existsSync(p));
2453
2939
  if (anyPathExists) {
2454
2940
  kept.push(session);
2455
2941
  } else {
@@ -2507,7 +2993,7 @@ async function mergeHydratedSessions(incoming) {
2507
2993
  });
2508
2994
  }
2509
2995
  var samePath = (a, b) => {
2510
- const n = (p) => path10.resolve(p).split(path10.sep).join("/").toLowerCase();
2996
+ const n = (p) => path11.resolve(p).split(path11.sep).join("/").toLowerCase();
2511
2997
  return n(a) === n(b);
2512
2998
  };
2513
2999
  async function forgetOtherBaseCheckoutEntries(target, keepBranch, repoPath) {
@@ -2523,6 +3009,10 @@ export {
2523
3009
  readSessionActivity,
2524
3010
  activeWithin,
2525
3011
  effectiveLastAccessedAt,
3012
+ checkedOutBranch,
3013
+ workingBranch,
3014
+ gitDirs,
3015
+ refShaFromFiles,
2526
3016
  writeTempTree,
2527
3017
  runGitAsync,
2528
3018
  archiveRefFor,
@@ -2534,7 +3024,9 @@ export {
2534
3024
  bestEffortAsync,
2535
3025
  swallow,
2536
3026
  STAGE_WANTS_YOU,
3027
+ stageOfPr,
2537
3028
  prStageOf,
3029
+ stageRepos,
2538
3030
  cleanStageRef,
2539
3031
  stageWaiting,
2540
3032
  createStageTracker,
@@ -2583,6 +3075,28 @@ export {
2583
3075
  readArchive,
2584
3076
  restoreArchivedTranscripts,
2585
3077
  messageOf,
3078
+ GITHUB_THREAD_ID,
3079
+ onGithub,
3080
+ githubRepoId,
3081
+ parseGithubPrUrl,
3082
+ parseAzureOrigin,
3083
+ onAzure,
3084
+ azureRepoId,
3085
+ azureWebUrl,
3086
+ parseAzurePrUrl,
3087
+ AZURE_THREAD_ID,
3088
+ azureThreadRepoId,
3089
+ azureThreadId,
3090
+ parseAzureThreadId,
3091
+ githubCommands,
3092
+ azureCommands,
3093
+ DEFAULT_HOST,
3094
+ commandsFor,
3095
+ hostName,
3096
+ parsePrLink,
3097
+ readSessionPrs,
3098
+ noteSessionPrs,
3099
+ notePrLooks,
2586
3100
  syncConversation,
2587
3101
  compressQuietCopies,
2588
3102
  syncConversations,
@@ -2629,9 +3143,9 @@ export {
2629
3143
  findSession,
2630
3144
  setOwnRepos,
2631
3145
  touchSession,
3146
+ clearLaunchedUnsafe,
2632
3147
  upsertSession,
2633
3148
  upsertSessionWithPort,
2634
- recordLaunch,
2635
3149
  setSessionArchived,
2636
3150
  setSessionTitle,
2637
3151
  setSessionAccount,
@@ -2644,4 +3158,4 @@ export {
2644
3158
  mergeHydratedSessions,
2645
3159
  forgetOtherBaseCheckoutEntries
2646
3160
  };
2647
- //# sourceMappingURL=chunk-37XQIG7F.js.map
3161
+ //# sourceMappingURL=chunk-ZG2M4ECW.js.map