@qitqode/qitqode-android-arm64 0.1.29 → 0.1.31

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 (414) hide show
  1. package/bundle/{chunk-g06rv5fq.js → chunk-01my2y0c.js} +1 -1
  2. package/bundle/chunk-04n2ycg5.js +800 -0
  3. package/bundle/{chunk-k7dcfqjs.js → chunk-05mce0j3.js} +1 -1
  4. package/bundle/{chunk-3q6650we.js → chunk-0bbs01f0.js} +1 -1
  5. package/bundle/{chunk-1rn0vmvv.js → chunk-0dt0bxz6.js} +2 -2
  6. package/bundle/{chunk-x6nbck7p.js → chunk-0mx2psfc.js} +1 -1
  7. package/bundle/chunk-0p27fvfr.js +2 -0
  8. package/bundle/chunk-0qs1vx97.js +2 -0
  9. package/bundle/{chunk-8kz3n8ye.js → chunk-0v0vqbn5.js} +1 -1
  10. package/bundle/chunk-0w0ctb90.js +2 -0
  11. package/bundle/chunk-0yt5njh7.js +8 -0
  12. package/bundle/{chunk-fsy279s5.js → chunk-10bjs581.js} +2 -2
  13. package/bundle/{chunk-z29fwg61.js → chunk-11x3t2tt.js} +1 -1
  14. package/bundle/{chunk-qzjpea91.js → chunk-12vef2pr.js} +1 -1
  15. package/bundle/{chunk-kkae8ead.js → chunk-15hw2z9t.js} +1 -1
  16. package/bundle/chunk-1f7ajq8s.js +2 -0
  17. package/bundle/chunk-1fswr17z.js +2 -0
  18. package/bundle/{chunk-yt2k9ga8.js → chunk-1gx18dm5.js} +1 -1
  19. package/bundle/chunk-1rhhhm88.js +2 -0
  20. package/bundle/{chunk-b4qd109w.js → chunk-1sgahe1s.js} +1 -1
  21. package/bundle/{chunk-74zgcxeg.js → chunk-1vb79bw1.js} +1 -1
  22. package/bundle/chunk-1wbjh23g.js +2 -0
  23. package/bundle/chunk-20f83ca0.js +2 -0
  24. package/bundle/{chunk-ed723mw1.js → chunk-24jg9d61.js} +1 -1
  25. package/bundle/{chunk-csdm3n24.js → chunk-2hc5z7b5.js} +1 -1
  26. package/bundle/{chunk-bzrsnv2k.js → chunk-2maqde7w.js} +2 -2
  27. package/bundle/{chunk-awav98j0.js → chunk-2vn41ecx.js} +1 -1
  28. package/bundle/{chunk-50w28xj1.js → chunk-2zq4k837.js} +1 -1
  29. package/bundle/chunk-31mnd3ph.js +3 -0
  30. package/bundle/{chunk-a2qerqgd.js → chunk-31qrzrwy.js} +1 -1
  31. package/bundle/{chunk-abtn6nec.js → chunk-326p5b10.js} +2 -2
  32. package/bundle/{chunk-2p2ch1k2.js → chunk-33e9y2aw.js} +1 -1
  33. package/bundle/{chunk-asmfntjm.js → chunk-35xk4g91.js} +1 -1
  34. package/bundle/{chunk-n86s4fw4.js → chunk-3632wgg1.js} +1 -1
  35. package/bundle/{chunk-tqsx2m1j.js → chunk-3bxg5bta.js} +1 -1
  36. package/bundle/{chunk-6bsgrr5h.js → chunk-3c6p8tm3.js} +1 -1
  37. package/bundle/chunk-3h9rq2wq.js +2 -0
  38. package/bundle/{chunk-7wthn44y.js → chunk-3ytjm3az.js} +1 -1
  39. package/bundle/{chunk-2mjc44ev.js → chunk-40efytmk.js} +1 -1
  40. package/bundle/chunk-42p59wm4.js +2 -0
  41. package/bundle/{chunk-09j71kp6.js → chunk-44a82dg0.js} +4 -4
  42. package/bundle/chunk-4512pvca.js +2 -0
  43. package/bundle/chunk-456bmaww.js +2 -0
  44. package/bundle/{chunk-s6me101a.js → chunk-48ge2ryx.js} +1 -1
  45. package/bundle/chunk-48pajrnt.js +2 -0
  46. package/bundle/{chunk-hn1f6rne.js → chunk-4cnwn1rh.js} +2 -2
  47. package/bundle/chunk-4d87mhwn.js +3 -0
  48. package/bundle/chunk-4fy9c54h.js +2 -0
  49. package/bundle/{chunk-43ae3chd.js → chunk-4gkk28xk.js} +2 -2
  50. package/bundle/{chunk-bsf6n350.js → chunk-4jtxtkj7.js} +2 -2
  51. package/bundle/{chunk-pq2prhb2.js → chunk-50sv6y2e.js} +1 -1
  52. package/bundle/chunk-50tb3g5x.js +2 -0
  53. package/bundle/chunk-52bam8g7.js +2 -0
  54. package/bundle/{chunk-zqxmr01r.js → chunk-53bqcctj.js} +1 -1
  55. package/bundle/chunk-53w4zqps.js +2 -0
  56. package/bundle/chunk-59y8q9m5.js +2 -0
  57. package/bundle/chunk-5eq1fft9.js +3 -0
  58. package/bundle/{chunk-8f0g7d7k.js → chunk-5hw6xa49.js} +2 -2
  59. package/bundle/{chunk-9epjgend.js → chunk-5q4harvc.js} +2 -2
  60. package/bundle/chunk-5tray1fw.js +3 -0
  61. package/bundle/{chunk-a2g69pv6.js → chunk-5v0xjs3x.js} +1 -1
  62. package/bundle/{chunk-ce5t444d.js → chunk-60v5jvgt.js} +1 -1
  63. package/bundle/chunk-64ezpbwt.js +2 -0
  64. package/bundle/{chunk-b9hstp7h.js → chunk-68yw2hk9.js} +1 -1
  65. package/bundle/{chunk-hhgjbag9.js → chunk-69nzndk7.js} +1 -1
  66. package/bundle/chunk-6bpe215q.js +2 -0
  67. package/bundle/chunk-6bphjajd.js +2 -0
  68. package/bundle/{chunk-qredfmch.js → chunk-6d5rrre9.js} +1 -1
  69. package/bundle/{chunk-mb4wvwfw.js → chunk-6hpgb8h4.js} +3 -3
  70. package/bundle/{chunk-88dhcv37.js → chunk-6kp07m7p.js} +1 -1
  71. package/bundle/{chunk-csyw14fj.js → chunk-6phh70sp.js} +1 -1
  72. package/bundle/chunk-6t1ehq36.js +2 -0
  73. package/bundle/{chunk-hgbkg85g.js → chunk-70ck4v3t.js} +1 -1
  74. package/bundle/{chunk-3n49y4kh.js → chunk-71sjjjr8.js} +1 -1
  75. package/bundle/{chunk-geccvf9d.js → chunk-71xz70r9.js} +1 -1
  76. package/bundle/{chunk-9kjj44cr.js → chunk-73e409hd.js} +1 -1
  77. package/bundle/{chunk-1xw68zak.js → chunk-78ymd20x.js} +1 -1
  78. package/bundle/{chunk-n4gjpgnk.js → chunk-7avcnwv8.js} +1 -1
  79. package/bundle/{chunk-z8v2tsz2.js → chunk-7hm0c2yg.js} +1 -1
  80. package/bundle/{chunk-kfgn4apg.js → chunk-7mke41x0.js} +1 -1
  81. package/bundle/chunk-7pfj4x1a.js +2 -0
  82. package/bundle/chunk-7ry9cvby.js +2 -0
  83. package/bundle/chunk-7wczs9mx.js +2 -0
  84. package/bundle/{chunk-yjj4cvqg.js → chunk-7xm75w1e.js} +1 -1
  85. package/bundle/{chunk-y212x7ws.js → chunk-7z5jh4ra.js} +1 -1
  86. package/bundle/{chunk-98vfbn0h.js → chunk-81qwdg5s.js} +1 -1
  87. package/bundle/{chunk-r4mnbhe1.js → chunk-83gqkmth.js} +1 -1
  88. package/bundle/chunk-873skv7w.js +2 -0
  89. package/bundle/{chunk-ndmrg80b.js → chunk-8hytwgwf.js} +1 -1
  90. package/bundle/{chunk-0wdtbn59.js → chunk-8n20thvd.js} +2 -2
  91. package/bundle/{chunk-xn61fgrh.js → chunk-8qswepp2.js} +1 -1
  92. package/bundle/chunk-8v96pmqn.js +2 -0
  93. package/bundle/chunk-8y2scz6z.js +2 -0
  94. package/bundle/{chunk-7mc8nxve.js → chunk-8ymffyep.js} +1 -1
  95. package/bundle/chunk-8zx7vnx6.js +2 -0
  96. package/bundle/{chunk-8k55xz7z.js → chunk-93p131d5.js} +1 -1
  97. package/bundle/chunk-94a76f8w.js +2 -0
  98. package/bundle/{chunk-3h4y7n1a.js → chunk-9emq67vc.js} +1 -1
  99. package/bundle/{chunk-ypthfv6d.js → chunk-9f1z9xce.js} +1 -1
  100. package/bundle/chunk-9mjz6e27.js +2 -0
  101. package/bundle/chunk-9ng7jjp7.js +2 -0
  102. package/bundle/chunk-9tpgnjy8.js +2 -0
  103. package/bundle/{chunk-f29n7826.js → chunk-9x5232dw.js} +1 -1
  104. package/bundle/{chunk-t3tkp1em.js → chunk-a1wdeapb.js} +1 -1
  105. package/bundle/{chunk-b20xjnpw.js → chunk-a7amey9s.js} +1 -1
  106. package/bundle/chunk-a7ym9f0v.js +2 -0
  107. package/bundle/chunk-a8f2xvy3.js +2 -0
  108. package/bundle/chunk-a99cvwta.js +2 -0
  109. package/bundle/chunk-abd1cfpg.js +2 -0
  110. package/bundle/{chunk-yn576pje.js → chunk-ag8kz1e7.js} +2 -2
  111. package/bundle/chunk-anwnwfjf.js +2 -0
  112. package/bundle/chunk-avys5mnz.js +2 -0
  113. package/bundle/chunk-axvjd10y.js +2 -0
  114. package/bundle/{chunk-4vze3djr.js → chunk-ay8emwym.js} +1 -1
  115. package/bundle/chunk-b4pphqab.js +2 -0
  116. package/bundle/chunk-b6087ak4.js +2 -0
  117. package/bundle/{chunk-qje3683x.js → chunk-b8gjz6bk.js} +1 -1
  118. package/bundle/chunk-bgw4fvg2.js +2 -0
  119. package/bundle/{chunk-q0xzbad1.js → chunk-bh53dz71.js} +1 -1
  120. package/bundle/chunk-brkqxbjy.js +2 -0
  121. package/bundle/{chunk-j2zay4da.js → chunk-c11d28qn.js} +2 -2
  122. package/bundle/{chunk-hd2kb05a.js → chunk-c14s0kxq.js} +1 -1
  123. package/bundle/{chunk-qsszerj7.js → chunk-c1bdzxbx.js} +2 -2
  124. package/bundle/{chunk-v9xnk9pz.js → chunk-c1vnp55z.js} +1 -1
  125. package/bundle/chunk-c26qxt5g.js +2 -0
  126. package/bundle/chunk-c6zscb38.js +2 -0
  127. package/bundle/{chunk-g0mbbysk.js → chunk-cfgvm15x.js} +1 -1
  128. package/bundle/{chunk-jntqzhxr.js → chunk-chpr8ekb.js} +1 -1
  129. package/bundle/chunk-cjww2jmv.js +3 -0
  130. package/bundle/{chunk-hbtd620x.js → chunk-ck2gfaba.js} +1 -1
  131. package/bundle/chunk-cmbh77cs.js +7 -0
  132. package/bundle/{chunk-eqcd9k9p.js → chunk-cnmq5xtq.js} +218 -218
  133. package/bundle/{chunk-azx0zxnx.js → chunk-cphrgyp6.js} +1 -1
  134. package/bundle/chunk-csz0dgyp.js +2 -0
  135. package/bundle/{chunk-fhdpp77n.js → chunk-ctaze2hn.js} +1 -1
  136. package/bundle/{chunk-n5sh2790.js → chunk-cxnfy6qk.js} +1 -1
  137. package/bundle/{chunk-yn05n0az.js → chunk-d07p6fpk.js} +2 -2
  138. package/bundle/{chunk-kw09hbrb.js → chunk-d65qs4d0.js} +1 -1
  139. package/bundle/{chunk-xk1nh1ay.js → chunk-d68fzyw7.js} +2 -2
  140. package/bundle/{chunk-6hdjkvr1.js → chunk-d6ry9418.js} +2 -2
  141. package/bundle/{chunk-zbq60sw6.js → chunk-dactgryw.js} +1 -1
  142. package/bundle/chunk-dafmkrhn.js +2 -0
  143. package/bundle/{chunk-qzcfjz9g.js → chunk-db405hjg.js} +1 -1
  144. package/bundle/chunk-dgprdym0.js +2 -0
  145. package/bundle/{chunk-v7deh7aj.js → chunk-dnwefyhv.js} +1 -1
  146. package/bundle/{chunk-scqxmv8k.js → chunk-drvkj3xg.js} +1 -1
  147. package/bundle/chunk-dryzt12j.js +2 -0
  148. package/bundle/chunk-dsamees2.js +2 -0
  149. package/bundle/{chunk-bv8pf0m1.js → chunk-dxpj0cxh.js} +2 -2
  150. package/bundle/{chunk-nv2r4cns.js → chunk-dynv30gm.js} +1 -1
  151. package/bundle/chunk-dyqpxx3b.js +2 -0
  152. package/bundle/{chunk-pg8dz1rq.js → chunk-e01wnqvc.js} +1 -1
  153. package/bundle/{chunk-z160s5p5.js → chunk-e10py6yr.js} +1 -1
  154. package/bundle/{chunk-xk7je9y8.js → chunk-e7ny0b3x.js} +1 -1
  155. package/bundle/{chunk-2w20mhch.js → chunk-eh7e49k4.js} +1 -1
  156. package/bundle/{chunk-6jewfaqa.js → chunk-ehhas0ew.js} +2 -2
  157. package/bundle/{chunk-6scqd8fh.js → chunk-ejrhvy38.js} +1 -1
  158. package/bundle/{chunk-sv48x9h8.js → chunk-enpzvmtc.js} +1 -1
  159. package/bundle/chunk-excnptfy.js +2 -0
  160. package/bundle/chunk-ez8vkgfz.js +2 -0
  161. package/bundle/chunk-f2btnww9.js +2 -0
  162. package/bundle/chunk-f8eter69.js +5 -0
  163. package/bundle/{chunk-7926bzm7.js → chunk-fgg9txzb.js} +1 -1
  164. package/bundle/chunk-fjq3a347.js +2 -0
  165. package/bundle/{chunk-6528bthc.js → chunk-fn9h4ync.js} +1 -1
  166. package/bundle/{chunk-m2ny1en7.js → chunk-fq0x3esz.js} +5 -5
  167. package/bundle/{chunk-h8chkene.js → chunk-fvzwbjh8.js} +1 -1
  168. package/bundle/chunk-fxdtq2ed.js +2 -0
  169. package/bundle/{chunk-sbx9z70j.js → chunk-fyqjm5fv.js} +1 -1
  170. package/bundle/{chunk-t35n89t9.js → chunk-g10d6x57.js} +1 -1
  171. package/bundle/{chunk-1d9f53sk.js → chunk-g5rabwre.js} +2 -2
  172. package/bundle/{chunk-4fk4se02.js → chunk-g7ccdh7r.js} +1 -1
  173. package/bundle/{chunk-0yqbyres.js → chunk-g9cjsfvg.js} +1 -1
  174. package/bundle/{chunk-yvqbewmc.js → chunk-gagtmjmp.js} +2 -2
  175. package/bundle/{chunk-4fspp5fg.js → chunk-gb00fh4z.js} +3 -3
  176. package/bundle/{chunk-44jpsp97.js → chunk-gbpvs0fx.js} +1 -1
  177. package/bundle/{chunk-v9bmpndq.js → chunk-gbrnn2dk.js} +1 -1
  178. package/bundle/chunk-gcw4rn10.js +2 -0
  179. package/bundle/{chunk-j8efst22.js → chunk-gj0wt0cy.js} +1 -1
  180. package/bundle/{chunk-rptvpa1v.js → chunk-gsar6xda.js} +1 -1
  181. package/bundle/{chunk-nxn4arcf.js → chunk-gt31468k.js} +1 -1
  182. package/bundle/{chunk-c19t7e8s.js → chunk-gwp17r03.js} +1 -1
  183. package/bundle/chunk-gwzw92jt.js +2 -0
  184. package/bundle/{chunk-z5yrvg40.js → chunk-h2afsbm1.js} +1 -1
  185. package/bundle/{chunk-d86ma6zk.js → chunk-h4j5xzc8.js} +1 -1
  186. package/bundle/{chunk-hevb7k95.js → chunk-hbbsbyyq.js} +1 -1
  187. package/bundle/chunk-hnctaq8s.js +3 -0
  188. package/bundle/{chunk-g3ch14a1.js → chunk-hnzegjgv.js} +1 -1
  189. package/bundle/chunk-hp7tssgv.js +2 -0
  190. package/bundle/chunk-ht0hbdmx.js +2 -0
  191. package/bundle/{chunk-ekndhwnn.js → chunk-ht5w06x7.js} +2 -2
  192. package/bundle/{chunk-a8p9aggx.js → chunk-htz93dsd.js} +1 -1
  193. package/bundle/{chunk-svrxk3vf.js → chunk-jbx3s7nw.js} +2 -2
  194. package/bundle/chunk-jcjbr3q7.js +2 -0
  195. package/bundle/{chunk-yyqrbv2f.js → chunk-jef04wyf.js} +1 -1
  196. package/bundle/{chunk-b1ntb3dh.js → chunk-jh0bw59r.js} +1 -1
  197. package/bundle/{chunk-b73s2h43.js → chunk-jrqb0jwy.js} +1 -1
  198. package/bundle/{chunk-3rt2k5sc.js → chunk-js1n8tgv.js} +1 -1
  199. package/bundle/chunk-jxswwvr3.js +2 -0
  200. package/bundle/{chunk-0626rvy2.js → chunk-kf167jw7.js} +1 -1
  201. package/bundle/{chunk-byc7ev8p.js → chunk-kfxv5rfg.js} +1 -1
  202. package/bundle/{chunk-d0qqgxs4.js → chunk-kj20f048.js} +1 -1
  203. package/bundle/{chunk-cd867geb.js → chunk-kq6b222y.js} +1 -1
  204. package/bundle/{chunk-6hmj972a.js → chunk-ktzq4ha1.js} +1 -1
  205. package/bundle/chunk-m5m448mg.js +3 -0
  206. package/bundle/{chunk-dfja6dj6.js → chunk-mcg24gkb.js} +1 -1
  207. package/bundle/chunk-mh0j6dzy.js +2 -0
  208. package/bundle/{chunk-p7h2qd7z.js → chunk-mk1bfzg5.js} +1 -1
  209. package/bundle/chunk-mxzceza9.js +2 -0
  210. package/bundle/{chunk-4vemws1t.js → chunk-mzs2pjyc.js} +2 -2
  211. package/bundle/chunk-n0dy98h2.js +2 -0
  212. package/bundle/{chunk-jwtev7b7.js → chunk-n9xns8by.js} +2 -2
  213. package/bundle/chunk-ngm6pqyt.js +2 -0
  214. package/bundle/chunk-ngtavamt.js +2 -0
  215. package/bundle/chunk-nkhc32s3.js +2 -0
  216. package/bundle/chunk-npse2xrd.js +2 -0
  217. package/bundle/{chunk-3vmh2ge6.js → chunk-nsk8dkwp.js} +1 -1
  218. package/bundle/{chunk-1fz0383p.js → chunk-nv3eyyaj.js} +1 -1
  219. package/bundle/{chunk-az9hsk6z.js → chunk-p18axz0m.js} +1 -1
  220. package/bundle/{chunk-2p9py4rw.js → chunk-p62gb4wj.js} +1 -1
  221. package/bundle/chunk-p6e4vqy7.js +2 -0
  222. package/bundle/{chunk-ktqrbbkh.js → chunk-p9qfbr02.js} +1 -1
  223. package/bundle/chunk-pctt1qv8.js +14 -0
  224. package/bundle/{chunk-gd45tjbd.js → chunk-pe29yy6s.js} +1 -1
  225. package/bundle/chunk-pf9g671w.js +2 -0
  226. package/bundle/chunk-phv9kdq6.js +3 -0
  227. package/bundle/{chunk-k095hd3c.js → chunk-pp2eqkse.js} +1 -1
  228. package/bundle/{chunk-gjvymdhp.js → chunk-pp6vhqrr.js} +1 -1
  229. package/bundle/chunk-ppjnqexm.js +2 -0
  230. package/bundle/chunk-pqkjhn8h.js +2 -0
  231. package/bundle/{chunk-yj73ehjd.js → chunk-pxvk3syj.js} +1 -1
  232. package/bundle/{chunk-tsb9g1nz.js → chunk-qbc36nbb.js} +2 -2
  233. package/bundle/{chunk-xhncwg5v.js → chunk-qc8rsn4v.js} +1 -1
  234. package/bundle/chunk-qd8w2gkd.js +2 -0
  235. package/bundle/{chunk-k16s2dnx.js → chunk-qrsveve6.js} +1 -1
  236. package/bundle/chunk-qvnb3j71.js +3 -0
  237. package/bundle/{chunk-q5363rr9.js → chunk-r4ndwym0.js} +1 -1
  238. package/bundle/chunk-r78czx4d.js +8 -0
  239. package/bundle/{chunk-cjfgs1x8.js → chunk-rbk8seme.js} +1 -1
  240. package/bundle/{chunk-n34y5gp6.js → chunk-redjxn13.js} +2 -2
  241. package/bundle/chunk-rf12t4n5.js +2 -0
  242. package/bundle/{chunk-fj7kd4gc.js → chunk-rg0mrprz.js} +1 -1
  243. package/bundle/{chunk-2xxefrps.js → chunk-rjd8gbs5.js} +1 -1
  244. package/bundle/chunk-rpgne7xh.js +2 -0
  245. package/bundle/chunk-rvgj1vky.js +2 -0
  246. package/bundle/{chunk-bx6kyvg7.js → chunk-rvkrgkeq.js} +1 -1
  247. package/bundle/{chunk-2hw0jzv4.js → chunk-rzhdkkpz.js} +1 -1
  248. package/bundle/{chunk-45jqjyk9.js → chunk-s9ntkjz3.js} +1 -1
  249. package/bundle/{chunk-81h5f8ev.js → chunk-skqbaadf.js} +1 -1
  250. package/bundle/chunk-ss2jvqrg.js +2 -0
  251. package/bundle/{chunk-61yatzp8.js → chunk-ss2ms1r3.js} +1 -1
  252. package/bundle/chunk-ssajqv72.js +2 -0
  253. package/bundle/{chunk-xn5v8wgh.js → chunk-t56r99hp.js} +1 -1
  254. package/bundle/{chunk-s1sepxdp.js → chunk-t8m74g39.js} +1 -1
  255. package/bundle/{chunk-s6bar2f9.js → chunk-t9mz17gb.js} +2 -2
  256. package/bundle/chunk-takew94z.js +9 -0
  257. package/bundle/{chunk-yp3dj4wh.js → chunk-tq0239xp.js} +1 -1
  258. package/bundle/{chunk-20d0cd1j.js → chunk-tqj69nh6.js} +2 -2
  259. package/bundle/{chunk-hpfqnjfz.js → chunk-tt30dybd.js} +1 -1
  260. package/bundle/{chunk-thk93j3e.js → chunk-tvdmnee6.js} +1 -1
  261. package/bundle/chunk-tvwwq4b3.js +2 -0
  262. package/bundle/{chunk-18vygvnc.js → chunk-v1xjc3s8.js} +1 -1
  263. package/bundle/chunk-v2n26eg4.js +2 -0
  264. package/bundle/chunk-vb286b31.js +2 -0
  265. package/bundle/chunk-vbeb74ny.js +11 -0
  266. package/bundle/chunk-vcw00k0n.js +3 -0
  267. package/bundle/{chunk-cfxjwfn4.js → chunk-vhe0tth1.js} +1 -1
  268. package/bundle/{chunk-z4nay2ef.js → chunk-vvxmwyrw.js} +1 -1
  269. package/bundle/{chunk-js9wdh67.js → chunk-vxyy2dp3.js} +2 -2
  270. package/bundle/{chunk-qk9vccja.js → chunk-vywnd5sf.js} +1 -1
  271. package/bundle/{chunk-gd5stg49.js → chunk-w18xs2h5.js} +1 -1
  272. package/bundle/{chunk-5n4hpc4f.js → chunk-wfb608qf.js} +3 -3
  273. package/bundle/chunk-x24y7qyd.js +2 -0
  274. package/bundle/{chunk-jkm54mha.js → chunk-x3y2xzhn.js} +1 -1
  275. package/bundle/{chunk-n3t52cz2.js → chunk-x4sp99g6.js} +1 -1
  276. package/bundle/{chunk-ef2b07fm.js → chunk-x562b0xk.js} +1 -1
  277. package/bundle/{chunk-zasd8cz8.js → chunk-x7k5yeey.js} +1 -1
  278. package/bundle/{chunk-v00cptj6.js → chunk-x9rbv6p6.js} +1 -1
  279. package/bundle/{chunk-m6wceqay.js → chunk-xcmgkc57.js} +1 -1
  280. package/bundle/{chunk-pycjksh4.js → chunk-xm7wascx.js} +1 -1
  281. package/bundle/{chunk-yaj9ywvz.js → chunk-xthkjax9.js} +1 -1
  282. package/bundle/{chunk-ps6jk326.js → chunk-xvwvd4kq.js} +2 -2
  283. package/bundle/{chunk-31wxbws4.js → chunk-xzrb857v.js} +1 -1
  284. package/bundle/chunk-y2d0w09y.js +2 -0
  285. package/bundle/{chunk-cev2qj7w.js → chunk-y3b4k38p.js} +1 -1
  286. package/bundle/{chunk-b9nwaaqs.js → chunk-y9q0hb7b.js} +2 -2
  287. package/bundle/chunk-yb79f79m.js +2 -0
  288. package/bundle/{chunk-8d2ddmf0.js → chunk-yek0sk2q.js} +1 -1
  289. package/bundle/{chunk-9atkgkaq.js → chunk-yhbcbjfk.js} +1 -1
  290. package/bundle/{chunk-k20nrwbg.js → chunk-yjf3kyej.js} +1 -1
  291. package/bundle/chunk-yjnyzpmt.js +2 -0
  292. package/bundle/{chunk-0a0vat1h.js → chunk-yp5bypsp.js} +2 -2
  293. package/bundle/{chunk-89f8v2y8.js → chunk-yp8wyzzm.js} +1 -1
  294. package/bundle/chunk-yqbcnsa1.js +2 -0
  295. package/bundle/{chunk-qtsmgjk7.js → chunk-yv0xrnn9.js} +1 -1
  296. package/bundle/chunk-z3mra3nm.js +2 -0
  297. package/bundle/{chunk-7m8fdp5p.js → chunk-z6pwkwdr.js} +1 -1
  298. package/bundle/{chunk-t299e2aw.js → chunk-zs8kqdsf.js} +2 -2
  299. package/bundle/{chunk-6saj1dhz.js → chunk-zscer8rc.js} +1 -1
  300. package/bundle/{chunk-4mrz9b6d.js → chunk-zw815d68.js} +2 -2
  301. package/bundle/chunk-zy9w1vkc.js +2 -0
  302. package/bundle/index.js +3 -3
  303. package/bundle/parser.worker.js +2 -2
  304. package/bundle/worker.js +1 -1
  305. package/package.json +1 -1
  306. package/bundle/chunk-07c1mvy1.js +0 -2
  307. package/bundle/chunk-0p7qcm51.js +0 -2
  308. package/bundle/chunk-0pmb7zzh.js +0 -2
  309. package/bundle/chunk-0xm85ayc.js +0 -3
  310. package/bundle/chunk-11d987sj.js +0 -11
  311. package/bundle/chunk-19sa03c1.js +0 -3
  312. package/bundle/chunk-1s9ctg0d.js +0 -2
  313. package/bundle/chunk-2f9fn9xr.js +0 -2
  314. package/bundle/chunk-2fhcvfyg.js +0 -2
  315. package/bundle/chunk-2ztdqtnk.js +0 -3
  316. package/bundle/chunk-3mfj0x4p.js +0 -2
  317. package/bundle/chunk-3shnje9k.js +0 -2
  318. package/bundle/chunk-3tz1qhpt.js +0 -2
  319. package/bundle/chunk-4dtbdycg.js +0 -2
  320. package/bundle/chunk-4kpvceap.js +0 -2
  321. package/bundle/chunk-4pz8av2y.js +0 -2
  322. package/bundle/chunk-4r4xh8a6.js +0 -2
  323. package/bundle/chunk-5hpq59t1.js +0 -2
  324. package/bundle/chunk-5s90ehww.js +0 -2
  325. package/bundle/chunk-5z7mjwwa.js +0 -14
  326. package/bundle/chunk-63kcg127.js +0 -2
  327. package/bundle/chunk-6fejrpht.js +0 -2
  328. package/bundle/chunk-6zzdw7q1.js +0 -2
  329. package/bundle/chunk-71pmrpkc.js +0 -2
  330. package/bundle/chunk-78m8rayq.js +0 -2
  331. package/bundle/chunk-7j6p5j2g.js +0 -2
  332. package/bundle/chunk-7tjd6ba1.js +0 -2
  333. package/bundle/chunk-8d8efdry.js +0 -2
  334. package/bundle/chunk-8jzjvmaz.js +0 -2
  335. package/bundle/chunk-93jxndr8.js +0 -2
  336. package/bundle/chunk-94qmhz2p.js +0 -3
  337. package/bundle/chunk-95qs7wnz.js +0 -2
  338. package/bundle/chunk-97h0jx8y.js +0 -5
  339. package/bundle/chunk-99ve54r6.js +0 -2
  340. package/bundle/chunk-9ksaqyb2.js +0 -2
  341. package/bundle/chunk-9p7t748e.js +0 -2
  342. package/bundle/chunk-a69jgepp.js +0 -2
  343. package/bundle/chunk-a94s0jks.js +0 -2
  344. package/bundle/chunk-ar310tc3.js +0 -2
  345. package/bundle/chunk-at03h9eq.js +0 -2
  346. package/bundle/chunk-ay9p70xx.js +0 -2
  347. package/bundle/chunk-b6dsv601.js +0 -3
  348. package/bundle/chunk-bajtytm5.js +0 -2
  349. package/bundle/chunk-bh8v3mfg.js +0 -2
  350. package/bundle/chunk-bp8sxnrm.js +0 -2
  351. package/bundle/chunk-bw5e8thn.js +0 -2
  352. package/bundle/chunk-c8ajbhv3.js +0 -2
  353. package/bundle/chunk-c8n72r2k.js +0 -8
  354. package/bundle/chunk-ccddzk10.js +0 -2
  355. package/bundle/chunk-ch8cx9jn.js +0 -2
  356. package/bundle/chunk-cm4jtnkg.js +0 -2
  357. package/bundle/chunk-cq7j5tv5.js +0 -2
  358. package/bundle/chunk-cttqh20d.js +0 -2
  359. package/bundle/chunk-cvvfa1jf.js +0 -2
  360. package/bundle/chunk-d7t0bcvk.js +0 -800
  361. package/bundle/chunk-dd3m74rc.js +0 -3
  362. package/bundle/chunk-e3qtndrt.js +0 -2
  363. package/bundle/chunk-e8cac405.js +0 -2
  364. package/bundle/chunk-ez92ah9y.js +0 -2
  365. package/bundle/chunk-fazvedgy.js +0 -2
  366. package/bundle/chunk-gf5pwww1.js +0 -2
  367. package/bundle/chunk-gtzcm5sb.js +0 -2
  368. package/bundle/chunk-j0znryc6.js +0 -9
  369. package/bundle/chunk-kzrw6h8t.js +0 -2
  370. package/bundle/chunk-ma0m6kpj.js +0 -2
  371. package/bundle/chunk-mjrvj2cg.js +0 -2
  372. package/bundle/chunk-mpebdv59.js +0 -2
  373. package/bundle/chunk-n20v44zr.js +0 -2
  374. package/bundle/chunk-nfzmvy30.js +0 -2
  375. package/bundle/chunk-nksathh4.js +0 -2
  376. package/bundle/chunk-p5360c2q.js +0 -2
  377. package/bundle/chunk-q14890p6.js +0 -2
  378. package/bundle/chunk-q4n02cwv.js +0 -2
  379. package/bundle/chunk-q7s17j1b.js +0 -2
  380. package/bundle/chunk-qm07wesh.js +0 -2
  381. package/bundle/chunk-qrrg9v3d.js +0 -2
  382. package/bundle/chunk-rdqgss38.js +0 -2
  383. package/bundle/chunk-rf524gez.js +0 -3
  384. package/bundle/chunk-rqgcz2zr.js +0 -2
  385. package/bundle/chunk-rs1698xs.js +0 -3
  386. package/bundle/chunk-rzc528ym.js +0 -2
  387. package/bundle/chunk-s2za1n7h.js +0 -8
  388. package/bundle/chunk-sbv96mj0.js +0 -3
  389. package/bundle/chunk-t3q7qakr.js +0 -2
  390. package/bundle/chunk-th78zcds.js +0 -2
  391. package/bundle/chunk-tj00kzk4.js +0 -2
  392. package/bundle/chunk-tv26mwx5.js +0 -2
  393. package/bundle/chunk-v69n6mef.js +0 -2
  394. package/bundle/chunk-vegwb3t0.js +0 -2
  395. package/bundle/chunk-w9seyn69.js +0 -2
  396. package/bundle/chunk-wanf4se3.js +0 -2
  397. package/bundle/chunk-wdhzmk1b.js +0 -2
  398. package/bundle/chunk-wnwesaap.js +0 -2
  399. package/bundle/chunk-wxqtda70.js +0 -2
  400. package/bundle/chunk-wzb6s9rk.js +0 -2
  401. package/bundle/chunk-x0dg9rg6.js +0 -2
  402. package/bundle/chunk-xmnzrzbs.js +0 -2
  403. package/bundle/chunk-xzf62kc6.js +0 -2
  404. package/bundle/chunk-yk8kk25c.js +0 -3
  405. package/bundle/chunk-yned6vmd.js +0 -3
  406. package/bundle/chunk-yra49yga.js +0 -2
  407. package/bundle/chunk-ytye0p7f.js +0 -2
  408. package/bundle/chunk-yv2mxxbq.js +0 -2
  409. package/bundle/chunk-z2fqqer0.js +0 -2
  410. package/bundle/chunk-z3qanc8m.js +0 -2
  411. package/bundle/chunk-z44m19vm.js +0 -2
  412. package/bundle/chunk-zcagdtab.js +0 -2
  413. package/bundle/chunk-zervk6c5.js +0 -2
  414. package/bundle/chunk-zqjp7jdd.js +0 -7
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{mq as a}from"./chunk-1d9f53sk.js";import"./chunk-yjj4cvqg.js";export default a();
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Fo as a,Go as b,Ho as c,Io as d,Jo as e,Ko as f,Lo as g,Mo as h,No as i}from"./chunk-bsf6n350.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-1d9f53sk.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yjj4cvqg.js";export{i as gateway,h as createGatewayProvider,h as createGateway,g as GatewayResponseError,d as GatewayRateLimitError,e as GatewayModelNotFoundError,c as GatewayInvalidRequestError,f as GatewayInternalServerError,a as GatewayError,b as GatewayAuthenticationError};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{GO as t}from"./chunk-yjj4cvqg.js";var e=await import("./chunk-qrrg9v3d.js",{with:{type:"file"}}),a=e.default;export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Cd as H,Dd as I}from"./chunk-45jqjyk9.js";import{Rd as G}from"./chunk-yajd975f.js";import{Of as B}from"./chunk-v9xnk9pz.js";import{ag as E}from"./chunk-5z7mjwwa.js";import"./chunk-z29fwg61.js";import"./chunk-b9hstp7h.js";import"./chunk-j0znryc6.js";import"./chunk-sbv96mj0.js";import"./chunk-nfg7nt13.js";import"./chunk-ps6jk326.js";import"./chunk-tsb9g1nz.js";import"./chunk-m2ny1en7.js";import"./chunk-09j71kp6.js";import"./chunk-js9wdh67.js";import"./chunk-0a0vat1h.js";import"./chunk-z8v2tsz2.js";import"./chunk-j8efst22.js";import"./chunk-8f0g7d7k.js";import"./chunk-abtn6nec.js";import"./chunk-d7t0bcvk.js";import"./chunk-7mc8nxve.js";import"./chunk-dfja6dj6.js";import"./chunk-n34y5gp6.js";import"./chunk-bn0h9dny.js";import"./chunk-q5363rr9.js";import"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import{po as D}from"./chunk-s2za1n7h.js";import"./chunk-19sa03c1.js";import"./chunk-csdm3n24.js";import"./chunk-xk1nh1ay.js";import"./chunk-bsf6n350.js";import"./chunk-4vze3djr.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-1d9f53sk.js";import"./chunk-svrxk3vf.js";import"./chunk-kkae8ead.js";import"./chunk-s6me101a.js";import"./chunk-jwtev7b7.js";import"./chunk-b9nwaaqs.js";import"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-fsy279s5.js";import"./chunk-hn1f6rne.js";import"./chunk-4kpvceap.js";import{Ss as f}from"./chunk-94qmhz2p.js";import"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-bv8pf0m1.js";import"./chunk-4mrz9b6d.js";import"./chunk-yjj4cvqg.js";var T=G({command:"serve",builder:(b)=>B(b).option("auto-password",{type:"boolean",default:!1,describe:"generate a random ephemeral QITQODE_SERVER_PASSWORD for this run and print it"}),describe:"starts a headless qitqode server",handler:async(b)=>{let A=await H(b);if(b["auto-password"]&&!f.QITQODE_SERVER_PASSWORD){let z=crypto.randomUUID();process.env.QITQODE_SERVER_PASSWORD=z,console.log('Generated ephemeral server password (basic auth, username "qitqode"):'),console.log(` ${z}`)}if(I(A,f.QITQODE_SERVER_PASSWORD))console.error("ERROR: Binding to non-loopback address without QITQODE_SERVER_PASSWORD is not allowed."),console.error("Set QITQODE_SERVER_PASSWORD, pass --auto-password, or pass --no-auth to override (DANGEROUS)."),process.exit(1);if(!f.QITQODE_SERVER_PASSWORD)console.error(""),console.error("\u2554\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2557"),console.error("\u2551 WARNING: server is running WITHOUT authentication. \u2551"),console.error("\u2551 \u2551"),console.error("\u2551 Any process or browser page that can reach this address can read \u2551"),console.error("\u2551 project files, run shell commands, and open terminals as you. \u2551"),console.error("\u2551 \u2551"),console.error("\u2551 Set QITQODE_SERVER_PASSWORD, or restart with --auto-password to \u2551"),console.error("\u2551 generate an ephemeral password for this run. \u2551"),console.error("\u255A\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u255D"),console.error("");if(process.env.QITQODE_KEY)console.log("Using QITQODE_KEY for authentication.");else if(!await D())console.error("Warning: no QitQode credential found. AI features will not work until you sign in (`qitqode auth login`) or set QITQODE_KEY.");let j=await E.listen(A);console.log(`qitqode server listening on http://${j.hostname}:${j.port}`),await new Promise(()=>{}),await j.stop()}});export{T as ServeCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-yjj4cvqg.js";var e="./libopentui-xtk56e94.so";export{e as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Id as q,Jd as K,Kd as D,Nd as L,Od as N}from"./chunk-2p9py4rw.js";import"./chunk-n3t52cz2.js";import{Vf as B}from"./chunk-cjfgs1x8.js";import{hh as G}from"./chunk-m2ny1en7.js";import"./chunk-09j71kp6.js";import"./chunk-js9wdh67.js";import"./chunk-0a0vat1h.js";import"./chunk-z8v2tsz2.js";import"./chunk-j8efst22.js";import"./chunk-8f0g7d7k.js";import"./chunk-abtn6nec.js";import"./chunk-d7t0bcvk.js";import{Fl as C}from"./chunk-7mc8nxve.js";import"./chunk-dfja6dj6.js";import"./chunk-n34y5gp6.js";import"./chunk-bn0h9dny.js";import"./chunk-q5363rr9.js";import"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import"./chunk-s2za1n7h.js";import"./chunk-19sa03c1.js";import"./chunk-csdm3n24.js";import"./chunk-xk1nh1ay.js";import"./chunk-bsf6n350.js";import"./chunk-4vze3djr.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-1d9f53sk.js";import"./chunk-svrxk3vf.js";import"./chunk-kkae8ead.js";import"./chunk-s6me101a.js";import"./chunk-jwtev7b7.js";import"./chunk-b9nwaaqs.js";import"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-fsy279s5.js";import"./chunk-hn1f6rne.js";import"./chunk-4kpvceap.js";import{Wr as J}from"./chunk-94qmhz2p.js";import"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-bv8pf0m1.js";import"./chunk-4mrz9b6d.js";import"./chunk-yjj4cvqg.js";var X={command:"upgrade [target]",describe:"upgrade qitqode to the latest or a specific version",builder:(z)=>{return z.positional("target",{describe:"version to upgrade to, for ex '0.1.48' or 'v0.1.48'",type:"string"}).option("method",{alias:"m",describe:"installation method to use",type:"string",choices:["curl","npm","pnpm","bun","brew","choco","scoop"]})},handler:async(z)=>{B.empty(),B.println(B.logo(" ")),B.empty(),K("Upgrade");let O=await G.runPromise(C.Service.use((j)=>j.method())),E=z.method??O;if(E==="unknown"){if(q.error(`qitqode is installed to ${process.execPath} and may be managed by a package manager`),!await N({message:"Install anyways?",options:[{label:"Yes",value:!0},{label:"No",value:!1}],initialValue:!1})){D("Done");return}}q.info("Using method: "+E);let F=z.target?z.target.replace(/^v/,""):await G.runPromise(C.Service.use((j)=>j.latest()));if(J===F){q.warn(`qitqode upgrade skipped: ${F} is already installed`),D("Done");return}q.info(`From ${J} \u2192 ${F}`);let H=L();H.start("Upgrading...");let x=await G.runPromise(C.Service.use((j)=>j.upgrade(E,F))).catch((j)=>j);if(x){if(H.stop("Upgrade failed",1),x instanceof C.UpgradeFailedError)if(E==="choco"&&x.stderr.includes("not running from an elevated command shell"))q.error("Please run the terminal as Administrator and try again");else q.error(x.stderr);else if(x instanceof Error)q.error(x.message);D("Done");return}H.stop("Upgrade complete"),D("Done")}};export{X as UpgradeCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{A as g,u as a,v as b,w as c,x as d,y as e,z as f}from"./chunk-r4mnbhe1.js";import"./chunk-q5363rr9.js";import"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import"./chunk-19sa03c1.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-hn1f6rne.js";import"./chunk-94qmhz2p.js";import"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-yjj4cvqg.js";export{e as waitForDependencies,c as layer,f as get,d as defaultLayer,g as TuiConfig,b as Service,a as Info};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-yjj4cvqg.js";var r="./highlights-eq9cgrbb.scm";export{r as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Ed as j}from"./chunk-sbx9z70j.js";import{Rd as Q}from"./chunk-yajd975f.js";import{Vf as M}from"./chunk-cjfgs1x8.js";import{og as N}from"./chunk-z29fwg61.js";import{hh as $}from"./chunk-m2ny1en7.js";import"./chunk-09j71kp6.js";import"./chunk-js9wdh67.js";import"./chunk-0a0vat1h.js";import"./chunk-z8v2tsz2.js";import"./chunk-j8efst22.js";import"./chunk-8f0g7d7k.js";import"./chunk-abtn6nec.js";import{Cl as X,kk as J}from"./chunk-d7t0bcvk.js";import"./chunk-7mc8nxve.js";import"./chunk-dfja6dj6.js";import"./chunk-n34y5gp6.js";import"./chunk-bn0h9dny.js";import"./chunk-q5363rr9.js";import"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import"./chunk-s2za1n7h.js";import"./chunk-19sa03c1.js";import"./chunk-csdm3n24.js";import{Eo as _}from"./chunk-xk1nh1ay.js";import"./chunk-bsf6n350.js";import"./chunk-4vze3djr.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-1d9f53sk.js";import"./chunk-svrxk3vf.js";import"./chunk-kkae8ead.js";import"./chunk-s6me101a.js";import"./chunk-jwtev7b7.js";import"./chunk-b9nwaaqs.js";import"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-fsy279s5.js";import"./chunk-hn1f6rne.js";import"./chunk-4kpvceap.js";import{Is as Y,Ss as Z}from"./chunk-94qmhz2p.js";import{it as E,tt as V}from"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-bv8pf0m1.js";import"./chunk-4mrz9b6d.js";import"./chunk-yjj4cvqg.js";import{EOL as L}from"os";import k from"path";function P(){let q=["-R","-S"];if(process.platform!=="win32")return["less",...q];let z=_("less");if(z){if(V.stat(z)?.size)return[z,...q]}if(Z.QITQODE_GIT_BASH_PATH){let G=k.join(Z.QITQODE_GIT_BASH_PATH,"..","..","usr","bin","less.exe");if(V.stat(G)?.size)return[G,...q]}let B=_("git");if(B){let G=k.join(B,"..","..","usr","bin","less.exe");if(V.stat(G)?.size)return[G,...q]}return["cmd","/c","more"]}var g=Q({command:"session",describe:"manage sessions",builder:(q)=>q.command(T).command(D).command(v).demandCommand(),async handler(){}}),v=Q({command:"import-claude",describe:"import Claude Code sessions (~/.claude/projects) into qitqode",builder:(q)=>q.option("force",{describe:"re-sync every session, ignoring the mtime cache",type:"boolean",default:!1}),handler:async(q)=>{let z=await N.run({force:q.force});M.println(`Claude import: scanned ${z.scanned}, imported ${z.imported}, resynced ${z.resynced}, skipped ${z.skipped}`+(z.errors.length?`, errors ${z.errors.length}`:""));for(let B of z.errors)M.error(B)}}),D=Q({command:"delete <sessionID>",describe:"delete a session",builder:(q)=>{return q.positional("sessionID",{describe:"session ID to delete",type:"string",demandOption:!0})},handler:async(q)=>{await j(process.cwd(),async()=>{let z=J.make(q.sessionID);try{await $.runPromise(X.Service.use((B)=>B.get(z)))}catch{M.error(`Session not found: ${q.sessionID}`),process.exit(1)}await $.runPromise(X.Service.use((B)=>B.remove(z))),M.println(M.Style.TEXT_SUCCESS_BOLD+`Session ${q.sessionID} deleted`+M.Style.TEXT_NORMAL)})}}),T=Q({command:"list",describe:"list sessions",builder:(q)=>{return q.option("max-count",{alias:"n",describe:"limit to N most recent sessions",type:"number"}).option("format",{describe:"output format",type:"string",choices:["table","json"],default:"table"})},handler:async(q)=>{await j(process.cwd(),async()=>{let z=[...X.list({roots:!0,limit:q.maxCount})];if(z.length===0)return;let B;if(q.format==="json")B=f(z);else B=b(z);if(process.stdout.isTTY&&!q.maxCount&&q.format==="table"){let H=E.spawn(P(),{stdin:"pipe",stdout:"inherit",stderr:"inherit"});if(!H.stdin){console.log(B);return}H.stdin.write(B),H.stdin.end(),await H.exited}else console.log(B)})}});function b(q){let z=[],B=Math.max(20,...q.map((K)=>K.id.length)),G=Math.max(25,...q.map((K)=>K.title.length)),H=`Session ID${" ".repeat(B-10)} Title${" ".repeat(G-5)} Updated`;z.push(H),z.push("\u2500".repeat(H.length));for(let K of q){let A=Y.truncate(K.title,G),R=Y.todayTimeOrDateTime(K.time.updated),w=`${K.id.padEnd(B)} ${A.padEnd(G)} ${R}`;z.push(w)}return z.join(L)}function f(q){let z=q.map((B)=>({id:B.id,title:B.title,updated:B.time.updated,created:B.time.created,projectId:B.projectID,directory:B.directory}));return JSON.stringify(z,null,2)}export{T as SessionListCommand,v as SessionImportClaudeCommand,D as SessionDeleteCommand,g as SessionCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-yjj4cvqg.js";function n(){return(e)=>JSON.parse(JSON.stringify(e.Type()))}export{n as default};
@@ -1,3 +0,0 @@
1
- // @bun
2
- import{gt as L,tt as Y}from"./chunk-20d0cd1j.js";import{vt as Hr}from"./chunk-b6dsv601.js";import{AC as rr,PE as ar,jE as go,mO as k,qH as W}from"./chunk-t299e2aw.js";import{EO as J,HO as ho,IO as vo}from"./chunk-yjj4cvqg.js";var Po={};J(Po,{validateArchiveMetadata:()=>Uo,validateArchiveEntries:()=>Ko,replaceDirectoryAtomically:()=>Xo,extractZip:()=>Pr,assertArchiveDestinationSafe:()=>no});import I from"path";import Q from"fs/promises";function Ko(o,r){let a=I.resolve(r);for(let m of o){let n=m.trim().replaceAll("\\","/");if(!n)continue;if(n.includes("\x00")||I.posix.isAbsolute(n)||/^[a-z]:\//i.test(n))throw Error(`Unsafe archive entry: ${m}`);if(n.split("/").includes(".."))throw Error(`Unsafe archive entry: ${m}`);let f=I.resolve(a,...n.split("/"));if(f!==a&&!f.startsWith(`${a}${I.sep}`))throw Error(`Unsafe archive entry: ${m}`)}}function Uo(o){for(let r of o.split(/\r?\n/))if(/^[bclps]/.test(r))throw Error("Archive contains an unsafe special entry")}async function Yo(o){let r=await Q.readdir(o,{withFileTypes:!0});await Promise.all(r.map(async(a)=>{let m=I.join(o,a.name);if(a.isSymbolicLink())throw Error(`Archive contains a symbolic link: ${a.name}`);if(a.isDirectory())await Yo(m)}))}async function qo(o){return Q.lstat(o).catch((r)=>{if(r.code==="ENOENT")return;throw r})}async function no(o){let r=I.resolve(o),a=I.parse(r),m=a.root;for(let n of r.slice(a.root.length).split(I.sep).filter(Boolean)){m=I.join(m,n);let f=await qo(m);if(!f)return;if(f.isSymbolicLink())throw Error(`Archive destination contains a symbolic link: ${m}`)}}async function Xo(o,r){let a=I.resolve(r);await no(a);let m=await qo(a);if(m&&!m.isDirectory())throw Error("Archive destination must be a directory");let n=I.join(I.dirname(a),`.qitqode-backup-${crypto.randomUUID()}`);if(m)await Q.rename(a,n);try{await Q.rename(o,a)}catch(f){if(m)await Q.rename(n,a);throw f}if(m)await Q.rm(n,{recursive:!0,force:!0})}async function Pr(o,r){let a=I.resolve(o),m=I.resolve(r),n=await L(process.platform==="win32"?["tar","-tf",a]:["unzip","-Z1",a]);Ko(n.stdout.toString().split(/\r?\n/),m);let f=await L(process.platform==="win32"?["tar","-tvf",a]:["unzip","-Z","-l",a]);Uo(f.stdout.toString()),await no(I.dirname(m)),await Q.mkdir(I.dirname(m),{recursive:!0}),await no(I.dirname(m));let s=await Q.mkdtemp(I.join(I.dirname(m),".qitqode-extract-"));try{if(process.platform==="win32"){let t=a.replace(/'/g,"''"),x=s.replace(/'/g,"''"),N=`$global:ProgressPreference = 'SilentlyContinue'; Expand-Archive -Path '${t}' -DestinationPath '${x}' -Force`;await L(["powershell","-NoProfile","-NonInteractive","-Command",N])}else await L(["unzip","-o","-q",a,"-d",s]);await Yo(s),await Xo(s,m)}finally{await Q.rm(s,{recursive:!0,force:!0})}}var Eo={};J(Eo,{isValidHex:()=>Ao,hexToRgb:()=>Zo,hexToAnsiBold:()=>Ar});function Ao(o){if(!o)return!1;return/^#[0-9a-fA-F]{6}$/.test(o)}function Zo(o){let r=parseInt(o.slice(1,3),16),a=parseInt(o.slice(3,5),16),m=parseInt(o.slice(5,7),16);return{r,g:a,b:m}}function Ar(o){if(!Ao(o))return;let{r,g:a,b:m}=Zo(o);return`\x1B[38;2;${r};${a};${m}m\x1B[1m`}var Lo={};J(Lo,{awaitDeferred:()=>Zr});function Zr(o,r){return W.ensuring(go.await(o),W.sync(r))}import V from"os";var z={};J(z,{Path:()=>H,Global:()=>z});import U from"fs/promises";import uo from"path";import aa from"os";import fo from"path";import dr from"os";import{randomBytes as gr,randomUUID as Lr}from"crypto";import{mkdir as so,readFile as er,rm as E,stat as Dr,utimes as hr,writeFile as eo}from"fs/promises";import{createHash as Er}from"crypto";var bo;((ym)=>{function o(r){return Er("sha1").update(r).digest("hex")}ym.fast=o})(bo||={});var to;((Do)=>{let o;function r(u){o=u}Do.setGlobal=r;let a=()=>{if(!o)throw Error("Flock global not set");return fo.join(o.state,"locks")},m={staleMs:60000,timeoutMs:300000,baseDelayMs:100,maxDelayMs:2000};function n(u){if(typeof u!=="object"||u===null||!("code"in u))return;let i=u.code;if(typeof i!=="string")return;return i}function f(u,i){return new Promise((c,M)=>{if(i?.aborted){M(i.reason??Error("Aborted"));return}let R,b=()=>{i?.removeEventListener("abort",j),c()},j=()=>{if(R)clearTimeout(R);i?.removeEventListener("abort",j),M(i?.reason??Error("Aborted"))};if(i?.addEventListener("abort",j,{once:!0}),R=setTimeout(b,u),i?.aborted)j()})}function s(u){let i=Math.floor(u*0.3),c=Math.floor(Math.random()*(2*i+1))-i;return Math.max(0,u+c)}function t(){return performance.now()}function x(){return performance.timeOrigin+t()}async function N(u){try{return await Dr(u)}catch(i){let c=n(i);if(c==="ENOENT"||c==="ENOTDIR")return;throw i}}async function T(u,i,c,M){let R=x(),b=await N(i);if(b)return R-b.mtimeMs>M;let j=await N(c);if(j)return R-j.mtimeMs>M;let C=await N(u);if(!C)return!1;return R-C.mtimeMs>M}async function P(u,i){let c=Lr?.()??gr(16).toString("hex"),M=fo.join(u,"meta.json"),R=fo.join(u,"heartbeat");try{await so(u,{mode:448})}catch(g){if(n(g)!=="EEXIST")throw g;if(!await T(u,R,M,i.staleMs))return{acquired:!1};let S=u+".breaker";try{await so(S,{mode:448})}catch(B){let Z=n(B);if(Z==="EEXIST"){let Fo=await N(S);if(Fo&&x()-Fo.mtimeMs>i.staleMs)await E(S,{recursive:!0,force:!0}).catch(()=>{return});return{acquired:!1}}if(Z==="ENOENT"||Z==="ENOTDIR")return{acquired:!1};throw B}try{if(!await T(u,R,M,i.staleMs))return{acquired:!1};await E(u,{recursive:!0,force:!0});try{await so(u,{mode:448})}catch(B){let Z=n(B);if(Z==="EEXIST"||Z==="ENOTEMPTY")return{acquired:!1};throw B}}finally{await E(S,{recursive:!0,force:!0}).catch(()=>{return})}}let b={token:c,pid:process.pid,hostname:dr.hostname(),createdAt:new Date().toISOString()};await eo(R,"",{flag:"wx"}).catch(async()=>{throw await E(u,{recursive:!0,force:!0}),Error("Lock acquired but heartbeat already existed (possible compromise).")}),await eo(M,JSON.stringify(b,null,2),{flag:"wx"}).catch(async()=>{throw await E(u,{recursive:!0,force:!0}),Error("Lock acquired but meta.json already existed (possible compromise).")});let j;return{acquired:!0,startHeartbeat:(g=Math.max(100,Math.floor(i.staleMs/3)))=>{if(j)return;j=setInterval(()=>{let S=new Date;hr(R,S,S).catch(()=>{return})},g),j.unref?.()},release:async()=>{if(j)clearInterval(j),j=void 0;if((await er(M,"utf8").then((S)=>{let B=JSON.parse(S);if(!B||typeof B!=="object")return{};return{token:"token"in B&&typeof B.token==="string"?B.token:void 0}}).catch((S)=>{let B=n(S);if(B==="ENOENT"||B==="ENOTDIR")throw Error("Refusing to release: lock is compromised (metadata missing).");if(S instanceof SyntaxError)throw Error("Refusing to release: lock is compromised (metadata invalid).");throw S})).token!==c)throw Error("Refusing to release: lock token mismatch (not the owner).");await E(u,{recursive:!0,force:!0})}}}async function mo(u,i,c){let M=t()+c.timeoutMs,R=0,b=0,j=c.baseDelayMs;while(!0){i.signal?.throwIfAborted();let C=await P(u,c);if(C.acquired)return C;if(t()>M)throw Error(`Timed out waiting for lock: ${i.key}`);R+=1;let A=s(j);await i.onWait?.({key:i.key,attempt:R,delay:A,waited:b}),await f(A,i.signal),b+=A,j=Math.min(c.maxDelayMs,Math.floor(j*1.7))}}async function qr(u,i={}){i.signal?.throwIfAborted();let c={staleMs:i.staleMs??m.staleMs,timeoutMs:i.timeoutMs??m.timeoutMs,baseDelayMs:i.baseDelayMs??m.baseDelayMs,maxDelayMs:i.maxDelayMs??m.maxDelayMs},M=i.dir??a();await so(M,{recursive:!0});let R=fo.join(M,bo.fast(u)+".lock"),b=await mo(R,{key:u,onWait:i.onWait,signal:i.signal},c);b.startHeartbeat();let j,C=()=>{return j??=b.release()};return{release:C,[Symbol.asyncDispose](){return C()}}}Do.acquire=qr;async function Cm(u,i,c={}){let R=[];try{const M=ho(R,await qr(u,c),1);c.signal?.throwIfAborted();return await i()}catch(b){var j=b,C=1}finally{var A=vo(R,j,C);A&&await A}}Do.withLock=Cm,Do.effect=W.fn("Flock.effect")(function*(u,i={}){return yield*W.acquireRelease(W.promise((c)=>to.acquire(u,{...i,signal:c})).pipe(W.withSpan("Flock.acquire",{attributes:{key:u}})),(c)=>W.promise(()=>c.release()).pipe(W.withSpan("Flock.release"))).pipe(W.asVoid)})})(to||={});import w from"path";import vr from"os";import po from"path";var G=vr.homedir(),{env:K}=process,e=K.XDG_DATA_HOME||(G?po.join(G,".local","share"):void 0),io=K.XDG_CONFIG_HOME||(G?po.join(G,".config"):void 0),lo=K.XDG_STATE_HOME||(G?po.join(G,".local","state"):void 0),ko=K.XDG_CACHE_HOME||(G?po.join(G,".cache"):void 0),gm=K.XDG_RUNTIME_DIR||void 0,lr=(K.XDG_DATA_DIRS||"/usr/local/share/:/usr/share/").split(":");if(e)lr.unshift(e);var kr=(K.XDG_CONFIG_DIRS||"/etc/xdg").split(":");if(io)kr.unshift(io);import oa from"os";var D="qitqode";function Bo(o=process.env){let r=o.QITQODE_HOME;if(r){if(!w.isAbsolute(r))throw Error(`QITQODE_HOME must be an absolute path, got: ${JSON.stringify(r)}`);return{mode:"qitqode_home",root:r,data:w.join(r,"data"),cache:w.join(r,"cache"),config:w.join(r,"config"),state:w.join(r,"state")}}return{mode:"xdg",data:w.join(e,D),cache:w.join(ko,D),config:w.join(io,D),state:w.join(lo,D)}}function So(o=process.env){let r=o.QITQODE_LOG_DIR;if(r){if(!w.isAbsolute(r))throw Error(`QITQODE_LOG_DIR must be an absolute path, got: ${JSON.stringify(r)}`);return r}return w.join(e,D,"log")}var ra;((or)=>{class o extends rr.Service()("@qitqode/Global"){}or.Service=o,or.layer=ar.effect(o,W.gen(function*(){let a=process.env.HOME||process.env.USERPROFILE||oa.homedir(),{data:m,cache:n,config:f,state:s}=yield*W.sync(()=>Bo()),t=w.join(n,"bin"),x=yield*W.sync(()=>So());return o.of({home:a,data:m,cache:n,config:f,state:s,bin:t,log:x})}))})(ra||={});var{data:ma,cache:mr,config:na,state:fr}=Bo(),H={get home(){return process.env.HOME||process.env.USERPROFILE||aa.homedir()},data:ma,bin:uo.join(mr,"bin"),log:So(),cache:mr,config:na,state:fr};to.setGlobal({state:fr});await Promise.all([U.mkdir(H.data,{recursive:!0}),U.mkdir(H.config,{recursive:!0}),U.mkdir(H.state,{recursive:!0}),U.mkdir(H.log,{recursive:!0}),U.mkdir(H.bin,{recursive:!0})]);var nr="21",fa=await Y.readText(uo.join(H.cache,"version")).catch(()=>"0");if(fa!==nr){try{let o=await U.readdir(H.cache);await Promise.all(o.map((r)=>U.rm(uo.join(H.cache,r),{recursive:!0,force:!0})))}catch{}await Y.write(uo.join(H.cache,"version"),nr)}var sr="0.1.29",tr="latest",fn="f82ff893cea7bb0d5f0202bad2af4ff3cb252bb2",sn=!1;import sa from"path";var q;async function ir(){if(q)return q;let o=sa.join(z.Path.data,"installation_id"),r=await Y.readText(o).catch(()=>{return});if(r&&r.trim())return q=r.trim(),q;return q=crypto.randomUUID(),await Y.write(o,q),q}var pr="QITQODE_RUN_ID",ur="QITQODE_PROCESS_ROLE";function ta(){return process.env.QITQODE_RUN_ID??=crypto.randomUUID()}function ia(o){return process.env.QITQODE_PROCESS_ROLE??=o}function On(o){return{runID:ta(),processRole:ia(o)}}function Nn(o){let r=Object.fromEntries(Object.entries(process.env).filter((a)=>a[1]!==void 0));return o?Object.assign(r,o):r}function pa(){if(process.env.USER)return process.env.USER;if(process.env.USERNAME)return process.env.USERNAME;return V.userInfo().username}function ua(){return Intl.DateTimeFormat().resolvedOptions().locale}function xa(){return Intl.DateTimeFormat().resolvedOptions().timeZone}async function ca(){let o=V.cpus();return{os:{platform:V.platform(),arch:V.arch(),release:V.release(),hostname:V.hostname()},cpu:{model:o[0]?.model??"unknown",count:o.length},memory:{total_bytes:V.totalmem()},user:{username:pa(),homedir:V.homedir()},runtime:{bun_version:Bun.version,node_version:process.versions.node,pid:process.pid,timezone:xa(),locale:ua()},paths:{cwd:process.cwd(),data:z.Path.data,config:z.Path.config},qitqode:{version:sr,channel:tr,installation_id:await ir(),run_id:pr,process_role:ur}}}var Rr={};J(Rr,{toString:()=>Da,parse:()=>ha,match:()=>La,fromParsedKey:()=>ea});var y={done:!1,hasNext:!1};function X(o,...r){let a=o,m=r.map((f)=>("lazy"in f)?Oa(f):void 0),n=0;for(;n<r.length;){if(m[n]===void 0||!Na(a)){let x=r[n];a=x(a),n+=1;continue}let f=[];for(let x=n;x<r.length;x++){let N=m[x];if(N===void 0||(f.push(N),N.isSingle))break}let s=[];for(let x of a)if(xr(x,s,f))break;let{isSingle:t}=f.at(-1);a=t?s[0]:s,n+=f.length}return a}function xr(o,r,a){if(a.length===0)return r.push(o),!1;let m=o,n=y,f=!1;for(let[s,t]of a.entries()){let{index:x,items:N}=t;if(N.push(m),n=t(m,x,N),t.index+=1,n.hasNext){if(n.hasMany??!1){for(let T of n.next)if(xr(T,r,a.slice(s+1)))return!0;return f}m=n.next}if(!n.hasNext)break;n.done&&(f=!0)}return n.hasNext&&r.push(m),f}function Oa(o){let{lazy:r,lazyArgs:a}=o,m=r(...a);return Object.assign(m,{isSingle:r.single??!1,index:0,items:[]})}function Na(o){return typeof o=="string"||typeof o=="object"&&o!==null&&Symbol.iterator in o}function xo(o,r){let a=r.length-o.length;if(a===1){let[m,...n]=r;return X(m,{lazy:o,lazyArgs:n})}if(a===0){let m={lazy:o,lazyArgs:r};return Object.assign((n)=>X(n,m),m)}throw Error("Wrong number of arguments")}function ja(...o){return xo(Ra,o)}function Ra(){let o=new Set;return(r)=>o.has(r)?y:(o.add(r),{done:!1,hasNext:!0,next:r})}function Ta(...o){return xo(Ia,o)}function Ia(o){let r=o,a=new Set;return(m,n,f)=>{let s=r(m,n,f);return a.has(s)?y:(a.add(s),{done:!1,hasNext:!0,next:m})}}function cr(o,r,a){let m=(n)=>o(n,...r);return a===void 0?m:Object.assign(m,{lazy:a,lazyArgs:r})}function O(o,r,a){let m=o.length-r.length;if(m===0)return o(...r);if(m===1)return cr(o,r,a);throw Error("Wrong number of arguments")}function Ma(...o){return O(Object.values,o)}var Nr={asc:(o,r)=>o>r,desc:(o,r)=>o<r};function co(o,r){let[a,...m]=r;if(!Wa(a)){let f=Jo(...m);return o(a,f)}let n=Jo(a,...m);return(f)=>o(f,n)}function Jo(o,r,...a){let m=typeof o=="function"?o:o[0],n=typeof o=="function"?"asc":o[1],{[n]:f}=Nr,s=r===void 0?void 0:Jo(r,...a);return(t,x)=>{let N=m(t),T=m(x);return f(N,T)?1:f(T,N)?-1:s?.(t,x)??0}}function Wa(o){if(Or(o))return!0;if(typeof o!="object"||!Array.isArray(o))return!1;let[r,a,...m]=o;return Or(r)&&typeof a=="string"&&a in Nr&&m.length===0}var Or=(o)=>typeof o=="function"&&o.length===1;function Oo(...o){return co(ba,o)}var ba=(o,r)=>[...o].sort(r);function Ba(...o){return O(Sa,o)}function Sa(o,r){let a={};for(let[m,n]of Object.entries(o))r(n,m,o)&&(a[m]=n);return a}function wo(o){if(typeof o!="object"||o===null)return!1;let r=Object.getPrototypeOf(o);return r===null||r===Object.prototype}function Ja(...o){return O(jr,o)}function jr(o,r){let a={...o,...r};for(let m in r){if(!(m in o))continue;let{[m]:n}=o;if(!wo(n))continue;let{[m]:f}=r;wo(f)&&(a[m]=jr(n,f))}return a}function h(...o){return O(wa,o)}var wa=(o,r)=>o.length>=r;function za(...o){return O(_a,o)}function _a(o,r){if(!h(r,1))return{...o};if(!h(r,2)){let{[r[0]]:m,...n}=o;return n}let a={...o};for(let m of r)delete a[m];return a}function Ca(...o){return O(Ha,o)}function Ha(o,r){let a={};for(let[m,n]of Object.entries(o)){let f=r(n,m,o);a[m]=f}return a}function Qa(...o){return O($a,o,Ga)}var $a=(o,r)=>o.map(r),Ga=(o)=>(r,a,m)=>({done:!1,hasNext:!0,next:o(r,a,m)});function Va(...o){return O(ya,o)}var ya=(o,r)=>{let a=Object.create(null);for(let m=0;m<o.length;m++){let n=o[m],f=r(n,m,o);if(f!==void 0){let s=a[f];s===void 0?a[f]=[n]:s.push(n)}}return Object.setPrototypeOf(a,Object.prototype),a};function zo(...o){return O(v,o)}function v(o,r){if(o===r||Object.is(o,r))return!0;if(typeof o!="object"||typeof r!="object"||o===null||r===null||Object.getPrototypeOf(o)!==Object.getPrototypeOf(r))return!1;if(Array.isArray(o))return Fa(o,r);if(o instanceof Map)return Ka(o,r);if(o instanceof Set)return Ua(o,r);if(o instanceof Date)return o.getTime()===r.getTime();if(o instanceof RegExp)return o.toString()===r.toString();if(Object.keys(o).length!==Object.keys(r).length)return!1;for(let[a,m]of Object.entries(o))if(!(a in r)||!v(m,r[a]))return!1;return!0}function Fa(o,r){if(o.length!==r.length)return!1;for(let[a,m]of o.entries())if(!v(m,r[a]))return!1;return!0}function Ka(o,r){if(o.size!==r.size)return!1;for(let[a,m]of o.entries())if(!r.has(a)||!v(m,r.get(a)))return!1;return!0}function Ua(o,r){if(o.size!==r.size)return!1;let a=[...r];for(let m of o){let n=!1;for(let[f,s]of a.entries())if(v(m,s)){n=!0,a.splice(f,1);break}if(!n)return!1}return!0}function Ya(...o){return co(qa,o)}function qa(o,r){if(!h(o,2))return o[0];let[a]=o,[,...m]=o;for(let n of m)r(n,a)<0&&(a=n);return a}function Xa(...o){return O(Pa,o,Aa)}var Pa=(o,r)=>o.flatMap(r),Aa=(o)=>(r,a,m)=>{let n=o(r,a,m);return Array.isArray(n)?{done:!1,hasNext:!0,hasMany:!0,next:n}:{done:!1,hasNext:!0,next:n}};function Za(...o){return O(Object.entries,o)}function Ea(...o){return O(da,o,ga)}var da=(o,r)=>o.filter(r),ga=(o)=>(r,a,m)=>o(r,a,m)?{done:!1,hasNext:!0,next:r}:y;function La(o,r){if(!o)return!1;let a={...o,super:o.super??!1},m={...r,super:r.super??!1};return zo(a,m)}function ea(o,r=!1){return{name:o.name===" "?"space":o.name,ctrl:o.ctrl,meta:o.meta,shift:o.shift,super:o.super??!1,leader:r}}function Da(o){if(!o)return"";let r=[];if(o.ctrl)r.push("ctrl");if(o.meta)r.push("alt");if(o.super)r.push("super");if(o.shift)r.push("shift");if(o.name)if(o.name==="delete")r.push("del");else r.push(o.name);let a=r.join("+");if(o.leader)a=a?`<leader> ${a}`:"<leader>";return a}function ha(o){if(o==="none")return[];return o.split(",").map((r)=>{let m=r.replace(/<leader>/g,"leader+").toLowerCase().split("+"),n={ctrl:!1,meta:!1,shift:!1,leader:!1,name:""};for(let f of m)switch(f){case"ctrl":n.ctrl=!0;break;case"alt":case"meta":case"option":n.meta=!0;break;case"super":n.super=!0;break;case"shift":n.shift=!0;break;case"leader":n.leader=!0;break;case"esc":n.name="escape";break;default:n.name=f;break}return n})}var Tr={};J(Tr,{create:()=>la,NotFound:()=>_o});import{AsyncLocalStorage as va}from"async_hooks";class _o extends Error{name;constructor(o){super(`No context found for ${o}`);this.name=o}}function la(o){let r=new va;return{use(){let a=r.getStore();if(!a)throw new _o(o);return a},provide(a,m){return r.run(a,m)}}}var Mr={};J(Mr,{truncateMiddle:()=>nm,truncate:()=>mm,todayTimeOrDateTime:()=>om,titlecase:()=>ka,time:()=>Co,pluralize:()=>fm,number:()=>rm,duration:()=>am,datetime:()=>Ir});function ka(o){return o.replace(/\b\w/g,(r)=>r.toUpperCase())}function Co(o){return new Date(o).toLocaleTimeString(void 0,{timeStyle:"short"})}function Ir(o){let r=new Date(o),a=Co(o),m=r.toLocaleDateString();return`${a} \xB7 ${m}`}function om(o){let r=new Date(o),a=new Date;if(r.getFullYear()===a.getFullYear()&&r.getMonth()===a.getMonth()&&r.getDate()===a.getDate())return Co(o);else return Ir(o)}function rm(o){if(o>=1e6)return(o/1e6).toFixed(1)+"M";else if(o>=1000)return(o/1000).toFixed(1)+"K";return o.toString()}function am(o){if(o<1000)return`${o}ms`;if(o<60000)return`${(o/1000).toFixed(1)}s`;if(o<3600000){let m=Math.floor(o/60000),n=Math.floor(o%60000/1000);return`${m}m ${n}s`}if(o<86400000){let m=Math.floor(o/3600000),n=Math.floor(o%3600000/60000);return`${m}h ${n}m`}let r=Math.floor(o%86400000/3600000);return`${Math.floor(o/86400000)}d ${r}h`}function mm(o,r){if(r<=0)return"";if(o.length<=r)return o;return o.slice(0,r-1)+"\u2026"}function nm(o,r=35){if(r<=0)return"";if(o.length<=r)return o;let a="\u2026",m=Math.ceil((r-a.length)/2),n=Math.floor((r-a.length)/2);return o.slice(0,m)+a+(n>0?o.slice(-n):"")}function fm(o,r,a){return(o===1?r:a).replace("{}",o.toString())}var Br={};J(Br,{write:()=>im,read:()=>tm});var l=new Map;function Wr(o){if(!l.has(o))l.set(o,{readers:0,writer:!1,waitingReaders:[],waitingWriters:[]});return l.get(o)}function sm(o){let r=l.get(o);if(!r||r.writer||r.readers>0)return;if(r.waitingWriters.length>0){r.waitingWriters.shift()();return}while(r.waitingReaders.length>0)r.waitingReaders.shift()();if(r.readers===0&&!r.writer&&r.waitingReaders.length===0&&r.waitingWriters.length===0)l.delete(o)}function br(o){return new Promise((r)=>{let a=()=>{o.acquire();let m=!1;r({[Symbol.dispose]:()=>{if(m)return;m=!0,o.release(),sm(o.key)}})};if(o.available())a();else o.waiting.push(a)})}async function tm(o){let r=Wr(o);return br({key:o,available:()=>!r.writer&&r.waitingWriters.length===0,acquire:()=>r.readers++,release:()=>r.readers--,waiting:r.waitingReaders})}async function im(o){let r=Wr(o);return br({key:o,available:()=>!r.writer&&r.readers===0,acquire:()=>{r.writer=!0},release:()=>{r.writer=!1},waiting:r.waitingWriters})}var yr={};J(yr,{redactValue:()=>Go,init:()=>Im,flush:()=>Mm,file:()=>Tm,enabled:()=>jm,create:()=>Vo,Level:()=>xm,Default:()=>Rm});import Io from"path";import F from"fs/promises";import{createWriteStream as Qr}from"fs";var lu="https://qortex.forgewise.tech/api/v1/qortex/streamTier",ku=new URL("https://qortex.forgewise.tech/api/v1/qortex/streamTier").origin,Sr="https://qortex.forgewise.tech/api/v1/qortex/streamTier".replace(/\/streamTier$/,""),ox={name:"QitQode",family:"qlex",npm:"@qitqode/qlex-provider",limit:{context:200000,output:16384},capabilities:{temperature:!0,reasoning:!1,attachment:!0,toolcall:!0,input:{text:!0,audio:!1,image:!0,video:!1,pdf:!1},output:{text:!0,audio:!1,image:!1,video:!1,pdf:!1},interleaved:!1},release_date:"2025-07-06"};function No(o){return o.replace(/provider\s+'[^']*'\s*(?:stream\s+)?(?:failed|error)?\s*:?\s*/gi,"").replace(/\b(?:anthropic|openai|google|vertex\s*ai|bedrock|azure|x\.?ai|mistral|deepseek|cohere|groq|together(?:\.ai)?|openrouter|fireworks|perplexity|meta)\b/gi,"").replace(/\b(?:gpt|claude|gemini|grok|llama|qwen|sonnet|opus|haiku|o[0-9])[-\w.]*/gi,"").replace(/\s+/g," ").replace(/^[\s:;,.\-]+/,"").replace(/[\s.]+$/,"").trim()}var rx={notLoggedIn:"Not logged in to QitQode. Run `qitqode auth login` to sign in with your Forgewise account.",rateLimit:"Rate limit exceeded. Please wait a moment before sending more requests.",insufficientBalance:(o)=>{let r=o?No(o):"";return`Insufficient qredits${r?`: ${r}`:""}. Add qredits at qitqode.com to continue.`},invalidCredentials:(o)=>{let r=o?No(o):"";return`QitQode sign-in was rejected by the server${r?` (${r})`:""}. Please sign in again with your Forgewise account or a valid API key.`},gatewayUnavailable:(o)=>{let r=o?No(o):"";return`The QitQode model gateway is unavailable${r?` (${r})`:""}. Your sign-in is still valid \u2014 the model backend isn't reachable through its trusted gateway yet. This is a server-side configuration issue, not a login problem.`},streamFailed:(o)=>{let r=o?No(o):"";return`The QitQode model stream failed${r?`: ${r}`:""}.`},insufficientBalanceFallback:"Insufficient qredits.",insufficientBalanceCliSuffix:" Visit qitqode.com to add qredits.",invalidCredentialsFallback:"QitQode sign-in was rejected by the server. Please sign in again.",apiKeyPrompt:"Paste your Qortex API key:",apiKeyPlaceholder:"qortex-...",loginMenuForgewise:"Sign in with Forgewise account",loginMenuApiKey:"Paste a Qortex API key",waitingForgewise:"\u23F3 Waiting for Forgewise sign-in in your browser\u2026"};function p(o){let r=process.env[o]?.toLowerCase();return r==="true"||r==="1"}function Ho(o){let r=process.env[o]?.toLowerCase();return r==="false"||r==="0"}function $(o){let r=process.env[o];if(!r)return;let a=Number(r);return Number.isInteger(a)&&a>0?a:void 0}var d=p("QITQODE_EXPERIMENTAL"),jo=p("QITQODE_DISABLE_CLAUDE_CODE"),Ro=p("QITQODE_DISABLE_EXTERNAL_SKILLS"),pm=Ro||jo||p("QITQODE_DISABLE_CLAUDE_CODE_SKILLS"),um=process.env.QITQODE_EXPERIMENTAL_DISABLE_COPY_ON_SELECT,Jr={OTEL_EXPORTER_OTLP_ENDPOINT:process.env.OTEL_EXPORTER_OTLP_ENDPOINT,OTEL_EXPORTER_OTLP_HEADERS:process.env.OTEL_EXPORTER_OTLP_HEADERS,QITQODE_AUTO_SHARE:p("QITQODE_AUTO_SHARE"),QITQODE_AUTO_HEAP_SNAPSHOT:p("QITQODE_AUTO_HEAP_SNAPSHOT"),QITQODE_GIT_BASH_PATH:process.env.QITQODE_GIT_BASH_PATH,QITQODE_CONFIG:process.env.QITQODE_CONFIG,QITQODE_CONFIG_CONTENT:process.env.QITQODE_CONFIG_CONTENT,get QITQODE_BACKEND_URL(){return process.env.QITQODE_BACKEND_URL??Sr},QITQODE_DISABLE_AUTOUPDATE:p("QITQODE_DISABLE_AUTOUPDATE"),QITQODE_DISABLE_LOG_ROTATION:p("QITQODE_DISABLE_LOG_ROTATION"),QITQODE_ALWAYS_NOTIFY_UPDATE:p("QITQODE_ALWAYS_NOTIFY_UPDATE"),QITQODE_DISABLE_PRUNE:p("QITQODE_DISABLE_PRUNE"),QITQODE_DISABLE_TERMINAL_TITLE:p("QITQODE_DISABLE_TERMINAL_TITLE"),QITQODE_SHOW_TTFD:p("QITQODE_SHOW_TTFD"),QITQODE_PERMISSION:process.env.QITQODE_PERMISSION,QITQODE_DISABLE_DEFAULT_PLUGINS:p("QITQODE_DISABLE_DEFAULT_PLUGINS"),QITQODE_DISABLE_LSP_DOWNLOAD:!0,QITQODE_ENABLE_EXPERIMENTAL_MODELS:p("QITQODE_ENABLE_EXPERIMENTAL_MODELS"),QITQODE_DISABLE_AUTOCOMPACT:p("QITQODE_DISABLE_AUTOCOMPACT"),QITQODE_DISABLE_MODELS_FETCH:p("QITQODE_DISABLE_MODELS_FETCH"),QITQODE_DISABLE_MOUSE:p("QITQODE_DISABLE_MOUSE"),QITQODE_OUTPUT_LENGTH_CONTINUATION_LIMIT:$("QITQODE_OUTPUT_LENGTH_CONTINUATION_LIMIT")??3,QITQODE_INVALID_OUTPUT_CONTINUATION_LIMIT:$("QITQODE_INVALID_OUTPUT_CONTINUATION_LIMIT")??2,QITQODE_TEXT_NGRAM_N:$("QITQODE_TEXT_NGRAM_N")??6,QITQODE_TEXT_REPEAT_THRESHOLD:$("QITQODE_TEXT_REPEAT_THRESHOLD")??3,QITQODE_TEXT_WINDOW_TOKENS:$("QITQODE_TEXT_WINDOW_TOKENS")??500,QITQODE_MAX_PROMPT_IMAGES:$("QITQODE_MAX_PROMPT_IMAGES")??4,QITQODE_MAX_PROMPT_IMAGE_SIZE:$("QITQODE_MAX_PROMPT_IMAGE_SIZE")??393216,QITQODE_DISABLE_PROVIDER_ENV:p("QITQODE_DISABLE_PROVIDER_ENV"),QITQODE_DISABLE_CLAUDE_CODE:jo,get QITQODE_DISABLE_CLAUDE_CODE_MCP(){return jo||p("QITQODE_DISABLE_CLAUDE_CODE_MCP")},QITQODE_DISABLE_CLAUDE_CODE_PROMPT:jo||p("QITQODE_DISABLE_CLAUDE_CODE_PROMPT"),QITQODE_DISABLE_CLAUDE_CODE_COMMANDS:p("QITQODE_DISABLE_CLAUDE_CODE_COMMANDS"),QITQODE_DISABLE_CLAUDE_CODE_SKILLS:pm,QITQODE_DISABLE_EXTERNAL_SKILLS:Ro,QITQODE_DISABLE_CODEX_SKILLS:Ro||p("QITQODE_DISABLE_CODEX_SKILLS"),QITQODE_DISABLE_OPENCODE_SKILLS:Ro||p("QITQODE_DISABLE_OPENCODE_SKILLS"),QITQODE_FAKE_VCS:process.env.QITQODE_FAKE_VCS,QITQODE_DISABLE_GIT:p("QITQODE_DISABLE_GIT"),get QITQODE_SERVER_PASSWORD(){return process.env.QITQODE_SERVER_PASSWORD},get QITQODE_SERVER_USERNAME(){return process.env.QITQODE_SERVER_USERNAME},QITQODE_ENABLE_QUESTION_TOOL:p("QITQODE_ENABLE_QUESTION_TOOL"),QITQODE_EXPERIMENTAL:d,QITQODE_EXPERIMENTAL_FILEWATCHER:k.boolean("QITQODE_EXPERIMENTAL_FILEWATCHER").pipe(k.withDefault(!1)),QITQODE_EXPERIMENTAL_DISABLE_FILEWATCHER:k.boolean("QITQODE_EXPERIMENTAL_DISABLE_FILEWATCHER").pipe(k.withDefault(!1)),QITQODE_EXPERIMENTAL_ICON_DISCOVERY:d||p("QITQODE_EXPERIMENTAL_ICON_DISCOVERY"),QITQODE_EXPERIMENTAL_DISABLE_COPY_ON_SELECT:um===void 0?process.platform==="win32":p("QITQODE_EXPERIMENTAL_DISABLE_COPY_ON_SELECT"),QITQODE_ENABLE_EXA:p("QITQODE_ENABLE_EXA")||d||p("QITQODE_EXPERIMENTAL_EXA"),QITQODE_EXPERIMENTAL_BASH_DEFAULT_TIMEOUT_MS:$("QITQODE_EXPERIMENTAL_BASH_DEFAULT_TIMEOUT_MS"),QITQODE_EXPERIMENTAL_OUTPUT_TOKEN_MAX:$("QITQODE_EXPERIMENTAL_OUTPUT_TOKEN_MAX"),QITQODE_EXPERIMENTAL_OXFMT:d||p("QITQODE_EXPERIMENTAL_OXFMT"),QITQODE_EXPERIMENTAL_LSP_TY:p("QITQODE_EXPERIMENTAL_LSP_TY"),QITQODE_EXPERIMENTAL_LSP_TOOL:d||p("QITQODE_EXPERIMENTAL_LSP_TOOL"),QITQODE_EXPERIMENTAL_WORKFLOW_TOOL:!Ho("QITQODE_EXPERIMENTAL_WORKFLOW_TOOL"),QITQODE_EXPERIMENTAL_MARKDOWN:!Ho("QITQODE_EXPERIMENTAL_MARKDOWN"),QITQODE_MODELS_URL:process.env.QITQODE_MODELS_URL,QITQODE_MODELS_PATH:process.env.QITQODE_MODELS_PATH,QITQODE_DB:process.env.QITQODE_DB,QITQODE_DISABLE_CHANNEL_DB:!Ho("QITQODE_DISABLE_CHANNEL_DB"),QITQODE_SKIP_MIGRATIONS:p("QITQODE_SKIP_MIGRATIONS"),QITQODE_STRICT_CONFIG_DEPS:p("QITQODE_STRICT_CONFIG_DEPS"),QITQODE_WORKSPACE_ID:process.env.QITQODE_WORKSPACE_ID,QITQODE_EXPERIMENTAL_HTTPAPI:p("QITQODE_EXPERIMENTAL_HTTPAPI"),QITQODE_EXPERIMENTAL_WORKSPACES:d||p("QITQODE_EXPERIMENTAL_WORKSPACES"),get QITQODE_DISABLE_COMPOSE_SKILLS(){return p("QITQODE_DISABLE_COMPOSE_SKILLS")},get QITQODE_DISABLE_BUILTIN_SKILLS(){return p("QITQODE_DISABLE_BUILTIN_SKILLS")},get QITQODE_DISABLE_PROJECT_CONFIG(){return p("QITQODE_DISABLE_PROJECT_CONFIG")},get QITQODE_TUI_CONFIG(){return process.env.QITQODE_TUI_CONFIG},get QITQODE_CONFIG_DIR(){return process.env.QITQODE_CONFIG_DIR},get QITQODE_HOME(){return process.env.QITQODE_HOME},get QITQODE_PURE(){return p("QITQODE_PURE")},get QITQODE_PLUGIN_META_FILE(){return process.env.QITQODE_PLUGIN_META_FILE},get QITQODE_CLIENT(){return process.env.QITQODE_CLIENT??"cli"}};var xm=Hr.enum(["DEBUG","INFO","WARN","ERROR"]).meta({ref:"LogLevel",description:"Log level"}),wr={DEBUG:0,INFO:1,WARN:2,ERROR:3},cm=10,Om=52428800,Nm=209715200,$r="INFO";function oo(o){return wr[o]>=wr[$r]}function jm(o){return oo(o)}var zr=new Map,Rm=Vo({service:"default"}),_="";function Tm(){return _}var ao,To=0,_r=!0,ro=(o)=>{return process.stderr.write(o),o.length};function Mo(){return new Date().toISOString().split(".")[0].replace(/:/g,"")}async function Im(o){if(o.level)$r=o.level;if(_r=o.rotate??!Jr.QITQODE_DISABLE_LOG_ROTATION,Gr(z.Path.log),o.print)return;if(_=Io.join(z.Path.log,o.dev?"dev.log":Mo()+".log"),o.dev){let r=await F.stat(_).catch(()=>null);if(r&&r.size>0)await F.rename(_,`${_}.${Mo()}`).catch(()=>{})}else await F.truncate(_).catch(()=>{});ao=Qr(_,{flags:"a"}),To=0,ro=(r)=>{return $o=$o.then(async()=>{if(To+=Buffer.byteLength(r),_r&&To>=Om)To=Buffer.byteLength(r),await Wm();await new Promise((a)=>{if(!ao){a();return}ao.write(r,()=>a())})}).catch(()=>{}),r.length}}var $o=Promise.resolve();async function Mm(){await $o}async function Wm(){let o=ao,r=`${_}.${Mo()}`;for(let a=2;await F.stat(r).then(()=>!0,()=>!1);a++)r=`${_}.${Mo()}.${a}`;if(await F.rename(_,r).catch(()=>{}),ao=Qr(_,{flags:"a"}),o)o.end();Gr(z.Path.log)}async function Gr(o){let r=await F.readdir(o).catch(()=>[]),m=(await Promise.all(r.filter((t)=>t.includes(".log")&&Io.join(o,t)!==_).map(async(t)=>{let x=await F.stat(Io.join(o,t)).catch(()=>null);return x?.isFile()?{name:t,size:x.size}:null}))).flatMap((t)=>t?[t]:[]).sort((t,x)=>t.name<x.name?-1:t.name>x.name?1:0),n=m.reduce((t,x)=>t+x.size,0),f=m.length,s=m.filter((t)=>{if(f<=cm&&n<=Nm)return!1;return n-=t.size,f-=1,!0});await Promise.all(s.map((t)=>F.unlink(Io.join(o,t.name)).catch(()=>{})))}var bm=/token|secret|password|passwd|credential|api[_-]?key|authorization|cookie|set-cookie/i;function Go(o,r){if(bm.test(o)&&r!==void 0&&r!==null)return"[REDACTED]";return r}var Qo=10240;function Bm(o){try{let r=JSON.stringify(o,function(a,m){return a?Go(a,m):m});if(typeof r==="string"&&r.length>Qo)return r.slice(0,Qo)+`\u2026[truncated ${r.length-Qo} chars]`;return r}catch{return"[unserializable]"}}function Vr(o,r=0){let a=o.message;return o.cause instanceof Error&&r<10?a+" Caused by: "+Vr(o.cause,r+1):a}var Cr=Date.now();function Vo(o){o=o||{};let r=o.service;if(r&&typeof r==="string"){let n=zr.get(r);if(n)return n}function a(n,f){let s=Object.entries({...o,...f}).filter(([N,T])=>T!==void 0&&T!==null).map(([N,T])=>{let P=`${N}=`;if(T instanceof Error)return P+Vr(T);let mo=Go(N,T);if(mo!==T)return P+mo;if(typeof T==="object"&&T!==null)return P+Bm(T);return P+T}).join(" "),t=new Date,x=t.getTime()-Cr;return Cr=t.getTime(),[t.toISOString().split(".")[0],"+"+x+"ms",s,n].filter(Boolean).join(" ")+`
3
- `}let m={debug(n,f){if(oo("DEBUG"))ro("DEBUG "+a(n,f))},info(n,f){if(oo("INFO"))ro("INFO "+a(n,f))},error(n,f){if(oo("ERROR"))ro("ERROR "+a(n,f))},warn(n,f){if(oo("WARN"))ro("WARN "+a(n,f))},tag(n,f){if(o)o[n]=f;return m},clone(){return Vo({...o})},time(n,f){let s=Date.now();m.info(n,{status:"started",...f});function t(){m.info(n,{status:"completed",duration:Date.now()-s,...f})}return{stop:t,[Symbol.dispose](){t()}}}};if(r&&typeof r==="string")zr.set(r,m);return m}var Fr={};J(Fr,{listen:()=>Sm,emit:()=>Jm,client:()=>wm});function Sm(o){onmessage=async(r)=>{let a=JSON.parse(r.data);if(a.type==="rpc.request")try{let m=await o[a.method](a.input);postMessage(JSON.stringify({type:"rpc.result",result:m,id:a.id}))}catch(m){postMessage(JSON.stringify({type:"rpc.result",error:m instanceof Error?m.message:String(m),id:a.id}))}}}function Jm(o,r){postMessage(JSON.stringify({type:"rpc.event",event:o,data:r}))}function wm(o){let r=new Map,a=new Map,m=0;return o.onmessage=async(n)=>{let f=JSON.parse(n.data);if(f.type==="rpc.result"){let s=r.get(f.id);if(s)if(r.delete(f.id),"error"in f)s.reject(Error(typeof f.error==="string"?f.error:"RPC call failed"));else s.resolve(f.result)}if(f.type==="rpc.event"){let s=a.get(f.event);if(s)for(let t of s)t(f.data)}},{call(n,f){let s=m++;return new Promise((t,x)=>{r.set(s,{resolve:t,reject:x});try{o.postMessage(JSON.stringify({type:"rpc.request",method:n,input:f,id:s}))}catch(N){r.delete(s),x(N)}})},on(n,f){let s=a.get(n);if(!s)s=new Set,a.set(n,s);return s.add(f),()=>{s.delete(f)}}}}var Ur={};J(Ur,{estimate:()=>Kr});function Kr(o){return Math.max(0,Math.round((o||"").length/4))}var Yr={};J(Yr,{match:()=>Wo,allStructured:()=>_m,all:()=>zm});function Wo(o,r){if(o)o=o.replaceAll("\\","/");if(r)r=r.replaceAll("\\","/");let a=r.replace(/[.+^${}()|[\]\\]/g,"\\$&").replace(/\*/g,".*").replace(/\?/g,".");if(a.endsWith(" .*"))a=a.slice(0,-3)+"( .*)?";let m=process.platform==="win32"?"si":"s";return new RegExp("^"+a+"$",m).test(o)}function zm(o,r){let a=X(r,Object.entries,Oo([([n])=>n.length,"asc"],[([n])=>n,"asc"])),m=void 0;for(let[n,f]of a)if(Wo(o,n)){m=f;continue}return m}function _m(o,r){let a=X(r,Object.entries,Oo([([n])=>n.length,"asc"],[([n])=>n,"asc"])),m=void 0;for(let[n,f]of a){let s=n.split(/\s+/);if(!Wo(o.head,s[0]))continue;if(s.length===1||yo(o.tail,s.slice(1))){m=f;continue}}return m}function yo(o,r){if(r.length===0)return!0;let[a,...m]=r;if(a==="*")return yo(o,m);for(let n=0;n<o.length;n++)if(Wo(o[n],a)&&yo(o.slice(n+1),m))return!0;return!1}export{sr as Wr,tr as Xr,fn as Yr,sn as Zr,X as _r,ja as $r,Ta as as,Ma as bs,Oo as cs,Ba as ds,Ja as es,za as fs,Ca as gs,Qa as hs,Va as is,zo as js,Ya as ks,Xa as ls,Za as ms,Ea as ns,Wo as os,Yr as ps,lu as qs,ku as rs,Sr as ss,ox as ts,No as us,rx as vs,pr as ws,ur as xs,ta as ys,On as zs,Nn as As,Po as Bs,Eo as Cs,Lo as Ds,ir as Es,ca as Fs,Rr as Gs,Tr as Hs,Mr as Is,Br as Js,wm as Ks,Fr as Ls,Ur as Ms,bo as Ns,to as Os,ra as Ps,H as Qs,z as Rs,Jr as Ss,xm as Ts,jm as Us,Rm as Vs,Tm as Ws,Im as Xs,Mm as Ys,Go as Zs,Vo as _s,yr as $s};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Df as k}from"./chunk-ywkvq7zb.js";import{Kg as f}from"./chunk-ps6jk326.js";function z(){return async(l,b)=>k(await f(l,b.options),b)}export{z as Cf};
@@ -1,5 +0,0 @@
1
- // @bun
2
- import{Fd as T,Hd as q,Id as N,Jd as w,Kd as X,Nd as D}from"./chunk-2p9py4rw.js";import"./chunk-n3t52cz2.js";import{Vf as Q}from"./chunk-cjfgs1x8.js";import{hh as A}from"./chunk-m2ny1en7.js";import"./chunk-09j71kp6.js";import"./chunk-js9wdh67.js";import"./chunk-0a0vat1h.js";import"./chunk-z8v2tsz2.js";import"./chunk-j8efst22.js";import"./chunk-8f0g7d7k.js";import"./chunk-abtn6nec.js";import"./chunk-d7t0bcvk.js";import{Fl as $}from"./chunk-7mc8nxve.js";import"./chunk-dfja6dj6.js";import"./chunk-n34y5gp6.js";import"./chunk-bn0h9dny.js";import"./chunk-q5363rr9.js";import"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import"./chunk-s2za1n7h.js";import"./chunk-19sa03c1.js";import"./chunk-csdm3n24.js";import"./chunk-xk1nh1ay.js";import"./chunk-bsf6n350.js";import"./chunk-4vze3djr.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-1d9f53sk.js";import"./chunk-svrxk3vf.js";import"./chunk-kkae8ead.js";import"./chunk-s6me101a.js";import"./chunk-jwtev7b7.js";import"./chunk-b9nwaaqs.js";import"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-fsy279s5.js";import"./chunk-hn1f6rne.js";import"./chunk-4kpvceap.js";import{Rs as W}from"./chunk-94qmhz2p.js";import{it as _,tt as Y}from"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-bv8pf0m1.js";import"./chunk-4mrz9b6d.js";import"./chunk-yjj4cvqg.js";import V from"fs/promises";import L from"path";import R from"os";var g={command:"uninstall",describe:"uninstall qitqode and remove all related files",builder:(j)=>j.option("keep-config",{alias:"c",type:"boolean",describe:"keep configuration files",default:!1}).option("keep-data",{alias:"d",type:"boolean",describe:"keep session data and snapshots",default:!1}).option("dry-run",{type:"boolean",describe:"show what would be removed without removing",default:!1}).option("force",{alias:"f",type:"boolean",describe:"skip confirmation prompts",default:!1}),handler:async(j)=>{Q.empty(),Q.println(Q.logo(" ")),Q.empty(),w("Uninstall QitQode");let B=await A.runPromise($.Service.use((J)=>J.method()));N.info(`Installation method: ${B}`);let E=await v(j,B);if(await z(E,B),!j.force&&!j.dryRun){let J=await q({message:"Are you sure you want to uninstall?",initialValue:!1});if(!J||T(J)){X("Cancelled");return}}if(j.dryRun){N.warn("Dry run - no changes made"),X("Done");return}await G(B,E),X("Done")}};async function v(j,B){let E=[{path:W.Path.data,label:"Data",keep:j.keepData},{path:W.Path.cache,label:"Cache",keep:!1},{path:W.Path.config,label:"Config",keep:j.keepConfig},{path:W.Path.state,label:"State",keep:!1}],J=B==="curl"?await P():null,H=B==="curl"?process.execPath:null;return{directories:E,shellConfig:J,binary:H}}async function z(j,B){N.message("The following will be removed:");for(let E of j.directories){if(!await V.access(E.path).then(()=>!0).catch(()=>!1))continue;let H=await F(E.path),K=S(H),O=E.keep?Q.Style.TEXT_DIM+"(keeping)":"",M=E.keep?"\u25CB":"\u2713";N.info(` ${M} ${E.label}: ${Z(E.path)} ${Q.Style.TEXT_DIM}(${K})${O}`)}if(j.binary)N.info(` \u2713 Binary: ${Z(j.binary)}`);if(j.shellConfig)N.info(` \u2713 Shell PATH in ${Z(j.shellConfig)}`);if(B!=="curl"&&B!=="unknown"){let E={npm:"npm uninstall -g @qitqode/cli",pnpm:"pnpm uninstall -g @qitqode/cli",bun:"bun remove -g @qitqode/cli"};N.info(` \u2713 Package: ${E[B]||B}`)}}async function G(j,B){let E=D(),J=[];for(let H of B.directories){if(H.keep){N.step(`Skipping ${H.label} (--keep-${H.label.toLowerCase()})`);continue}if(!await V.access(H.path).then(()=>!0).catch(()=>!1))continue;E.start(`Removing ${H.label}...`);let O=await V.rm(H.path,{recursive:!0,force:!0}).catch((M)=>M);if(O){E.stop(`Failed to remove ${H.label}`,1),J.push(`${H.label}: ${O.message}`);continue}E.stop(`Removed ${H.label}`)}if(B.shellConfig){E.start("Cleaning shell config...");let H=await k(B.shellConfig).catch((K)=>K);if(H)E.stop("Failed to clean shell config",1),J.push(`Shell config: ${H.message}`);else E.stop("Cleaned shell config")}if(j!=="curl"&&j!=="unknown"){let K={npm:["npm","uninstall","-g","@qitqode/cli"],pnpm:["pnpm","uninstall","-g","@qitqode/cli"],bun:["bun","remove","-g","@qitqode/cli"]}[j];if(K){E.start(`Running ${K.join(" ")}...`);let O=await _.run(K,{nothrow:!0});if(O.code!==0)E.stop(`Package manager uninstall failed: exit code ${O.code}`,1),N.warn(`You may need to run manually: ${K.join(" ")}`);else E.stop("Package removed")}else N.warn(`Uninstall not supported for method "${j}" yet, skipping package removal`)}if(j==="curl"&&B.binary){Q.empty(),N.message("To finish removing the binary, run:"),N.info(` rm "${B.binary}"`);let H=L.dirname(B.binary);if(H.includes(".qitqode"))N.info(` rmdir "${H}" 2>/dev/null`)}if(J.length>0){Q.empty(),N.warn("Some operations failed:");for(let H of J)N.error(` ${H}`)}Q.empty(),N.success("Thank you for using QitQode!")}async function P(){let j=L.basename(process.env.SHELL||"bash"),B=R.homedir(),E=process.env.XDG_CONFIG_HOME||L.join(B,".config"),J={fish:[L.join(E,"fish","config.fish")],zsh:[L.join(B,".zshrc"),L.join(B,".zshenv"),L.join(E,"zsh",".zshrc"),L.join(E,"zsh",".zshenv")],bash:[L.join(B,".bashrc"),L.join(B,".bash_profile"),L.join(B,".profile"),L.join(E,"bash",".bashrc"),L.join(E,"bash",".bash_profile")],ash:[L.join(B,".ashrc"),L.join(B,".profile")],sh:[L.join(B,".profile")]},H=J[j]||J.bash;for(let K of H){if(!await V.access(K).then(()=>!0).catch(()=>!1))continue;let M=await Y.readText(K).catch(()=>"");if(M.includes("# qitqode")||M.includes(".qitqode/bin"))return K}return null}async function k(j){let E=(await Y.readText(j)).split(`
3
- `),J=[],H=!1;for(let O of E){let M=O.trim();if(M==="# qitqode"){H=!0;continue}if(H){if(H=!1,M.includes(".qitqode/bin")||M.includes("fish_add_path"))continue}if(M.startsWith("export PATH=")&&M.includes(".qitqode/bin")||M.startsWith("fish_add_path")&&M.includes(".qitqode"))continue;J.push(O)}while(J.length>0&&J[J.length-1].trim()==="")J.pop();let K=J.join(`
4
- `)+`
5
- `;await Y.write(j,K)}async function F(j){let B=0,E=async(J)=>{let H=await V.readdir(J,{withFileTypes:!0}).catch(()=>[]);for(let K of H){let O=L.join(J,K.name);if(K.isDirectory()){await E(O);continue}if(K.isFile()){let M=await V.stat(O).catch(()=>null);if(M)B+=M.size}}};return await E(j),B}function S(j){if(j<1024)return`${j} B`;if(j<1048576)return`${(j/1024).toFixed(1)} KB`;if(j<1073741824)return`${(j/1048576).toFixed(1)} MB`;return`${(j/1073741824).toFixed(1)} GB`}function Z(j){let B=R.homedir();if(j===B||j.startsWith(B+L.sep))return"~"+j.slice(B.length);return j}export{g as UninstallCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{GO as t}from"./chunk-yjj4cvqg.js";var e=await import("./chunk-78m8rayq.js",{with:{type:"file"}}),a=e.default;export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-yjj4cvqg.js";var n="./highlights-hk7bwhj4.scm";export{n as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{GO as t}from"./chunk-yjj4cvqg.js";var e=await import("./chunk-ch8cx9jn.js",{with:{type:"file"}}),a=e.default;export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{nq as a,oq as b,pq as c}from"./chunk-svrxk3vf.js";import"./chunk-kkae8ead.js";import"./chunk-yjj4cvqg.js";export{a as openApp,c as default,b as apps};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{p as w,q as h,r as I,s as C,t as D}from"./chunk-kw09hbrb.js";import{Id as c,Jd as k,Kd as $,Nd as x}from"./chunk-2p9py4rw.js";import"./chunk-n3t52cz2.js";import{Rd as P}from"./chunk-yajd975f.js";import{Vf as d}from"./chunk-cjfgs1x8.js";import{lm as l}from"./chunk-dfja6dj6.js";import"./chunk-n34y5gp6.js";import"./chunk-bn0h9dny.js";import{Wn as v}from"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import"./chunk-19sa03c1.js";import"./chunk-csdm3n24.js";import"./chunk-xk1nh1ay.js";import"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-fsy279s5.js";import"./chunk-hn1f6rne.js";import{Rs as b}from"./chunk-94qmhz2p.js";import{ct as m}from"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-yjj4cvqg.js";var j={spinner:()=>x(),log:{error:(o)=>c.error(o),info:(o)=>c.info(o),success:(o)=>c.success(o)},resolve:(o)=>v(o),...h,global:b.Path.config};function S(o){if(!o||typeof o!=="object")return;if(!("cause"in o))return;return o.cause}function _(o,e=j){let n=o.mod,a=Boolean(o.force),y=Boolean(o.global);return async(f)=>{let u=e.spinner();u.start("Installing plugin package...");let p=await I(n,e);if(!p.ok){u.stop("Install failed",1),e.log.error(`Could not install "${n}"`);let t=w(p.error);if(t.detail)e.log.error(t.detail);if(t.missing)e.log.info("This package depends on a version that is not available in your npm registry."),e.log.info("Check npm registry/auth settings and try again.");return!1}u.stop("Plugin package ready");let s=e.spinner();s.start("Reading plugin manifest...");let i=await C(p.target);if(!i.ok){if(i.code==="manifest_read_failed")return s.stop("Manifest read failed",1),e.log.error(`Installed "${n}" but failed to read ${i.file}`),e.log.error(m(S(i.error)??i.error)),!1;if(i.code==="manifest_no_targets")return s.stop("No plugin targets found",1),e.log.error(`"${n}" does not expose plugin entrypoints in package.json`),e.log.info('Expected one of: exports["./tui"], exports["./server"], package.json main for server, or package.json["oc-themes"] for tui themes.'),!1;return s.stop("Manifest read failed",1),!1}s.stop(`Detected ${i.targets.map((t)=>t.kind).join(" + ")} target${i.targets.length===1?"":"s"}`);let g=e.spinner();g.start("Updating plugin config...");let r=await D({spec:n,targets:i.targets,force:a,global:y,vcs:f.vcs,worktree:f.worktree,directory:f.directory,config:e.global},e);if(!r.ok){if(r.code==="invalid_json")return g.stop(`Failed updating ${r.kind} config`,1),e.log.error(`Invalid JSON in ${r.file} (${r.parse} at line ${r.line}, column ${r.col})`),e.log.info("Fix the config file and run the command again."),!1;return g.stop("Failed updating plugin config",1),e.log.error(m(r.error)),!1}g.stop("Plugin config updated");for(let t of r.items){if(t.mode==="noop"){e.log.info(`Already configured in ${t.file}`);continue}if(t.mode==="replace"){e.log.info(`Replaced in ${t.file}`);continue}e.log.info(`Added to ${t.file}`)}return e.log.success(`Installed ${n}`),e.log.info(y?`Scope: global (${r.dir})`:`Scope: local (${r.dir})`),!0}}var R=P({command:"plugin <module>",aliases:["plug"],describe:"install plugin and update config",builder:(o)=>{return o.positional("module",{type:"string",describe:"npm module name"}).option("global",{alias:["g"],type:"boolean",default:!1,describe:"install in global config"}).option("force",{alias:["f"],type:"boolean",default:!1,describe:"replace existing plugin version"})},handler:async(o)=>{let e=String(o.module??"").trim();if(!e){d.error("module is required"),process.exitCode=1;return}d.empty(),k(`Install plugin ${e}`);let n=_({mod:e,global:Boolean(o.global),force:Boolean(o.force)}),a=!0;if(await l.provide({directory:process.cwd(),fn:async()=>{a=await n({vcs:l.project.vcs,worktree:l.worktree,directory:l.directory})}}),$("Done"),!a)process.exitCode=1}});export{_ as createPlugTask,R as PluginCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Gl as a,Hl as b,Il as c,Jl as d,Kl as e,Ll as f,Ml as g,Nl as h,Ol as i}from"./chunk-7mc8nxve.js";import"./chunk-n34y5gp6.js";import"./chunk-a8p9aggx.js";import"./chunk-csdm3n24.js";import"./chunk-6hdjkvr1.js";import"./chunk-94qmhz2p.js";import"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-yjj4cvqg.js";export{i as stopRefresh,h as startRefresh,g as refresh,d as readModelCatalogResponse,f as get,c as Provider,b as Model,a as MODEL_CATALOG_MAX_BYTES,e as Data};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{$f as d,Yf as a,Zf as b,_f as c,ag as e}from"./chunk-5z7mjwwa.js";import"./chunk-z29fwg61.js";import"./chunk-b9hstp7h.js";import"./chunk-j0znryc6.js";import"./chunk-sbv96mj0.js";import"./chunk-nfg7nt13.js";import"./chunk-ps6jk326.js";import"./chunk-tsb9g1nz.js";import"./chunk-m2ny1en7.js";import"./chunk-09j71kp6.js";import"./chunk-js9wdh67.js";import"./chunk-0a0vat1h.js";import"./chunk-z8v2tsz2.js";import"./chunk-j8efst22.js";import"./chunk-8f0g7d7k.js";import"./chunk-abtn6nec.js";import"./chunk-d7t0bcvk.js";import"./chunk-7mc8nxve.js";import"./chunk-dfja6dj6.js";import"./chunk-n34y5gp6.js";import"./chunk-bn0h9dny.js";import"./chunk-q5363rr9.js";import"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import"./chunk-s2za1n7h.js";import"./chunk-19sa03c1.js";import"./chunk-csdm3n24.js";import"./chunk-xk1nh1ay.js";import"./chunk-bsf6n350.js";import"./chunk-4vze3djr.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-1d9f53sk.js";import"./chunk-svrxk3vf.js";import"./chunk-kkae8ead.js";import"./chunk-s6me101a.js";import"./chunk-jwtev7b7.js";import"./chunk-b9nwaaqs.js";import"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-fsy279s5.js";import"./chunk-hn1f6rne.js";import"./chunk-4kpvceap.js";import"./chunk-94qmhz2p.js";import"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-bv8pf0m1.js";import"./chunk-4mrz9b6d.js";import"./chunk-yjj4cvqg.js";export{c as url,b as openapi,d as listen,e as Server,a as Default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-yjj4cvqg.js";var t="./tree-sitter-3jzf13jk.wasm";export{t as default};
@@ -1,3 +0,0 @@
1
- // @bun
2
- import{Tt as o}from"./chunk-j2zay4da.js";var e=o;
3
- export{e as vt};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Kq as a,Lq as b,Mq as c}from"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-94qmhz2p.js";import"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-yjj4cvqg.js";export{c as makeRuntime,a as attachWith,b as attach};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Sd as a,Td as b,Ud as c}from"./chunk-0626rvy2.js";import"./chunk-ekndhwnn.js";import"./chunk-sv48x9h8.js";import"./chunk-yp3dj4wh.js";import"./chunk-yjj4cvqg.js";export{b as validateSsoProfile,a as isSsoProfile,c as fromSSO};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-yjj4cvqg.js";var a="./highlights-x6tmsnaa.scm";export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{of as h}from"./chunk-g3ch14a1.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yjj4cvqg.js";var v=(q)=>{return h({baseURL:"https://gateway.ai.cloudflare.com/v1/compat",name:"Unified",...q||{}})},x=v();export{x as unified,v as createUnified};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Lg as a}from"./chunk-tsb9g1nz.js";import{Yg as t,hh as c}from"./chunk-m2ny1en7.js";import"./chunk-09j71kp6.js";import"./chunk-js9wdh67.js";import"./chunk-0a0vat1h.js";import"./chunk-z8v2tsz2.js";import"./chunk-j8efst22.js";import"./chunk-8f0g7d7k.js";import"./chunk-abtn6nec.js";import"./chunk-d7t0bcvk.js";import"./chunk-7mc8nxve.js";import"./chunk-dfja6dj6.js";import"./chunk-n34y5gp6.js";import"./chunk-bn0h9dny.js";import"./chunk-q5363rr9.js";import"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import"./chunk-s2za1n7h.js";import"./chunk-19sa03c1.js";import"./chunk-csdm3n24.js";import"./chunk-xk1nh1ay.js";import"./chunk-bsf6n350.js";import"./chunk-4vze3djr.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-1d9f53sk.js";import"./chunk-svrxk3vf.js";import"./chunk-kkae8ead.js";import"./chunk-s6me101a.js";import"./chunk-jwtev7b7.js";import"./chunk-b9nwaaqs.js";import"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-fsy279s5.js";import"./chunk-hn1f6rne.js";import"./chunk-4kpvceap.js";import"./chunk-94qmhz2p.js";import"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import{vt as i}from"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-bv8pf0m1.js";import"./chunk-4mrz9b6d.js";import"./chunk-yjj4cvqg.js";var n=i.object({name:a.shape.name,branch:a.shape.branch.unwrap(),directory:a.shape.directory.unwrap()}),d={name:"Worktree",description:"Create a git worktree",async configure(e){let r=await c.runPromise(t.Service.use((o)=>o.makeWorktreeInfo()));return{...e,name:r.name,branch:r.branch,directory:r.directory}},async create(e){let r=n.parse(e);await c.runPromise(t.Service.use((o)=>o.createFromInfo({name:r.name,directory:r.directory,branch:r.branch})))},async remove(e){let r=n.parse(e);await c.runPromise(t.Service.use((o)=>o.remove({directory:r.directory})))},target(e){return{type:"local",directory:n.parse(e).directory}}};export{d as WorktreeAdaptor};
@@ -1,8 +0,0 @@
1
- // @bun
2
- import{a as XB,b as YB}from"./chunk-11d987sj.js";import"./chunk-2ztdqtnk.js";import"./chunk-bx6kyvg7.js";import{B as JB}from"./chunk-gsez13bg.js";import{C as r,E as e}from"./chunk-c8k32724.js";import"./chunk-0yqbyres.js";import{I as BB}from"./chunk-s6bar2f9.js";import{O as VB}from"./chunk-6p7yg5sr.js";import"./chunk-2p9py4rw.js";import"./chunk-n3t52cz2.js";import{Rd as t}from"./chunk-yajd975f.js";import{Of as p,Pf as T,Qf as R,Rf as g}from"./chunk-v9xnk9pz.js";import{Vf as H}from"./chunk-cjfgs1x8.js";import{Dg as a}from"./chunk-j0znryc6.js";import{hh as y}from"./chunk-m2ny1en7.js";import"./chunk-09j71kp6.js";import"./chunk-js9wdh67.js";import"./chunk-0a0vat1h.js";import"./chunk-z8v2tsz2.js";import"./chunk-j8efst22.js";import"./chunk-8f0g7d7k.js";import"./chunk-abtn6nec.js";import{ok as n,rl as s}from"./chunk-d7t0bcvk.js";import"./chunk-7mc8nxve.js";import{km as h}from"./chunk-dfja6dj6.js";import"./chunk-n34y5gp6.js";import"./chunk-bn0h9dny.js";import"./chunk-q5363rr9.js";import"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import{ko as L,mo as i,po as o}from"./chunk-s2za1n7h.js";import"./chunk-19sa03c1.js";import"./chunk-csdm3n24.js";import"./chunk-xk1nh1ay.js";import"./chunk-bsf6n350.js";import"./chunk-4vze3djr.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-1d9f53sk.js";import"./chunk-svrxk3vf.js";import"./chunk-kkae8ead.js";import"./chunk-s6me101a.js";import"./chunk-jwtev7b7.js";import"./chunk-b9nwaaqs.js";import"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-fsy279s5.js";import"./chunk-hn1f6rne.js";import{Ur as I}from"./chunk-4kpvceap.js";import{As as c,Ks as l,Vs as q,ws as v,xs as d,ys as f}from"./chunk-94qmhz2p.js";import{ct as D,qt as u,st as N}from"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import{qH as F}from"./chunk-t299e2aw.js";import"./chunk-bv8pf0m1.js";import"./chunk-4mrz9b6d.js";import{GO as O}from"./chunk-yjj4cvqg.js";import k from"path";import{fileURLToPath as zB}from"url";import{writeHeapSnapshot as WB}from"v8";import HB,{EOL as K}from"os";var ZB={free:"free",default:"default",fast:"fast",economy:"economical",power:"power",orchestrated:"orchestrated"};function GB(B){for(let[V,X]of Object.entries(ZB))if(B[V]){let Z=I[X];if(Z)return`${Z.providerID}/${Z.modelID}`}return}function KB(B){return async(X,Z)=>{let Y=new Request(X,Z),W=Y.body?await Y.text():void 0,$=await B.call("fetch",{url:Y.url,method:Y.method,headers:Object.fromEntries(Y.headers.entries()),body:W});return new Response($.body,{status:$.status,headers:$.headers})}}function MB(B){return{subscribe:async(V)=>{return B.on("global.event",(X)=>{V(X)})}}}async function jB(){if(typeof globalThis.QITQODE_WORKER_PATH<"u")return globalThis.QITQODE_WORKER_PATH;let B=new URL("./cli/cmd/tui/worker.js",import.meta.url);if(await u(zB(B)))return B;return new URL("./worker.ts",import.meta.url)}async function QB(B){let V=process.stdin.isTTY?void 0:await Bun.stdin.text();if(!B)return V;if(!V)return B;return V+`
3
- `+B}async function m(B){let V=i({baseUrl:B.url,fetch:B.fetch,directory:B.directory}),X=[{permission:"question",action:"deny",pattern:"*"},{permission:"plan_enter",action:"deny",pattern:"*"},{permission:"plan_exit",action:"deny",pattern:"*"}],Y=(await V.session.create({permission:X})).data?.id;if(!Y){H.error("headless: failed to create session");return}let W=await V.event.subscribe(),$=VB({sessionID:Y,query:async()=>{return(await V.session.status()).data?.[Y]}}),x=W.stream[Symbol.asyncIterator](),b=$.completion.then(()=>"DONE");(async()=>{try{while(!0){let z=await Promise.race([x.next(),b]);if(z==="DONE")break;let C=z;if(C.done)break;let M=C.value;$.onEvent(M);let G=M.properties;if(M.type==="message.part.updated"){let J=G?.part;if(!J||J.sessionID!==Y)continue;if(J.type==="text"&&J.time?.end){let A=String(J.text??"").trim();if(A)process.stdout.write(A+K)}}if(M.type==="permission.asked"){if(!G||G.sessionID!==Y)continue;await V.permission.reply({requestID:String(G.id),reply:"once"})}if(M.type==="session.error"){if(!G||G.sessionID!==Y||!G.error)continue;let J=G.error,A=J?.data!==null&&typeof J?.data==="object"&&"message"in J.data?String(J.data.message):String(J?.name??J);H.error(A)}}}finally{$.stop(),await x.return?.(void 0).catch(()=>{})}})().catch((z)=>{console.error(z),process.exit(1)});let S=B.model?s.parseModel(B.model):void 0;await V.session.prompt({sessionID:Y,agent:B.agent,model:S,parts:[{type:"text",text:B.prompt}]}),$.markStarted(),await $.completion}var pB=t({command:"$0 [project]",describe:"start qitqode tui",builder:(B)=>p(B).positional("project",{type:"string",describe:"path to start qitqode in"}).options(g).option("never-ask",{type:"boolean",describe:"start in never-ask mode \u2014 auto-decide without asking (permissions excluded), toggle at runtime with /never-ask",default:!1}).check((V)=>{if(V.dark&&V.light)throw Error("--dark and --light are mutually exclusive");if(V.sso&&!V.headless)throw Error("--sso requires --headless");if(V.sso&&V["api-key"]!==void 0)throw Error("--sso and --api-key are mutually exclusive");let X=Object.keys(ZB).filter((Z)=>V[Z]);if(X.length>1)throw Error(`${X.map((Z)=>`--${Z}`).join(" and ")} are mutually exclusive \u2014 choose one tier flag`);if(X.length===1&&V.model)throw Error(`--${X[0]} and --model are mutually exclusive \u2014 use one or the other`);return!0}),handler:async(B)=>{if(B.monochrome)process.env.QITQODE_TUI_ACCESSIBLE="1",process.env.NO_COLOR="1";let V=e();try{r();let X=JB(B);if(X){H.error(X),process.exitCode=1;return}let Z=GB(B)??B.model,Y=N(process.env.PWD??process.cwd()),W=B.project?N(k.isAbsolute(B.project)?B.project:k.join(Y,B.project)):N(process.cwd()),$=h(W);if($){if(B.project){H.error("Cannot start in "+W+": "+$),process.exitCode=1;return}let J=N(HB.homedir());if(h(J)){H.error("Cannot start in "+W+": "+$),process.exitCode=1;return}q.warn("unsafe start directory, falling back to home",{requested:W,home:J}),W=J}let x=await jB();try{process.chdir(W)}catch{H.error("Failed to change directory to "+W);return}let b=N(process.cwd()),w=c({[d]:"worker",[v]:f()}),S=new Worker(x,{env:w});S.onerror=(J)=>{q.error("thread error",{message:J.message,filename:J.filename,lineno:J.lineno,colno:J.colno,error:J.error})};let z=l(S),C=()=>{z.call("reload",void 0).catch((J)=>{q.warn("worker reload failed",{error:D(J)})})};process.on("SIGUSR2",C);let M=!1,G=async()=>{if(M)return;M=!0,process.off("SIGUSR2",C),await n(z.call("shutdown",void 0),5000).catch((J)=>{q.warn("worker shutdown failed",{error:D(J)})}),S.terminate()};try{let J=import("./chunk-qm07wesh.js"),A=import("./chunk-7tjd6ba1.js").then(({TuiConfig:P})=>P.get()),U=await QB(B.prompt),$B=await A;if(B.headless&&T(R(B))){H.error("--headless cannot be combined with network-listener flags (--port, --hostname, --mdns)"),process.exitCode=1;return}let E=R(B),_=T(E)?{url:(await z.call("server",E)).url,fetch:void 0,events:void 0}:{url:"http://qitqode.internal",fetch:KB(z),events:MB(z)};if(setTimeout(()=>{z.call("checkUpgrade",{directory:b}).catch(()=>{})},1000).unref?.(),B.headless){if(!U){H.error("--headless requires a prompt: pass --prompt or pipe input via stdin"),process.exitCode=1;return}if(B.sso){try{let j=await a({tryOpen:!1,onCode:(Q)=>{if(process.stdout.write(K),process.stdout.write(" To sign in, open: "+Q.verificationUri+K),process.stdout.write(" and enter code: "+Q.userCode+K),Q.verificationUriComplete)process.stdout.write(K+" Or open this link directly:"+K+" "+Q.verificationUriComplete+K);process.stdout.write(K+" Waiting for approval... (ctrl+c to cancel)"+K)}});await y.runPromise(F.gen(function*(){yield*(yield*L.Service).set("forgewise",BB(j,{rotateRefreshToken:!0}))})),process.stdout.write(" Signed in as "+(j.name||j.email)+K)}catch(j){H.error("SSO sign-in failed: "+D(j)),process.exitCode=1;return}await m({url:_.url,fetch:_.fetch,prompt:U,model:Z,agent:B.agent??"build",directory:b});return}let P=XB(typeof B["api-key"]==="string"?String(B["api-key"]):"");if(P)await y.runPromise(YB(P));else if(!await y.runPromise(F.gen(function*(){if(yield*F.promise(()=>o()))return!0;return!!(yield*(yield*L.Service).get("forgewise"))}))){H.error(`Not signed in. Use one of:
4
- qode auth login (browser / device-code flow)
5
- qode auth login --api-key (paste a Qortex API key)
6
- --api-key <key> (inline for this run)
7
- $QLEX_API_KEY (environment variable)
8
- $QITQODE_KEY (environment variable)`),process.exitCode=1;return}await m({url:_.url,fetch:_.fetch,prompt:U,model:Z,agent:B.agent??"build",directory:b})}else{let{tui:P}=await J;await P({url:_.url,async onSnapshot(){let j=WB("tui.heapsnapshot"),Q=await z.call("snapshot",void 0);return[j,Q]},config:$B,directory:b,fetch:_.fetch,events:_.events,args:{continue:B.continue,sessionID:B.session,agent:B.agent,model:Z,prompt:U,fork:B.fork,neverAsk:B["never-ask"]||B.fullauto||!1,fullauto:B.fullauto||!1,themeMode:B.dark?"dark":B.light?"light":void 0,monochrome:B.monochrome||!1,headless:!1}})}}finally{await G()}}finally{V?.()}process.exit(0)}});export{pB as TuiThreadCommand};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Jg as t}from"./chunk-ps6jk326.js";import{GO as n}from"./chunk-yjj4cvqg.js";async function a(){try{let{JSONSchema:e}=await import("./chunk-fhdpp77n.js");return(r)=>e.make(r)}catch{throw new t("effect")}}export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-yjj4cvqg.js";var e="./libopentui-c48jzvfh.so";export{e as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{mg as a,ng as b,og as c}from"./chunk-z29fwg61.js";import"./chunk-d7t0bcvk.js";import"./chunk-7mc8nxve.js";import"./chunk-dfja6dj6.js";import"./chunk-n34y5gp6.js";import"./chunk-bn0h9dny.js";import"./chunk-q5363rr9.js";import"./chunk-7wthn44y.js";import"./chunk-a8p9aggx.js";import"./chunk-0xm85ayc.js";import"./chunk-s2za1n7h.js";import"./chunk-19sa03c1.js";import"./chunk-csdm3n24.js";import"./chunk-xk1nh1ay.js";import"./chunk-bsf6n350.js";import"./chunk-4vze3djr.js";import"./chunk-bzrsnv2k.js";import"./chunk-d0qqgxs4.js";import"./chunk-cqtkxwd8.js";import"./chunk-v00cptj6.js";import"./chunk-1d9f53sk.js";import"./chunk-svrxk3vf.js";import"./chunk-kkae8ead.js";import"./chunk-s6me101a.js";import"./chunk-qsszerj7.js";import"./chunk-6jewfaqa.js";import"./chunk-6hdjkvr1.js";import"./chunk-1rn0vmvv.js";import"./chunk-fsy279s5.js";import"./chunk-hn1f6rne.js";import"./chunk-4kpvceap.js";import"./chunk-94qmhz2p.js";import"./chunk-20d0cd1j.js";import"./chunk-yn576pje.js";import"./chunk-b6dsv601.js";import"./chunk-j2zay4da.js";import"./chunk-4vemws1t.js";import"./chunk-yvqbewmc.js";import"./chunk-t299e2aw.js";import"./chunk-4mrz9b6d.js";import"./chunk-yjj4cvqg.js";export{b as run,a as encodeDir,c as ClaudeImport};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{GO as t}from"./chunk-yjj4cvqg.js";var e=await import("./chunk-1s9ctg0d.js",{with:{type:"file"}}),a=e.default;export{a as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-yjj4cvqg.js";function o(){return(e,n)=>e.toJsonSchema(n)}export{o as default};
@@ -1,2 +0,0 @@
1
- // @bun
2
- import"./chunk-yjj4cvqg.js";var _="./libopentui-0r5w9btr.so";export{_ as default};