@maycombhq/atticus 2.0.0-beta.18 → 2.0.0-beta.21

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 (270) hide show
  1. package/dist/bin.js +8 -4
  2. package/dist/{chunk-MUSJJ6CQ.js → chunk-265LWMOA.js} +16 -16
  3. package/dist/chunk-26WBY34Y.js +37 -0
  4. package/dist/{chunk-6H5JG5GL.js → chunk-26Z7OGQW.js} +63 -30
  5. package/dist/{chunk-4REDBQOZ.js → chunk-2D7PWSOK.js} +20 -20
  6. package/dist/{chunk-YPH6ZJ6R.js → chunk-2HH3UCZM.js} +4 -4
  7. package/dist/{chunk-RTUUX7PX.js → chunk-2HTEMYTB.js} +12 -26
  8. package/dist/{chunk-EHQUY26D.js → chunk-2UCRFXFZ.js} +11 -11
  9. package/dist/{chunk-ILDGIXNH.js → chunk-2V2ZPQQU.js} +81 -13
  10. package/dist/{chunk-YSEZQ6D3.js → chunk-36RY7ZXM.js} +107 -64
  11. package/dist/{chunk-QXFDM2FZ.js → chunk-37WE3LS2.js} +3 -3
  12. package/dist/{chunk-BAXM3JFQ.js → chunk-3AQ2R5NL.js} +1212 -754
  13. package/dist/chunk-3G6S7LAA.js +43 -0
  14. package/dist/{chunk-7TOAS7KI.js → chunk-3J5I7ZOU.js} +4 -4
  15. package/dist/{chunk-TAKAEJRD.js → chunk-3LZ6P5EP.js} +1 -1
  16. package/dist/chunk-3SSTNB4E.js +191 -0
  17. package/dist/chunk-3TD6S4TC.js +49 -0
  18. package/dist/{chunk-UUL6ZGMU.js → chunk-3UTYPHN3.js} +1 -1
  19. package/dist/{chunk-6AP2ZUUM.js → chunk-3WON4G3M.js} +2 -2
  20. package/dist/{chunk-AXY6LBW4.js → chunk-42EPP7OB.js} +12 -12
  21. package/dist/{chunk-QKMDT7VU.js → chunk-455SYIIE.js} +2 -2
  22. package/dist/{chunk-MFUFB3LN.js → chunk-4B6BT75O.js} +110 -20
  23. package/dist/{chunk-75MYLZSB.js → chunk-4CLK2RJO.js} +7 -7
  24. package/dist/chunk-4CYTJ5TZ.js +38 -0
  25. package/dist/{chunk-IH7RANGB.js → chunk-4D62IZII.js} +5 -5
  26. package/dist/{chunk-2QMZOCWN.js → chunk-4FOAYLI4.js} +14 -7
  27. package/dist/{chunk-V3UEPUHT.js → chunk-4KNOJC6J.js} +294 -215
  28. package/dist/{chunk-O6ILVBYB.js → chunk-4PYC2UGC.js} +1 -1
  29. package/dist/{chunk-EZBAS5BL.js → chunk-4SLBCEPD.js} +82 -50
  30. package/dist/{chunk-VIRTPODJ.js → chunk-4TKVU2I2.js} +6 -14
  31. package/dist/{chunk-IVCDU443.js → chunk-4WXRPQDE.js} +281 -51
  32. package/dist/{chunk-RMEEHH24.js → chunk-5CMPVC3N.js} +24 -24
  33. package/dist/chunk-5G7ILBUG.js +66 -0
  34. package/dist/{chunk-Z75XDWQR.js → chunk-5PV7S2ZP.js} +3 -3
  35. package/dist/{chunk-WWPC2AZ2.js → chunk-5QUOPNLN.js} +4 -4
  36. package/dist/{chunk-7OVH2L7L.js → chunk-5TDRBOAV.js} +5 -5
  37. package/dist/{chunk-YXUIUOQZ.js → chunk-5WERBKLE.js} +199 -63
  38. package/dist/{chunk-6WNNXEG6.js → chunk-62DLJSLV.js} +8 -8
  39. package/dist/{chunk-KCQS52TH.js → chunk-64AADMTW.js} +99 -25
  40. package/dist/{chunk-KLRUXRPN.js → chunk-67BP7HXL.js} +17 -17
  41. package/dist/chunk-6DQYZU2W.js +379 -0
  42. package/dist/{chunk-RONDYDMQ.js → chunk-6EXDI5GI.js} +51 -34
  43. package/dist/chunk-6FNAKCET.js +38 -0
  44. package/dist/{chunk-6SNEA73E.js → chunk-75ASLHBT.js} +21 -15
  45. package/dist/{chunk-EFT4KM6K.js → chunk-75ZOZFGH.js} +18 -18
  46. package/dist/{chunk-B3KW7EQW.js → chunk-77O633L5.js} +12 -12
  47. package/dist/{chunk-TLDL2ZZI.js → chunk-7AB6OWTV.js} +3 -3
  48. package/dist/{chunk-R5YXY6NT.js → chunk-7CZHUZBL.js} +25 -25
  49. package/dist/{chunk-F4D4G2A6.js → chunk-7FHNFCHK.js} +306 -125
  50. package/dist/{chunk-CC5RNYZF.js → chunk-7FUIVIBG.js} +19 -9
  51. package/dist/{chunk-UBTOSSNK.js → chunk-7QPCGTPS.js} +21 -21
  52. package/dist/{chunk-CDLTRJ4N.js → chunk-A2G72UI4.js} +7 -7
  53. package/dist/{chunk-YGSOQ5LX.js → chunk-AE4P57KK.js} +23 -17
  54. package/dist/{chunk-PGQL5YGH.js → chunk-AHW3RY3X.js} +7 -7
  55. package/dist/chunk-AM6FP6JW.js +43 -0
  56. package/dist/{chunk-DYNC6BAQ.js → chunk-AOCWFA7T.js} +93 -10
  57. package/dist/{chunk-CYX36GKZ.js → chunk-API5TOUB.js} +1 -1
  58. package/dist/{chunk-BJ5T3KDF.js → chunk-AZDITBCT.js} +3 -3
  59. package/dist/{chunk-U6GZSUMC.js → chunk-BA2HUMDN.js} +25 -3
  60. package/dist/chunk-BA3U7ALS.js +99 -0
  61. package/dist/{chunk-63565QTF.js → chunk-BC6KKZ67.js} +5 -5
  62. package/dist/{chunk-XO5RQKNM.js → chunk-BEPCKDCP.js} +1843 -577
  63. package/dist/{chunk-KUH62AQ3.js → chunk-BPPU3PW7.js} +4 -4
  64. package/dist/{chunk-52ULYRV4.js → chunk-BVWWPBKD.js} +18 -18
  65. package/dist/{chunk-R2FGEBIU.js → chunk-BXZ4PKIT.js} +13 -11
  66. package/dist/{chunk-4BU26GFB.js → chunk-C7CEK3KW.js} +4 -4
  67. package/dist/chunk-CFH3QH26.js +29 -0
  68. package/dist/chunk-CG6CULP6.js +170 -0
  69. package/dist/chunk-CLD4RVTA.js +45 -0
  70. package/dist/{chunk-BU543ZEC.js → chunk-CNPY4NTZ.js} +13 -13
  71. package/dist/{chunk-PLBIWEPV.js → chunk-CNU5Q2D5.js} +32 -31
  72. package/dist/{chunk-JTYYEYRR.js → chunk-COYN3UAN.js} +124 -21
  73. package/dist/{chunk-TNCROWPQ.js → chunk-CPK7QSBG.js} +10 -10
  74. package/dist/{chunk-43E6XX67.js → chunk-D2WSW4GU.js} +1 -1
  75. package/dist/{chunk-SHEUEHKC.js → chunk-D57MFJPP.js} +3 -3
  76. package/dist/chunk-D5KV5PSK.js +45 -0
  77. package/dist/chunk-D5MASS4I.js +48 -0
  78. package/dist/{chunk-TQYBXDVH.js → chunk-DCWN3HFV.js} +1 -1
  79. package/dist/{chunk-FF4IGX4Z.js → chunk-DDJPM5YX.js} +2 -2
  80. package/dist/chunk-DN4A2Q2O.js +57 -0
  81. package/dist/{chunk-4ZCFCIEL.js → chunk-DUPZPDCJ.js} +52 -16
  82. package/dist/{chunk-CUJ5TIEB.js → chunk-E2VXBSIR.js} +4 -4
  83. package/dist/{chunk-BX47X5DJ.js → chunk-E57AOFYN.js} +13 -13
  84. package/dist/{chunk-SSTI7GAV.js → chunk-ECLXZWAG.js} +12 -12
  85. package/dist/{chunk-KYK3TA4Q.js → chunk-EDZ45WIR.js} +14 -14
  86. package/dist/chunk-EFCQSMXB.js +37 -0
  87. package/dist/{chunk-YC2K3FJG.js → chunk-EZIN5E5B.js} +8 -8
  88. package/dist/{chunk-MIZNACDI.js → chunk-F6H2RJ3N.js} +1 -1
  89. package/dist/{chunk-EMZVHDJP.js → chunk-FAJDKNSD.js} +7 -3
  90. package/dist/chunk-FGAGWYZB.js +47 -0
  91. package/dist/{chunk-KBGQ3IAM.js → chunk-FLVZFTLQ.js} +18 -18
  92. package/dist/{chunk-2NNXLH53.js → chunk-FQ6WH6PB.js} +22 -7
  93. package/dist/{chunk-QWSLMVHI.js → chunk-FRHD22WM.js} +61 -23
  94. package/dist/{chunk-5MEN4SM5.js → chunk-FVMPFCDS.js} +4 -4
  95. package/dist/{chunk-KLRZKW7Y.js → chunk-FY3QIRTL.js} +3 -3
  96. package/dist/{chunk-B3SWPNJF.js → chunk-FYBF5MB2.js} +13 -11
  97. package/dist/{chunk-CVZCW3NI.js → chunk-G5YJBNDZ.js} +14 -5
  98. package/dist/{chunk-U6EPS5PF.js → chunk-G6IQYM25.js} +5 -5
  99. package/dist/chunk-G6X4YL4D.js +161 -0
  100. package/dist/{chunk-DOSX3MRW.js → chunk-GC2VK3JT.js} +25 -25
  101. package/dist/{chunk-EEWBTFRP.js → chunk-GCS3FZOB.js} +27 -3
  102. package/dist/{chunk-6H6OPNEP.js → chunk-GDZB57IU.js} +5 -5
  103. package/dist/chunk-GIFMBCTW.js +221 -0
  104. package/dist/{chunk-X5WYPIH3.js → chunk-GK4PYVEC.js} +18 -8
  105. package/dist/{chunk-VBSJ5NRB.js → chunk-GNWAOVFQ.js} +5 -5
  106. package/dist/{chunk-TXFDQRBL.js → chunk-GS76RXQE.js} +11 -11
  107. package/dist/{chunk-U3YC4RGC.js → chunk-GSGIZ2OO.js} +23 -23
  108. package/dist/chunk-GUYL7RMK.js +60 -0
  109. package/dist/{chunk-AZYBHPV4.js → chunk-GX74YWR7.js} +14 -13
  110. package/dist/{chunk-YY7VP7KW.js → chunk-HE3HRDNZ.js} +2 -2
  111. package/dist/{chunk-Z7HYYDZM.js → chunk-HGHRSF3E.js} +14 -13
  112. package/dist/{chunk-Q2X4IREC.js → chunk-HK3VOHIE.js} +106 -36
  113. package/dist/{chunk-P5JYMO7Y.js → chunk-HS4BGB4G.js} +22 -22
  114. package/dist/{chunk-IOW6BF3U.js → chunk-HSZMPH5T.js} +798 -141
  115. package/dist/{chunk-L3T33FA7.js → chunk-HWD4JPU7.js} +4 -2
  116. package/dist/{chunk-7NYCH5HY.js → chunk-HXXP2NTE.js} +6 -6
  117. package/dist/{chunk-7S7OFVIU.js → chunk-I2A3Z5AK.js} +4 -4
  118. package/dist/{chunk-WQSDKX7M.js → chunk-ICHDSWEY.js} +7 -7
  119. package/dist/chunk-IFFRGC3N.js +31 -0
  120. package/dist/{chunk-HMZQAIR5.js → chunk-IFHDV6KQ.js} +24 -17
  121. package/dist/chunk-J2O4LFVI.js +80 -0
  122. package/dist/chunk-J5AAZ6OJ.js +161 -0
  123. package/dist/{chunk-CVRWAG76.js → chunk-JAABT3DA.js} +3 -3
  124. package/dist/chunk-JITJP64K.js +34 -0
  125. package/dist/chunk-JKIGL3XQ.js +162 -0
  126. package/dist/chunk-JRVNXLZP.js +615 -0
  127. package/dist/chunk-JRXHON4E.js +41 -0
  128. package/dist/{chunk-XFCK5B27.js → chunk-JS6WMC3J.js} +8 -8
  129. package/dist/chunk-JU4QNJSR.js +62 -0
  130. package/dist/{chunk-IPSFMTK2.js → chunk-JYMIB5XY.js} +152 -42
  131. package/dist/{chunk-L336AJCZ.js → chunk-JYTIHTIK.js} +8 -6
  132. package/dist/{chunk-VEJYZEPC.js → chunk-K332XW7K.js} +135 -16
  133. package/dist/{chunk-KCF7TFOE.js → chunk-K6JB6XTX.js} +11 -11
  134. package/dist/{chunk-LFIIX4OV.js → chunk-KDAHXQIE.js} +46 -34
  135. package/dist/chunk-KYZMRSPS.js +93 -0
  136. package/dist/chunk-L4CESDPB.js +22 -0
  137. package/dist/{chunk-3LR4522O.js → chunk-LEBR5NHW.js} +14 -14
  138. package/dist/{chunk-US3QZU23.js → chunk-LIJJCBQI.js} +67 -7
  139. package/dist/{chunk-XLHL6WTI.js → chunk-LIRVU3HW.js} +16 -16
  140. package/dist/{chunk-BAT4CBB7.js → chunk-LN77DXBM.js} +19 -10
  141. package/dist/{chunk-E5FM44EJ.js → chunk-LNWEWYCM.js} +2474 -315
  142. package/dist/{chunk-TX4OGZKU.js → chunk-LO3BLMVG.js} +3 -3
  143. package/dist/{chunk-RUOGHYSK.js → chunk-LPV6T362.js} +5 -5
  144. package/dist/{chunk-2T5CQH4R.js → chunk-LQH4P45K.js} +1 -1
  145. package/dist/chunk-LU4MQVAL.js +41 -0
  146. package/dist/{chunk-HW4RRIJA.js → chunk-LWDNKE4X.js} +12 -10
  147. package/dist/chunk-M4H2UG4R.js +218 -0
  148. package/dist/{chunk-CANMOOE6.js → chunk-M6D2U3YM.js} +3 -3
  149. package/dist/{chunk-AB5E5HCN.js → chunk-MD7KUEJ3.js} +14 -272
  150. package/dist/{chunk-ENTAAEDK.js → chunk-MMZUN7ZO.js} +20 -20
  151. package/dist/{chunk-L4MHJG3I.js → chunk-MZGRDONP.js} +46 -36
  152. package/dist/{chunk-IYI2S6BB.js → chunk-N3RUGTGV.js} +18 -18
  153. package/dist/{chunk-WZRCGGXG.js → chunk-NCB6656Z.js} +7 -7
  154. package/dist/{chunk-SBE773JU.js → chunk-NRQ65LTQ.js} +5 -5
  155. package/dist/{chunk-NRPMPZWJ.js → chunk-NTAVOWYD.js} +117 -18
  156. package/dist/{chunk-UJBZS5I7.js → chunk-NYOABJNK.js} +36 -27
  157. package/dist/{chunk-LXAPJ3BL.js → chunk-O4IKAIZ2.js} +24 -20
  158. package/dist/{chunk-MMB2OHUY.js → chunk-ODMBPDDV.js} +48 -13
  159. package/dist/chunk-OKUB6RJA.js +533 -0
  160. package/dist/{chunk-MKFYQQ5Q.js → chunk-OMPENNWY.js} +4 -1
  161. package/dist/chunk-OPQZISG3.js +25 -0
  162. package/dist/{chunk-ROJMXG4E.js → chunk-OV57AHCG.js} +24 -24
  163. package/dist/{chunk-7KGXDIWV.js → chunk-OZJ3JLYI.js} +9 -8
  164. package/dist/{chunk-G5BYKJIM.js → chunk-P2VBXX7N.js} +11 -10
  165. package/dist/{chunk-YK6CSODO.js → chunk-PAINMSID.js} +4353 -1106
  166. package/dist/chunk-PKJAV25S.js +43 -0
  167. package/dist/{chunk-R5MNPIMD.js → chunk-PNQLCRSS.js} +4 -4
  168. package/dist/{chunk-3SMMFQED.js → chunk-PQH56YF6.js} +37 -5
  169. package/dist/chunk-PRTBPXYA.js +50 -0
  170. package/dist/{chunk-FF4ZMLSL.js → chunk-PRW3HXM3.js} +2 -2
  171. package/dist/chunk-PRZ7KMWL.js +42 -0
  172. package/dist/{chunk-IFV6MKYV.js → chunk-PTQ3ZALZ.js} +42 -4
  173. package/dist/{chunk-ELQSLAP6.js → chunk-PUEWDYGP.js} +2 -2
  174. package/dist/{chunk-F2ZCZYIK.js → chunk-Q26LDIUV.js} +12 -11
  175. package/dist/chunk-Q46QDDMF.js +277 -0
  176. package/dist/chunk-QBNWF5ZU.js +19 -0
  177. package/dist/{chunk-ANETFNTV.js → chunk-QE527XRY.js} +24 -21
  178. package/dist/{chunk-QNMLLYTN.js → chunk-QHJJMZLX.js} +397 -32
  179. package/dist/chunk-QJCJOMW3.js +425 -0
  180. package/dist/{chunk-3HOONZUE.js → chunk-QKMRFNMA.js} +15 -15
  181. package/dist/{chunk-7S6VJ643.js → chunk-QOOEYDNJ.js} +101 -13
  182. package/dist/{chunk-4YNKN4DF.js → chunk-QSIDVFB7.js} +20 -18
  183. package/dist/{chunk-2IT7SIJY.js → chunk-RA33EYS4.js} +19 -18
  184. package/dist/{chunk-P7NV3FEJ.js → chunk-RALY3E5U.js} +4 -4
  185. package/dist/{chunk-6NESNLVU.js → chunk-S2RY3BOD.js} +35 -21
  186. package/dist/chunk-SB5GRUFM.js +54 -0
  187. package/dist/{chunk-EUQHM2CH.js → chunk-SH27FYPF.js} +18 -18
  188. package/dist/chunk-T74WQQGS.js +40 -0
  189. package/dist/{chunk-LGDW4G73.js → chunk-TGVVUKTG.js} +2 -2
  190. package/dist/chunk-THN26IEF.js +48 -0
  191. package/dist/{chunk-ZV2VCBMQ.js → chunk-TJH2EUAZ.js} +18 -12
  192. package/dist/{chunk-NGT5LLSE.js → chunk-TQ4TG57V.js} +6 -6
  193. package/dist/{chunk-WEDXFJPG.js → chunk-TQTRWENN.js} +12 -12
  194. package/dist/{chunk-ZRWS54RI.js → chunk-TSM6T6GQ.js} +23 -23
  195. package/dist/{chunk-KET7KOVE.js → chunk-TW3KOSQK.js} +15 -7
  196. package/dist/{chunk-RBXDHCN7.js → chunk-TWQRPM76.js} +2 -2
  197. package/dist/{chunk-IO6DQCZX.js → chunk-TYD6I4CZ.js} +4 -4
  198. package/dist/{chunk-5NLJH6R4.js → chunk-U3NBK4EU.js} +56 -17
  199. package/dist/{chunk-U542BJME.js → chunk-UDXWIPCB.js} +7 -7
  200. package/dist/{chunk-OSB6AKF2.js → chunk-UEVZZZU2.js} +4 -4
  201. package/dist/{chunk-5ZV7BK22.js → chunk-UF4UHCIG.js} +2 -2
  202. package/dist/{chunk-PHJOOL6U.js → chunk-UFE36WJH.js} +4 -4
  203. package/dist/{chunk-IHRP4OYV.js → chunk-URIKUID7.js} +12 -12
  204. package/dist/chunk-UYLBRRFK.js +1106 -0
  205. package/dist/chunk-UZACEG2C.js +515 -0
  206. package/dist/{chunk-LR4XBH4L.js → chunk-VAMHOHUU.js} +12 -12
  207. package/dist/{chunk-S5PSGAQ2.js → chunk-VUVGX5L2.js} +1 -1
  208. package/dist/{chunk-2TG2QGKW.js → chunk-VYOCPTUB.js} +18 -16
  209. package/dist/{chunk-VTEDQ6GY.js → chunk-WAZEXEJH.js} +175 -3
  210. package/dist/{chunk-UTSFKZ72.js → chunk-WCEF7H6L.js} +3 -3
  211. package/dist/{chunk-DXPUYG5L.js → chunk-WEOMJHPV.js} +12 -12
  212. package/dist/{chunk-NFKBU2UH.js → chunk-WFU77T3A.js} +5 -5
  213. package/dist/chunk-WIWTJMMR.js +292 -0
  214. package/dist/{chunk-MRFSUAJH.js → chunk-WNTIOBOG.js} +18 -18
  215. package/dist/{chunk-UROTYIGJ.js → chunk-X2CUXTWU.js} +6 -6
  216. package/dist/chunk-X7EMBM5X.js +34 -0
  217. package/dist/{chunk-OO5TKEAG.js → chunk-XEQCQO66.js} +8 -8
  218. package/dist/{chunk-NBQO75XT.js → chunk-XG4WJHLQ.js} +17 -1
  219. package/dist/{chunk-ZQC7MNQB.js → chunk-XOL3GFW2.js} +101 -30
  220. package/dist/{chunk-GXDATVSY.js → chunk-XQ3YZ4QW.js} +22 -22
  221. package/dist/{chunk-GTW54D3D.js → chunk-Y6K3CJBU.js} +726 -88
  222. package/dist/{chunk-CQCAJI6G.js → chunk-YAH5IQAL.js} +5 -5
  223. package/dist/{chunk-U6TD7UOH.js → chunk-YBOVNMHC.js} +51 -14
  224. package/dist/{chunk-OJICVOZH.js → chunk-YF5DZCPN.js} +79 -39
  225. package/dist/chunk-YIGBJNH4.js +37 -0
  226. package/dist/{chunk-7C7OZARH.js → chunk-YJ3TBOTK.js} +25 -25
  227. package/dist/{chunk-HXFSM4LG.js → chunk-YKTE2RU3.js} +2 -2
  228. package/dist/{chunk-7IM4BVVH.js → chunk-YO2PKTXT.js} +268 -36
  229. package/dist/{chunk-Z3UU7XV6.js → chunk-YTTNTQOX.js} +15 -15
  230. package/dist/{chunk-2ZICHO3V.js → chunk-YWAKDNMH.js} +183 -33
  231. package/dist/{chunk-OXOSJXOI.js → chunk-YZDZOEV4.js} +4 -4
  232. package/dist/{chunk-MRCETHW5.js → chunk-Z3QFH7YG.js} +4 -4
  233. package/dist/{chunk-5KZTRD4V.js → chunk-Z6VLC5X4.js} +17 -17
  234. package/dist/{chunk-EDURU5DF.js → chunk-ZFQMMU5Y.js} +2 -2
  235. package/dist/{chunk-3GLDB4IT.js → chunk-ZKYRDV7A.js} +12 -12
  236. package/dist/{chunk-GBGJ6WSO.js → chunk-ZLS6PU2O.js} +3 -3
  237. package/dist/{chunk-JZOOX3PQ.js → chunk-ZOSD4FXV.js} +3 -3
  238. package/dist/chunk-ZPDDEVQX.js +47 -0
  239. package/dist/{chunk-2TTSX7NB.js → chunk-ZQLRCA2V.js} +7 -7
  240. package/dist/{chunk-ESP3RUUR.js → chunk-ZX7235KR.js} +128 -54
  241. package/dist/{chunk-MH4XG5XS.js → chunk-ZZFHLRQW.js} +18 -16
  242. package/dist/files.json +559 -439
  243. package/dist/packages/sdk/npm/index.js +4679 -2672
  244. package/dist/packages/ui/dist/assets/{elk-api-BuFBvNyV.js → elk-api-CowTnhEJ.js} +2 -2
  245. package/dist/packages/ui/dist/assets/index-Dw20IRhQ.css +1 -0
  246. package/dist/packages/ui/dist/assets/index-z2wv0d5d.js +47 -0
  247. package/dist/packages/ui/dist/index.html +2 -2
  248. package/package.json +3 -3
  249. package/dist/chunk-25TJC2CL.js +0 -48
  250. package/dist/chunk-3Q5RHGCA.js +0 -47
  251. package/dist/chunk-4W7FOGAB.js +0 -41
  252. package/dist/chunk-6AF3CVJT.js +0 -48
  253. package/dist/chunk-A3KEXFQS.js +0 -34
  254. package/dist/chunk-BAUINGGJ.js +0 -41
  255. package/dist/chunk-BOFUCRJX.js +0 -47
  256. package/dist/chunk-GGKGILIP.js +0 -54
  257. package/dist/chunk-IKN6C67W.js +0 -53
  258. package/dist/chunk-K7MYVIFK.js +0 -54
  259. package/dist/chunk-KHA5LVPE.js +0 -34
  260. package/dist/chunk-LSXGM6MB.js +0 -37
  261. package/dist/chunk-M54TDRM3.js +0 -29
  262. package/dist/chunk-M5GF4NAB.js +0 -45
  263. package/dist/chunk-UTZGBCXE.js +0 -38
  264. package/dist/chunk-UVTSMBM4.js +0 -43
  265. package/dist/chunk-XXE3S3OG.js +0 -44
  266. package/dist/chunk-YJRQCUVJ.js +0 -43
  267. package/dist/chunk-ZFTK4BDN.js +0 -41
  268. package/dist/chunk-ZMARAW37.js +0 -38
  269. package/dist/packages/ui/dist/assets/index-C5QnK82A.css +0 -1
  270. package/dist/packages/ui/dist/assets/index-CQ0a1cBg.js +0 -29
@@ -5,13 +5,13 @@ var __atticusUrl = (p) => new URL("./" + p, import.meta.url).href;
5
5
  var __atticusPath = (p) => __atticusFileURLToPath(__atticusUrl(p));
6
6
 
7
7
  // packages/core/dist/schema/version.js
8
- var SCHEMA_VERSION = 4;
8
+ var SCHEMA_VERSION = 5;
9
9
 
10
10
  // packages/core/dist/fs.js
11
11
  import { randomBytes } from "node:crypto";
12
12
  import { mkdir, readFile, rename, rm, writeFile } from "node:fs/promises";
13
13
  import { hostname } from "node:os";
14
- import { dirname, join } from "node:path";
14
+ import { dirname, join, resolve } from "node:path";
15
15
  async function writeFileAtomic(path, data) {
16
16
  await mkdir(dirname(path), { recursive: true });
17
17
  const tmp = `${path}.${process.pid}.${randomBytes(4).toString("hex")}.tmp`;
@@ -23,6 +23,32 @@ async function writeFileAtomic(path, data) {
23
23
  throw e;
24
24
  }
25
25
  }
26
+ var FileChangedError = class extends Error {
27
+ path;
28
+ constructor(path) {
29
+ super(`${path} changed since it was read (another edit, or a person's): nothing was written. Read it again and redo the change.`);
30
+ this.path = path;
31
+ }
32
+ };
33
+ var writing = /* @__PURE__ */ new Map();
34
+ function writeFileIfUnchanged(path, before, data) {
35
+ const key = resolve(path);
36
+ const prev = writing.get(key) ?? Promise.resolve();
37
+ const work = async () => {
38
+ const now = await readFile(path, "utf8").catch(() => void 0);
39
+ if (now !== before)
40
+ throw new FileChangedError(path);
41
+ await writeFileAtomic(path, data);
42
+ };
43
+ const next = prev.then(work, work);
44
+ const tail = next.catch(() => void 0);
45
+ writing.set(key, tail);
46
+ void tail.then(() => {
47
+ if (writing.get(key) === tail)
48
+ writing.delete(key);
49
+ });
50
+ return next;
51
+ }
26
52
  var BUSY = /* @__PURE__ */ new Set(["EPERM", "EBUSY", "EACCES"]);
27
53
  async function renameRetrying(from, to, tries = 9) {
28
54
  for (let i = 0; ; i++) {
@@ -39,12 +65,15 @@ async function renameRetrying(from, to, tries = 9) {
39
65
  }
40
66
  var LockHeldError = class extends Error {
41
67
  held;
42
- constructor(held) {
43
- super(`Another ${held.what} is running (process ${held.pid} on ${held.host}, since ${held.startedAt}). Wait for it to finish.`);
68
+ file;
69
+ constructor(held, file) {
70
+ super(`Another ${held.what} is running (process ${held.pid} on ${held.host}, since ${held.startedAt}). Wait for it to finish${file ? `; if nothing is running, delete ${file}` : ""}.`);
44
71
  this.held = held;
72
+ this.file = file;
45
73
  this.name = "LockHeldError";
46
74
  }
47
75
  };
76
+ var heldHere = /* @__PURE__ */ new Set();
48
77
  var lockFileOf = (root, name) => join(root, ".atticus", "locks", `${name}.json`);
49
78
  function alive(pid) {
50
79
  try {
@@ -54,16 +83,19 @@ function alive(pid) {
54
83
  return e.code === "EPERM";
55
84
  }
56
85
  }
57
- async function readLock(root, name) {
86
+ async function readLock(root, name, o = {}) {
58
87
  try {
59
- const info = JSON.parse(await readFile(lockFileOf(root, name), "utf8"));
60
- const stale = info.host === hostname() ? !alive(info.pid) : false;
88
+ const file = lockFileOf(root, name);
89
+ const info = JSON.parse(await readFile(file, "utf8"));
90
+ const here = info.host === hostname();
91
+ const age = (o.now ?? (() => /* @__PURE__ */ new Date()))().getTime() - Date.parse(info.startedAt);
92
+ const stale = here && (!alive(info.pid) || info.pid === process.pid && !heldHere.has(file)) || o.maxAgeMs !== void 0 && Number.isFinite(age) && age > o.maxAgeMs;
61
93
  return { ...info, stale };
62
94
  } catch {
63
95
  return void 0;
64
96
  }
65
97
  }
66
- async function acquireLock(root, name, what, now = () => /* @__PURE__ */ new Date()) {
98
+ async function acquireLock(root, name, what, now = () => /* @__PURE__ */ new Date(), o = {}) {
67
99
  const file = lockFileOf(root, name);
68
100
  await ensureLocalIgnore(root);
69
101
  await mkdir(dirname(file), { recursive: true });
@@ -77,18 +109,20 @@ async function acquireLock(root, name, what, now = () => /* @__PURE__ */ new Dat
77
109
  for (let attempt = 0; attempt < 2; attempt++) {
78
110
  try {
79
111
  await writeFile(file, JSON.stringify(info), { encoding: "utf8", flag: "wx" });
112
+ heldHere.add(file);
80
113
  const release = async () => {
81
114
  const cur = await readLock(root, name);
82
115
  if (cur && cur.pid === info.pid && cur.startedAt === info.startedAt)
83
116
  await rm(file, { force: true });
117
+ heldHere.delete(file);
84
118
  };
85
119
  return interrupted ? { release, interrupted } : { release };
86
120
  } catch (e) {
87
121
  if (e.code !== "EEXIST")
88
122
  throw e;
89
- const held = await readLock(root, name);
123
+ const held = await readLock(root, name, { ...o, now });
90
124
  if (held && !held.stale)
91
- throw new LockHeldError(held);
125
+ throw new LockHeldError(held, file);
92
126
  if (held) {
93
127
  const { stale: _s, ...rest } = held;
94
128
  interrupted = rest;
@@ -116,11 +150,10 @@ async function ensureLocalIgnore(root) {
116
150
  const missing = LOCAL_ONLY.filter((l) => !have.has(l));
117
151
  if (!missing.length)
118
152
  return;
119
- await mkdir(dirname(file), { recursive: true });
120
153
  const prefix = text && !text.endsWith("\n") ? `${text}
121
154
  ` : text;
122
- await writeFile(file, `${prefix}${prefix ? "" : "# This machine's own files: never committed.\n"}${missing.join("\n")}
123
- `, "utf8");
155
+ await writeFileAtomic(file, `${prefix}${prefix ? "" : "# This machine's own files: never committed.\n"}${missing.join("\n")}
156
+ `);
124
157
  }
125
158
 
126
159
  // packages/core/dist/log.js
@@ -245,6 +278,8 @@ var NO_LOG = {
245
278
  export {
246
279
  SCHEMA_VERSION,
247
280
  writeFileAtomic,
281
+ FileChangedError,
282
+ writeFileIfUnchanged,
248
283
  renameRetrying,
249
284
  LockHeldError,
250
285
  lockFileOf,
@@ -0,0 +1,533 @@
1
+ import { createRequire as __atticusCreateRequire } from "node:module";
2
+ import { fileURLToPath as __atticusFileURLToPath } from "node:url";
3
+ var require = __atticusCreateRequire(import.meta.url);
4
+ var __atticusUrl = (p) => new URL("./" + p, import.meta.url).href;
5
+ var __atticusPath = (p) => __atticusFileURLToPath(__atticusUrl(p));
6
+ import {
7
+ originOf
8
+ } from "./chunk-THN26IEF.js";
9
+ import {
10
+ isAdopted,
11
+ orgPackDirOf,
12
+ require_dist
13
+ } from "./chunk-PAINMSID.js";
14
+ import {
15
+ writeFileAtomic
16
+ } from "./chunk-ODMBPDDV.js";
17
+ import {
18
+ __toESM
19
+ } from "./chunk-TV45EUGM.js";
20
+
21
+ // packages/cli/dist/skills-commands.js
22
+ var import_yaml = __toESM(require_dist(), 1);
23
+ import { execFile } from "node:child_process";
24
+ import { createHash } from "node:crypto";
25
+ import { lstatSync, realpathSync } from "node:fs";
26
+ import { mkdir, readdir, readFile, rm } from "node:fs/promises";
27
+ import { tmpdir } from "node:os";
28
+ import { dirname, join, sep } from "node:path";
29
+ import { promisify } from "node:util";
30
+ var run = promisify(execFile);
31
+ var sha = (t) => createHash("sha256").update(t).digest("hex").slice(0, 16);
32
+ var lf = (t) => t.replace(/\r\n?/g, "\n");
33
+ var NAME = /^[a-z0-9][a-z0-9-]{0,62}$/;
34
+ var MARK = (src, h) => `<!-- atticus: written from ${src} (${h}); edit the source, or keep your edit here: atticus skills write leaves an edited file alone -->`;
35
+ var packRel = (root) => isAdopted(root) ? ".atticus/org-pack" : "org-pack";
36
+ function splitFm(text) {
37
+ const m = /^---\r?\n([\s\S]*?)\r?\n---\r?\n?([\s\S]*)$/.exec(text);
38
+ if (!m)
39
+ return { fm: {}, body: text };
40
+ try {
41
+ const fm = (0, import_yaml.parse)(m[1]);
42
+ return { fm: fm && typeof fm === "object" ? fm : {}, body: m[2] };
43
+ } catch {
44
+ return { fm: {}, body: m[2] };
45
+ }
46
+ }
47
+ var fmText = (o) => `---
48
+ ${(0, import_yaml.stringify)(o, { lineWidth: 0 }).trimEnd()}
49
+ ---
50
+ `;
51
+ async function filesUnder(dir, rel = "", links) {
52
+ const out = [];
53
+ for (const e of await readdir(dir, { withFileTypes: true }).catch(() => [])) {
54
+ const r = rel ? `${rel}/${e.name}` : e.name;
55
+ if (e.isSymbolicLink())
56
+ links?.push(r);
57
+ else if (e.isDirectory())
58
+ out.push(...await filesUnder(join(dir, e.name), r, links));
59
+ else if (e.isFile())
60
+ out.push(r);
61
+ }
62
+ return out.sort();
63
+ }
64
+ var REF = /^(?!.*(?:\.\.|\/\/|\.lock(?:\/|$)|\/$|\.$))[A-Za-z0-9][A-Za-z0-9._/-]{0,199}$/;
65
+ async function sourcesOf(root) {
66
+ const pack = orgPackDirOf(root);
67
+ const rel = packRel(root);
68
+ const out = [];
69
+ const scan = async (sub, team) => {
70
+ const sk = join(pack, "skills", sub);
71
+ for (const e of await readdir(sk, { withFileTypes: true }).catch(() => [])) {
72
+ if (!e.isDirectory() || e.name === "imported")
73
+ continue;
74
+ const d = join(sk, e.name);
75
+ const raw = await readFile(join(d, "SKILL.md"), "utf8").catch(() => void 0);
76
+ if (raw === void 0)
77
+ continue;
78
+ const text = lf(raw);
79
+ const files = (await filesUnder(d)).filter((f) => f !== "SKILL.md");
80
+ out.push({
81
+ kind: "skill",
82
+ name: e.name,
83
+ source: `${rel}/skills/${sub ? `${sub}/` : ""}${e.name}`,
84
+ ...team ? { team } : {},
85
+ text,
86
+ files: await Promise.all(files.map(async (f) => ({ path: f, text: lf(await readFile(join(d, f), "utf8")) })))
87
+ });
88
+ }
89
+ for (const [kind, folder] of [
90
+ ["agent", "agents"],
91
+ ["instructions", "instructions"]
92
+ ]) {
93
+ const d = join(pack, folder, sub);
94
+ for (const e of await readdir(d, { withFileTypes: true }).catch(() => [])) {
95
+ if (!e.isFile() || !e.name.endsWith(".md"))
96
+ continue;
97
+ out.push({
98
+ kind,
99
+ name: e.name.slice(0, -3),
100
+ source: `${rel}/${folder}/${sub ? `${sub}/` : ""}${e.name}`,
101
+ ...team ? { team } : {},
102
+ text: lf(await readFile(join(d, e.name), "utf8")),
103
+ files: []
104
+ });
105
+ }
106
+ }
107
+ };
108
+ await scan("");
109
+ const teams = /* @__PURE__ */ new Set();
110
+ for (const folder of ["skills", "agents", "instructions"])
111
+ for (const e of await readdir(join(pack, folder, "imported"), { withFileTypes: true }).catch(() => []))
112
+ if (e.isDirectory())
113
+ teams.add(e.name);
114
+ for (const t of [...teams].sort())
115
+ await scan(`imported/${t}`, t);
116
+ return out.sort((a, b) => a.kind + a.name < b.kind + b.name ? -1 : 1);
117
+ }
118
+ var TEAM_KEYS = {
119
+ skill: /* @__PURE__ */ new Set(["name", "description"]),
120
+ agent: /* @__PURE__ */ new Set(["name", "description", "tools", "disallowedTools"]),
121
+ instructions: /* @__PURE__ */ new Set(["name", "description"])
122
+ };
123
+ var TEAM_READ_TOOLS = ["Read", "Grep", "Glob"];
124
+ var TEAM_COPILOT_TOOLS = ["read", "search"];
125
+ var namesOf = (v) => (Array.isArray(v) ? v.map(String) : typeof v === "string" ? v.split(",") : []).map((x) => x.trim()).filter(Boolean);
126
+ function teamFrontmatter(kind, fm) {
127
+ const keep = TEAM_KEYS[kind];
128
+ const out = Object.fromEntries(Object.entries(fm).filter(([k]) => keep.has(k)));
129
+ let readOnly = false;
130
+ let toolsLeft = [];
131
+ if (kind === "agent") {
132
+ const asked = namesOf(fm.tools);
133
+ const kept = asked.filter((t) => TEAM_READ_TOOLS.includes(t));
134
+ toolsLeft = asked.filter((t) => !kept.includes(t));
135
+ readOnly = kept.length === 0;
136
+ out.tools = (readOnly ? [...TEAM_READ_TOOLS] : kept).join(", ");
137
+ }
138
+ return { fm: out, dropped: Object.keys(fm).filter((k) => !keep.has(k)), readOnly, toolsLeft };
139
+ }
140
+ function outputsOf(i) {
141
+ const { fm: all, body } = splitFm(i.text);
142
+ const fm = i.team ? teamFrontmatter(i.kind, all).fm : all;
143
+ const description = typeof fm.description === "string" && fm.description.trim() ? fm.description.trim() : (body.split("\n").find((l) => l.trim() && !l.startsWith("#")) ?? i.name).trim().slice(0, 200);
144
+ const from = i.team ? `${i.source} (${i.team})` : i.source;
145
+ const h = sha(i.text + i.files.map((f) => f.path + f.text).join(""));
146
+ const mark = MARK(from, h);
147
+ switch (i.kind) {
148
+ case "skill":
149
+ return [
150
+ {
151
+ path: `.claude/skills/${i.name}/SKILL.md`,
152
+ // Another team's skill is run by a person only, never picked by the model on its own
153
+ // (Claude Code and VS Code both read SKILL.md from here and honour this).
154
+ text: `${fmText({ ...fm, name: i.name, description, ...i.team ? { "disable-model-invocation": true } : {} })}${mark}
155
+ ${body}`
156
+ },
157
+ ...i.files.map((f) => ({ path: `.claude/skills/${i.name}/${f.path}`, text: f.text })),
158
+ {
159
+ path: `.github/prompts/${i.name}.prompt.md`,
160
+ // Another team's runs in ask mode (it reads; it edits nothing and runs no command).
161
+ text: `${fmText({ description, agent: i.team ? "ask" : "agent" })}${mark}
162
+ ${body}${i.files.length ? `
163
+
164
+ This skill's files are in \`.claude/skills/${i.name}/\`: ${i.files.map((f) => `\`${f.path}\``).join(", ")}.
165
+ ` : ""}`
166
+ }
167
+ ];
168
+ case "agent":
169
+ return [
170
+ {
171
+ path: `.claude/agents/${i.name}.md`,
172
+ text: `${fmText({ ...fm, name: i.name, description })}${mark}
173
+ ${body}`
174
+ },
175
+ {
176
+ path: `.github/agents/${i.name}.agent.md`,
177
+ // Another team's reads only in Copilot too (an agent with no tools there gets them all).
178
+ text: `${fmText({ name: i.name, description, ...i.team ? { tools: [...TEAM_COPILOT_TOOLS] } : {} })}${mark}
179
+ ${body}`
180
+ }
181
+ ];
182
+ case "instructions":
183
+ return [
184
+ {
185
+ path: `.github/instructions/${i.name}.instructions.md`,
186
+ // Applied by itself only where its source says (`applyTo`): with none, a person attaches
187
+ // it, so another team's words never reach a session (Atticus's own reads among them)
188
+ // that didn't ask for them. Another team's never apply by themselves: a person attaches
189
+ // them (their `applyTo` could reach every file, the reading sessions' too).
190
+ text: `${fmText({ description, ...typeof fm.applyTo === "string" && !i.team ? { applyTo: fm.applyTo } : {} })}${mark}
191
+ ${body}`
192
+ }
193
+ ];
194
+ }
195
+ }
196
+ function claudeBlock(items) {
197
+ const ins = items.filter((i) => i.kind === "instructions");
198
+ if (!ins.length)
199
+ return "";
200
+ const own = ins.filter((i) => !i.team);
201
+ const others = ins.filter((i) => i.team);
202
+ return [
203
+ "<!-- atticus:team-instructions:begin (written by atticus skills write; edit the sources in the org pack) -->",
204
+ "## Team instructions",
205
+ "",
206
+ ...own.map((i) => `- @${i.source}`),
207
+ ...others.length ? [
208
+ ...own.length ? [""] : [],
209
+ "Other teams' instructions, reviewed in the org pack; mention one to use it:",
210
+ "",
211
+ ...others.map((i) => `- \`${i.source}\` (from ${i.team})`)
212
+ ] : [],
213
+ "<!-- atticus:team-instructions:end -->"
214
+ ].join("\n");
215
+ }
216
+ var STATE = (root) => join(orgPackDirOf(root), "skills", ".written.yaml");
217
+ async function planWrite(root) {
218
+ const items = await sourcesOf(root);
219
+ const written = ((0, import_yaml.parse)(await readFile(STATE(root), "utf8").catch(() => "") || "{}") ?? {}).files ?? {};
220
+ const write = [];
221
+ const kept = [];
222
+ const clashes = [];
223
+ let current = 0;
224
+ const seen = /* @__PURE__ */ new Map();
225
+ const ordered = [...items].sort((a, b) => (a.team ?? "") < (b.team ?? "") ? -1 : (a.team ?? "") > (b.team ?? "") ? 1 : 0);
226
+ const used = [];
227
+ for (const i of ordered) {
228
+ const k = `${i.kind}:${i.name}`;
229
+ const first = seen.get(k);
230
+ if (first) {
231
+ clashes.push(`${i.source} and ${first.source} are both ${i.kind} ${i.name}: ${first.source} is written; rename one`);
232
+ continue;
233
+ }
234
+ seen.set(k, i);
235
+ used.push(i);
236
+ }
237
+ for (const i of used)
238
+ for (const o of outputsOf(i)) {
239
+ const raw = await readFile(join(root, ...o.path.split("/")), "utf8").catch(() => void 0);
240
+ const on = raw === void 0 ? void 0 : lf(raw);
241
+ if (on === lf(o.text)) {
242
+ current++;
243
+ continue;
244
+ }
245
+ const was = written[o.path];
246
+ const ours = raw !== void 0 && (was === sha(on) || was === sha(raw));
247
+ if (on !== void 0 && was && !ours)
248
+ kept.push(o.path);
249
+ else if (on !== void 0 && !written[o.path])
250
+ kept.push(o.path);
251
+ else
252
+ write.push(o);
253
+ }
254
+ const block = claudeBlock(used);
255
+ const claudePath = join(root, "CLAUDE.md");
256
+ const claude = await readFile(claudePath, "utf8").catch(() => "");
257
+ const re = /<!-- atticus:team-instructions:begin[\s\S]*?atticus:team-instructions:end -->/;
258
+ const next = block ? re.test(claude) ? claude.replace(re, () => block) : `${claude.trimEnd()}${claude.trim() ? "\n\n" : ""}${block}
259
+ ` : claude.replace(re, "").trimEnd() + (claude.trim() ? "\n" : "");
260
+ return { write, kept, current, clashes, ...next !== claude ? { claude: next } : {} };
261
+ }
262
+ async function skillsWriteCommand(root, o, io) {
263
+ const p = await planWrite(root);
264
+ for (const c of p.clashes)
265
+ io.err(c);
266
+ if (o.check) {
267
+ for (const f of p.write)
268
+ io.out(`behind: ${f.path}`);
269
+ if (p.claude)
270
+ io.out("behind: CLAUDE.md (team instructions)");
271
+ for (const k of p.kept)
272
+ io.out(`edited here, kept: ${k}`);
273
+ const behind = p.write.length + (p.claude ? 1 : 0);
274
+ io.out(behind ? `${behind} files are behind the org pack: atticus skills write` : "The skills, agents and instructions written are current.");
275
+ return behind ? 1 : 0;
276
+ }
277
+ const state = ((0, import_yaml.parse)(await readFile(STATE(root), "utf8").catch(() => "") || "{}") ?? {}).files ?? {};
278
+ for (const f of p.write) {
279
+ await mkdir(dirname(join(root, ...f.path.split("/"))), { recursive: true });
280
+ await writeFileAtomic(join(root, ...f.path.split("/")), f.text);
281
+ state[f.path] = sha(lf(f.text));
282
+ io.out(`wrote ${f.path}`);
283
+ }
284
+ if (p.claude !== void 0) {
285
+ await writeFileAtomic(join(root, "CLAUDE.md"), p.claude);
286
+ io.out("wrote CLAUDE.md (team instructions)");
287
+ }
288
+ for (const k of p.kept)
289
+ io.out(`kept ${k}: it was edited here; remove it to have it written again`);
290
+ await mkdir(dirname(STATE(root)), { recursive: true });
291
+ await writeFileAtomic(STATE(root), (0, import_yaml.stringify)({ schemaVersion: 1, files: Object.fromEntries(Object.entries(state).sort()) }));
292
+ io.out(`${p.write.length} written, ${p.current} current, ${p.kept.length} kept as edited.`);
293
+ return 0;
294
+ }
295
+ function factsWithoutSource(text) {
296
+ const claims = /\b(topic|queue|schema|endpoint|field|payload|contract|route)s?\b/i.test(text);
297
+ const grounded = /\batticus (ask|query|guide|show|contracts|flows|map|catalog)\b|\/atticus-/i.test(text);
298
+ return claims && !grounded;
299
+ }
300
+ function inside(dir, rel) {
301
+ try {
302
+ const top = realpathSync(dir);
303
+ const p = realpathSync(join(dir, ...rel.split("/")));
304
+ return p === top || p.startsWith(top + sep);
305
+ } catch {
306
+ return false;
307
+ }
308
+ }
309
+ async function theirs(dir) {
310
+ const out = [];
311
+ const has = (p) => {
312
+ try {
313
+ return lstatSync(join(dir, ...p.split("/"))).isFile();
314
+ } catch {
315
+ return false;
316
+ }
317
+ };
318
+ for (const base of [".claude/skills", "org-pack/skills"])
319
+ for (const e of await readdir(join(dir, ...base.split("/")), { withFileTypes: true }).catch(() => []))
320
+ if (e.isDirectory() && e.name !== "imported" && has(`${base}/${e.name}/SKILL.md`))
321
+ out.push({
322
+ kind: "skill",
323
+ name: e.name,
324
+ path: `${base}/${e.name}/SKILL.md`,
325
+ folder: `${base}/${e.name}`
326
+ });
327
+ for (const [base, suffix] of [
328
+ [".claude/agents", ".md"],
329
+ ["org-pack/agents", ".md"],
330
+ [".github/agents", ".agent.md"],
331
+ [".github/chatmodes", ".chatmode.md"]
332
+ ])
333
+ for (const e of await readdir(join(dir, ...base.split("/")), { withFileTypes: true }).catch(() => []))
334
+ if (e.isFile() && e.name.endsWith(suffix))
335
+ out.push({
336
+ kind: "agent",
337
+ name: e.name.slice(0, -suffix.length),
338
+ path: `${base}/${e.name}`
339
+ });
340
+ for (const [base, suffix] of [
341
+ [".github/instructions", ".instructions.md"],
342
+ ["org-pack/instructions", ".md"]
343
+ ])
344
+ for (const e of await readdir(join(dir, ...base.split("/")), { withFileTypes: true }).catch(() => []))
345
+ if (e.isFile() && e.name.endsWith(suffix))
346
+ out.push({
347
+ kind: "instructions",
348
+ name: e.name.slice(0, -suffix.length),
349
+ path: `${base}/${e.name}`
350
+ });
351
+ const seen = /* @__PURE__ */ new Set();
352
+ return out.filter((x) => inside(dir, x.folder ?? x.path) && !seen.has(`${x.kind}:${x.name}`) && !!seen.add(`${x.kind}:${x.name}`));
353
+ }
354
+ async function skillsImportCommand(root, from, o, io) {
355
+ if (!from || !o.team) {
356
+ io.err("Usage: atticus skills import <their repo folder> --team <their team> [--at <tag>] [--only <names>]");
357
+ return 2;
358
+ }
359
+ if (!NAME.test(o.team)) {
360
+ io.err("--team is lower case, digits and dashes.");
361
+ return 2;
362
+ }
363
+ if (o.at !== void 0 && !REF.test(o.at)) {
364
+ io.err(`${o.at} isn't a tag or branch name.`);
365
+ return 2;
366
+ }
367
+ let dir = from;
368
+ let tmp;
369
+ if (o.at) {
370
+ tmp = join(tmpdir(), `atticus-import-${o.team}-${Date.now()}`);
371
+ try {
372
+ await mkdir(dirname(tmp), { recursive: true });
373
+ await run("git", [
374
+ "-C",
375
+ from,
376
+ "-c",
377
+ `core.hooksPath=${tmp}.no-hooks`,
378
+ "worktree",
379
+ "add",
380
+ "--detach",
381
+ "--",
382
+ tmp,
383
+ `${o.at}^{commit}`
384
+ ]);
385
+ dir = tmp;
386
+ } catch (e) {
387
+ io.err(`${from} has no ${o.at}: ${e.message.split("\n")[0]}`);
388
+ return 2;
389
+ }
390
+ }
391
+ try {
392
+ const only = o.only ? new Set(o.only.split(",").map((x) => x.trim())) : void 0;
393
+ const found = (await theirs(dir)).filter((x) => !only || only.has(x.name));
394
+ if (!found.length) {
395
+ io.err(`${from} has no skills (.claude/skills/<name>/SKILL.md), agents or instructions${only ? ` named ${[...only].join(", ")}` : ""}.`);
396
+ return 2;
397
+ }
398
+ const pack = orgPackDirOf(root);
399
+ const provPath = join(pack, "imported", `${o.team}.yaml`);
400
+ const prov = (0, import_yaml.parse)(await readFile(provPath, "utf8").catch(() => "") || "{}") ?? {};
401
+ const was = new Map((prov.items ?? []).map((x) => [`${x.kind}:${x.name}`, x.files]));
402
+ const items = [];
403
+ const origin = await originOf(from, (a) => run("git", a));
404
+ const notes = [];
405
+ const taken = new Map((await sourcesOf(root)).filter((x) => x.team !== o.team).map((x) => [`${x.kind}:${x.name}`, x.team ?? "this organisation"]));
406
+ for (const f of found) {
407
+ const owner = taken.get(`${f.kind}:${f.name}`);
408
+ if (owner) {
409
+ notes.push(`skipped ${f.kind} ${f.name}: ${owner} has one of that name already (the written files are one set); rename theirs or yours`);
410
+ continue;
411
+ }
412
+ if (!NAME.test(f.name)) {
413
+ notes.push(`skipped ${f.path}: ${f.name} isn't a name Atticus writes (lower case, digits, dashes)`);
414
+ continue;
415
+ }
416
+ const dest = f.kind === "skill" ? join(pack, "skills", "imported", o.team, f.name) : join(pack, f.kind === "agent" ? "agents" : "instructions", "imported", o.team);
417
+ const files = {};
418
+ let copied = true;
419
+ const copy = async (src, to, key) => {
420
+ if (!inside(dir, src)) {
421
+ copied = false;
422
+ notes.push(`left out ${src}: it isn't in their repo (a link to somewhere else)`);
423
+ return;
424
+ }
425
+ const text = await readFile(join(dir, ...src.split("/")), "utf8");
426
+ const on = await readFile(to, "utf8").catch(() => void 0);
427
+ const before = was.get(`${f.kind}:${f.name}`)?.[key];
428
+ if (on !== void 0 && before && sha(on) !== before && sha(on) !== sha(text) && !o.replace) {
429
+ notes.push(`kept ${to.slice(root.length + 1)}: edited here since the last import (--replace takes theirs)`);
430
+ files[key] = before;
431
+ return;
432
+ }
433
+ await mkdir(dirname(to), { recursive: true });
434
+ await writeFileAtomic(to, text);
435
+ files[key] = sha(text);
436
+ };
437
+ if (f.kind === "skill") {
438
+ const links = [];
439
+ const all = await filesUnder(join(dir, ...f.folder.split("/")), "", links);
440
+ if (links.length)
441
+ notes.push(`${f.name}: left out ${links.join(", ")}: a link to a file elsewhere is never copied`);
442
+ for (const p of all)
443
+ await copy(`${f.folder}/${p}`, join(dest, ...p.split("/")), p);
444
+ const theirsNow = new Set(all);
445
+ for (const p of (await filesUnder(dest).catch(() => [])).filter((x) => !theirsNow.has(x))) {
446
+ const here = await readFile(join(dest, ...p.split("/")), "utf8").catch(() => void 0);
447
+ const before = was.get(`${f.kind}:${f.name}`)?.[p];
448
+ if (here !== void 0 && !before) {
449
+ notes.push(`kept ${f.name}/${p}: added here, not one of ${o.team}'s`);
450
+ } else if (here !== void 0 && before && sha(here) !== before && !o.replace) {
451
+ notes.push(`kept ${f.name}/${p}: ${o.team} removed it, but it was edited here`);
452
+ files[p] = before;
453
+ } else {
454
+ await rm(join(dest, ...p.split("/")), { force: true });
455
+ notes.push(`removed ${f.name}/${p}: ${o.team} no longer has it`);
456
+ }
457
+ }
458
+ const scripts = all.filter((p) => !/\.(md|txt|ya?ml|json)$/i.test(p));
459
+ if (scripts.length)
460
+ notes.push(`${f.name} carries files that may run (${scripts.join(", ")}): review them in the PR; nothing ran here`);
461
+ const skillText = await readFile(join(dest, "SKILL.md"), "utf8");
462
+ if (factsWithoutSource(skillText))
463
+ notes.push(`${f.name} states things about the estate (topics, fields, routes) with no atticus command to get them: a reviewer checks it against the map`);
464
+ } else
465
+ await copy(f.path, join(dest, `${f.name}.md`), `${f.name}.md`);
466
+ const mainFile = f.kind === "skill" ? join(dest, "SKILL.md") : join(dest, `${f.name}.md`);
467
+ const t = teamFrontmatter(f.kind, splitFm(await readFile(mainFile, "utf8").catch(() => "")).fm);
468
+ if (t.dropped.length && copied)
469
+ notes.push(`${f.name}: left out of what the assistants read: ${t.dropped.join(", ")} (another team's file can't give itself these here; set them in your own copy if you want them)`);
470
+ if (f.kind === "agent" && copied)
471
+ notes.push(t.toolsLeft.length ? `${f.name} asks for ${t.toolsLeft.join(", ")}: another team's agent reads only here (${TEAM_READ_TOOLS.join(", ")}); give it more in your own copy if you want` : t.readOnly ? `${f.name} names no read tools, so it is written to read only (${TEAM_READ_TOOLS.join(", ")})` : `${f.name} reads only, as its tools say`);
472
+ items.push({ kind: f.kind, name: f.name, files, from: origin, at: o.at ?? "working copy" });
473
+ }
474
+ await mkdir(dirname(provPath), { recursive: true });
475
+ await writeFileAtomic(provPath, (0, import_yaml.stringify)({
476
+ schemaVersion: 1,
477
+ team: o.team,
478
+ // Where it came from, as the metarepo sees it (no one's home folder in a committed file).
479
+ from: origin,
480
+ at: o.at ?? "working copy",
481
+ // An import of some (--only) keeps the record of the rest.
482
+ items: [
483
+ ...(prov.items ?? []).filter((x) => !items.some((y) => y.kind === x.kind && y.name === x.name)),
484
+ ...items
485
+ ].sort((a, b) => `${a.kind}:${a.name}`.localeCompare(`${b.kind}:${b.name}`))
486
+ }));
487
+ io.out(`Imported ${items.length} from ${o.team}${o.at ? ` at ${o.at}` : ""} into ${packRel(root)}/{skills,agents,instructions}/imported/${o.team}/, provenance in ${packRel(root)}/imported/${o.team}.yaml.`);
488
+ for (const n of notes)
489
+ io.out(` ${n}`);
490
+ io.out("Review the copy in a pull request; then atticus skills write puts it where Claude and Copilot read it.");
491
+ return 0;
492
+ } finally {
493
+ if (tmp) {
494
+ await run("git", ["-C", from, "worktree", "remove", "--force", tmp]).catch(() => void 0);
495
+ await rm(tmp, { recursive: true, force: true }).catch(() => void 0);
496
+ }
497
+ }
498
+ }
499
+ async function skillsListCommand(root, o, io) {
500
+ const items = await sourcesOf(root);
501
+ if (o.json) {
502
+ io.out(JSON.stringify(items.map((i) => ({
503
+ kind: i.kind,
504
+ name: i.name,
505
+ source: i.source,
506
+ team: i.team,
507
+ writes: outputsOf(i).map((x) => x.path)
508
+ })), null, 2));
509
+ return 0;
510
+ }
511
+ if (!items.length) {
512
+ io.out(`No skills, agents or instructions in ${packRel(root)} yet. Take another team's: atticus skills import <their repo> --team <team> --at <tag>.`);
513
+ return 0;
514
+ }
515
+ for (const i of items)
516
+ io.out(`${i.kind} ${i.name}${i.team ? ` (from ${i.team})` : ""}: ${i.source} \u2192 ${outputsOf(i).filter((x) => !x.path.includes("/" + i.name + "/") || x.path.endsWith("SKILL.md")).map((x) => x.path).join(", ")}`);
517
+ return 0;
518
+ }
519
+
520
+ export {
521
+ splitFm,
522
+ REF,
523
+ sourcesOf,
524
+ teamFrontmatter,
525
+ outputsOf,
526
+ claudeBlock,
527
+ planWrite,
528
+ skillsWriteCommand,
529
+ factsWithoutSource,
530
+ inside,
531
+ skillsImportCommand,
532
+ skillsListCommand
533
+ };
@@ -3,6 +3,9 @@ import { fileURLToPath as __atticusFileURLToPath } from "node:url";
3
3
  var require = __atticusCreateRequire(import.meta.url);
4
4
  var __atticusUrl = (p) => new URL("./" + p, import.meta.url).href;
5
5
  var __atticusPath = (p) => __atticusFileURLToPath(__atticusUrl(p));
6
+ import {
7
+ isInPlace
8
+ } from "./chunk-XOL3GFW2.js";
6
9
 
7
10
  // packages/cli/dist/repo-ids.js
8
11
  function repoIdKey(id) {
@@ -10,7 +13,7 @@ function repoIdKey(id) {
10
13
  }
11
14
  function cloneUrlKey(url) {
12
15
  const u = url.trim();
13
- if (!u || u === "." || u.startsWith("./") || u.startsWith("../"))
16
+ if (!u || isInPlace(u) || /^\.\.[\\/]/.test(u))
14
17
  return void 0;
15
18
  return u.replace(/[/\\]+$/, "").replace(/\.git$/i, "").replace(/^[a-z][a-z0-9+.-]*:\/\//i, "").replace(/^[^@/]+@/, "").replace(/^([^/:]+):(?!\d+\/)/, "$1/").toLowerCase();
16
19
  }