axm.sh 0.1.6

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 (503) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +26 -0
  3. package/dist/src/app.d.ts +7 -0
  4. package/dist/src/app.d.ts.map +1 -0
  5. package/dist/src/app.js +96 -0
  6. package/dist/src/app.js.map +1 -0
  7. package/dist/src/cli-flags.d.ts +3 -0
  8. package/dist/src/cli-flags.d.ts.map +1 -0
  9. package/dist/src/cli-flags.js +4 -0
  10. package/dist/src/cli-flags.js.map +1 -0
  11. package/dist/src/formatter.d.ts +22 -0
  12. package/dist/src/formatter.d.ts.map +1 -0
  13. package/dist/src/formatter.js +170 -0
  14. package/dist/src/formatter.js.map +1 -0
  15. package/dist/src/json-output.d.ts +41 -0
  16. package/dist/src/json-output.d.ts.map +1 -0
  17. package/dist/src/json-output.js +171 -0
  18. package/dist/src/json-output.js.map +1 -0
  19. package/dist/src/main.d.ts +3 -0
  20. package/dist/src/main.d.ts.map +1 -0
  21. package/dist/src/main.js +4 -0
  22. package/dist/src/main.js.map +1 -0
  23. package/dist/src/root/auth/_auth.d.ts +3 -0
  24. package/dist/src/root/auth/_auth.d.ts.map +1 -0
  25. package/dist/src/root/auth/_auth.js +11 -0
  26. package/dist/src/root/auth/_auth.js.map +1 -0
  27. package/dist/src/root/auth/login.d.ts +15 -0
  28. package/dist/src/root/auth/login.d.ts.map +1 -0
  29. package/dist/src/root/auth/login.js +55 -0
  30. package/dist/src/root/auth/login.js.map +1 -0
  31. package/dist/src/root/auth/logout.d.ts +7 -0
  32. package/dist/src/root/auth/logout.d.ts.map +1 -0
  33. package/dist/src/root/auth/logout.js +59 -0
  34. package/dist/src/root/auth/logout.js.map +1 -0
  35. package/dist/src/root/auth/token.d.ts +7 -0
  36. package/dist/src/root/auth/token.d.ts.map +1 -0
  37. package/dist/src/root/auth/token.js +45 -0
  38. package/dist/src/root/auth/token.js.map +1 -0
  39. package/dist/src/root/auth/whoami.d.ts +7 -0
  40. package/dist/src/root/auth/whoami.d.ts.map +1 -0
  41. package/dist/src/root/auth/whoami.js +73 -0
  42. package/dist/src/root/auth/whoami.js.map +1 -0
  43. package/dist/src/root/commands/_commands.d.ts +3 -0
  44. package/dist/src/root/commands/_commands.d.ts.map +1 -0
  45. package/dist/src/root/commands/_commands.js +45 -0
  46. package/dist/src/root/commands/_commands.js.map +1 -0
  47. package/dist/src/root/commands/disable.d.ts +17 -0
  48. package/dist/src/root/commands/disable.d.ts.map +1 -0
  49. package/dist/src/root/commands/disable.js +100 -0
  50. package/dist/src/root/commands/disable.js.map +1 -0
  51. package/dist/src/root/commands/enable.d.ts +17 -0
  52. package/dist/src/root/commands/enable.d.ts.map +1 -0
  53. package/dist/src/root/commands/enable.js +101 -0
  54. package/dist/src/root/commands/enable.js.map +1 -0
  55. package/dist/src/root/commands/install/command-actions.d.ts +61 -0
  56. package/dist/src/root/commands/install/command-actions.d.ts.map +1 -0
  57. package/dist/src/root/commands/install/command-actions.js +211 -0
  58. package/dist/src/root/commands/install/command-actions.js.map +1 -0
  59. package/dist/src/root/commands/install/command.d.ts +3 -0
  60. package/dist/src/root/commands/install/command.d.ts.map +1 -0
  61. package/dist/src/root/commands/install/command.js +32 -0
  62. package/dist/src/root/commands/install/command.js.map +1 -0
  63. package/dist/src/root/commands/install/handler.d.ts +11 -0
  64. package/dist/src/root/commands/install/handler.d.ts.map +1 -0
  65. package/dist/src/root/commands/install/handler.js +31 -0
  66. package/dist/src/root/commands/install/handler.js.map +1 -0
  67. package/dist/src/root/commands/install/intent.d.ts +19 -0
  68. package/dist/src/root/commands/install/intent.d.ts.map +1 -0
  69. package/dist/src/root/commands/install/intent.js +9 -0
  70. package/dist/src/root/commands/install/intent.js.map +1 -0
  71. package/dist/src/root/commands/job-step-result.d.ts +21 -0
  72. package/dist/src/root/commands/job-step-result.d.ts.map +1 -0
  73. package/dist/src/root/commands/job-step-result.js +17 -0
  74. package/dist/src/root/commands/job-step-result.js.map +1 -0
  75. package/dist/src/root/commands/list.d.ts +7 -0
  76. package/dist/src/root/commands/list.d.ts.map +1 -0
  77. package/dist/src/root/commands/list.js +63 -0
  78. package/dist/src/root/commands/list.js.map +1 -0
  79. package/dist/src/root/commands/new.d.ts +19 -0
  80. package/dist/src/root/commands/new.d.ts.map +1 -0
  81. package/dist/src/root/commands/new.js +111 -0
  82. package/dist/src/root/commands/new.js.map +1 -0
  83. package/dist/src/root/commands/preview-sections.d.ts +11 -0
  84. package/dist/src/root/commands/preview-sections.d.ts.map +1 -0
  85. package/dist/src/root/commands/preview-sections.js +25 -0
  86. package/dist/src/root/commands/preview-sections.js.map +1 -0
  87. package/dist/src/root/commands/publish.d.ts +20 -0
  88. package/dist/src/root/commands/publish.d.ts.map +1 -0
  89. package/dist/src/root/commands/publish.js +238 -0
  90. package/dist/src/root/commands/publish.js.map +1 -0
  91. package/dist/src/root/commands/uninstall/command-actions.d.ts +31 -0
  92. package/dist/src/root/commands/uninstall/command-actions.d.ts.map +1 -0
  93. package/dist/src/root/commands/uninstall/command-actions.js +85 -0
  94. package/dist/src/root/commands/uninstall/command-actions.js.map +1 -0
  95. package/dist/src/root/commands/uninstall/command.d.ts +3 -0
  96. package/dist/src/root/commands/uninstall/command.d.ts.map +1 -0
  97. package/dist/src/root/commands/uninstall/command.js +27 -0
  98. package/dist/src/root/commands/uninstall/command.js.map +1 -0
  99. package/dist/src/root/commands/uninstall/handler.d.ts +8 -0
  100. package/dist/src/root/commands/uninstall/handler.d.ts.map +1 -0
  101. package/dist/src/root/commands/uninstall/handler.js +10 -0
  102. package/dist/src/root/commands/uninstall/handler.js.map +1 -0
  103. package/dist/src/root/commands/uninstall/intent.d.ts +15 -0
  104. package/dist/src/root/commands/uninstall/intent.d.ts.map +1 -0
  105. package/dist/src/root/commands/uninstall/intent.js +9 -0
  106. package/dist/src/root/commands/uninstall/intent.js.map +1 -0
  107. package/dist/src/root/commands/update.d.ts +18 -0
  108. package/dist/src/root/commands/update.d.ts.map +1 -0
  109. package/dist/src/root/commands/update.js +145 -0
  110. package/dist/src/root/commands/update.js.map +1 -0
  111. package/dist/src/root/discover/command.d.ts +6 -0
  112. package/dist/src/root/discover/command.d.ts.map +1 -0
  113. package/dist/src/root/discover/command.js +22 -0
  114. package/dist/src/root/discover/command.js.map +1 -0
  115. package/dist/src/root/discover/handler.d.ts +52 -0
  116. package/dist/src/root/discover/handler.d.ts.map +1 -0
  117. package/dist/src/root/discover/handler.js +102 -0
  118. package/dist/src/root/discover/handler.js.map +1 -0
  119. package/dist/src/root/doctor/command.d.ts +3 -0
  120. package/dist/src/root/doctor/command.d.ts.map +1 -0
  121. package/dist/src/root/doctor/command.js +19 -0
  122. package/dist/src/root/doctor/command.js.map +1 -0
  123. package/dist/src/root/doctor/handler.d.ts +10 -0
  124. package/dist/src/root/doctor/handler.d.ts.map +1 -0
  125. package/dist/src/root/doctor/handler.js +27 -0
  126. package/dist/src/root/doctor/handler.js.map +1 -0
  127. package/dist/src/root/doctor/render.d.ts +8 -0
  128. package/dist/src/root/doctor/render.d.ts.map +1 -0
  129. package/dist/src/root/doctor/render.js +183 -0
  130. package/dist/src/root/doctor/render.js.map +1 -0
  131. package/dist/src/root/init.d.ts +10 -0
  132. package/dist/src/root/init.d.ts.map +1 -0
  133. package/dist/src/root/init.js +133 -0
  134. package/dist/src/root/init.js.map +1 -0
  135. package/dist/src/root/install/command.d.ts +3 -0
  136. package/dist/src/root/install/command.d.ts.map +1 -0
  137. package/dist/src/root/install/command.js +32 -0
  138. package/dist/src/root/install/command.js.map +1 -0
  139. package/dist/src/root/install/handler.d.ts +17 -0
  140. package/dist/src/root/install/handler.d.ts.map +1 -0
  141. package/dist/src/root/install/handler.js +62 -0
  142. package/dist/src/root/install/handler.js.map +1 -0
  143. package/dist/src/root/install/resolve-root-install-intent.d.ts +16 -0
  144. package/dist/src/root/install/resolve-root-install-intent.d.ts.map +1 -0
  145. package/dist/src/root/install/resolve-root-install-intent.js +75 -0
  146. package/dist/src/root/install/resolve-root-install-intent.js.map +1 -0
  147. package/dist/src/root/install/workspace-install-handler.d.ts +23 -0
  148. package/dist/src/root/install/workspace-install-handler.d.ts.map +1 -0
  149. package/dist/src/root/install/workspace-install-handler.js +52 -0
  150. package/dist/src/root/install/workspace-install-handler.js.map +1 -0
  151. package/dist/src/root/install/workspace-install.d.ts +38 -0
  152. package/dist/src/root/install/workspace-install.d.ts.map +1 -0
  153. package/dist/src/root/install/workspace-install.js +160 -0
  154. package/dist/src/root/install/workspace-install.js.map +1 -0
  155. package/dist/src/root/mcp-servers/_mcp-servers.d.ts +3 -0
  156. package/dist/src/root/mcp-servers/_mcp-servers.d.ts.map +1 -0
  157. package/dist/src/root/mcp-servers/_mcp-servers.js +14 -0
  158. package/dist/src/root/mcp-servers/_mcp-servers.js.map +1 -0
  159. package/dist/src/root/mcp-servers/install/command-actions.d.ts +48 -0
  160. package/dist/src/root/mcp-servers/install/command-actions.d.ts.map +1 -0
  161. package/dist/src/root/mcp-servers/install/command-actions.js +185 -0
  162. package/dist/src/root/mcp-servers/install/command-actions.js.map +1 -0
  163. package/dist/src/root/mcp-servers/install/command.d.ts +3 -0
  164. package/dist/src/root/mcp-servers/install/command.d.ts.map +1 -0
  165. package/dist/src/root/mcp-servers/install/command.js +32 -0
  166. package/dist/src/root/mcp-servers/install/command.js.map +1 -0
  167. package/dist/src/root/mcp-servers/install/handler.d.ts +13 -0
  168. package/dist/src/root/mcp-servers/install/handler.d.ts.map +1 -0
  169. package/dist/src/root/mcp-servers/install/handler.js +22 -0
  170. package/dist/src/root/mcp-servers/install/handler.js.map +1 -0
  171. package/dist/src/root/mcp-servers/install/intent.d.ts +18 -0
  172. package/dist/src/root/mcp-servers/install/intent.d.ts.map +1 -0
  173. package/dist/src/root/mcp-servers/install/intent.js +9 -0
  174. package/dist/src/root/mcp-servers/install/intent.js.map +1 -0
  175. package/dist/src/root/mcp-servers/uninstall/command-actions.d.ts +31 -0
  176. package/dist/src/root/mcp-servers/uninstall/command-actions.d.ts.map +1 -0
  177. package/dist/src/root/mcp-servers/uninstall/command-actions.js +68 -0
  178. package/dist/src/root/mcp-servers/uninstall/command-actions.js.map +1 -0
  179. package/dist/src/root/mcp-servers/uninstall/command.d.ts +3 -0
  180. package/dist/src/root/mcp-servers/uninstall/command.d.ts.map +1 -0
  181. package/dist/src/root/mcp-servers/uninstall/command.js +27 -0
  182. package/dist/src/root/mcp-servers/uninstall/command.js.map +1 -0
  183. package/dist/src/root/mcp-servers/uninstall/handler.d.ts +8 -0
  184. package/dist/src/root/mcp-servers/uninstall/handler.d.ts.map +1 -0
  185. package/dist/src/root/mcp-servers/uninstall/handler.js +10 -0
  186. package/dist/src/root/mcp-servers/uninstall/handler.js.map +1 -0
  187. package/dist/src/root/mcp-servers/uninstall/intent.d.ts +15 -0
  188. package/dist/src/root/mcp-servers/uninstall/intent.d.ts.map +1 -0
  189. package/dist/src/root/mcp-servers/uninstall/intent.js +9 -0
  190. package/dist/src/root/mcp-servers/uninstall/intent.js.map +1 -0
  191. package/dist/src/root/packs/_packs.d.ts +3 -0
  192. package/dist/src/root/packs/_packs.d.ts.map +1 -0
  193. package/dist/src/root/packs/_packs.js +35 -0
  194. package/dist/src/root/packs/_packs.js.map +1 -0
  195. package/dist/src/root/packs/add.d.ts +16 -0
  196. package/dist/src/root/packs/add.d.ts.map +1 -0
  197. package/dist/src/root/packs/add.js +198 -0
  198. package/dist/src/root/packs/add.js.map +1 -0
  199. package/dist/src/root/packs/install/command-actions.d.ts +56 -0
  200. package/dist/src/root/packs/install/command-actions.d.ts.map +1 -0
  201. package/dist/src/root/packs/install/command-actions.js +373 -0
  202. package/dist/src/root/packs/install/command-actions.js.map +1 -0
  203. package/dist/src/root/packs/install/command.d.ts +3 -0
  204. package/dist/src/root/packs/install/command.d.ts.map +1 -0
  205. package/dist/src/root/packs/install/command.js +36 -0
  206. package/dist/src/root/packs/install/command.js.map +1 -0
  207. package/dist/src/root/packs/install/handler.d.ts +13 -0
  208. package/dist/src/root/packs/install/handler.d.ts.map +1 -0
  209. package/dist/src/root/packs/install/handler.js +22 -0
  210. package/dist/src/root/packs/install/handler.js.map +1 -0
  211. package/dist/src/root/packs/install/intent.d.ts +15 -0
  212. package/dist/src/root/packs/install/intent.d.ts.map +1 -0
  213. package/dist/src/root/packs/install/intent.js +9 -0
  214. package/dist/src/root/packs/install/intent.js.map +1 -0
  215. package/dist/src/root/packs/install/plan.d.ts +63 -0
  216. package/dist/src/root/packs/install/plan.d.ts.map +1 -0
  217. package/dist/src/root/packs/install/plan.js +181 -0
  218. package/dist/src/root/packs/install/plan.js.map +1 -0
  219. package/dist/src/root/packs/new.d.ts +18 -0
  220. package/dist/src/root/packs/new.d.ts.map +1 -0
  221. package/dist/src/root/packs/new.js +103 -0
  222. package/dist/src/root/packs/new.js.map +1 -0
  223. package/dist/src/root/packs/publish.d.ts +30 -0
  224. package/dist/src/root/packs/publish.d.ts.map +1 -0
  225. package/dist/src/root/packs/publish.js +288 -0
  226. package/dist/src/root/packs/publish.js.map +1 -0
  227. package/dist/src/root/packs/remove.d.ts +16 -0
  228. package/dist/src/root/packs/remove.d.ts.map +1 -0
  229. package/dist/src/root/packs/remove.js +156 -0
  230. package/dist/src/root/packs/remove.js.map +1 -0
  231. package/dist/src/root/packs/uninstall/command-actions.d.ts +47 -0
  232. package/dist/src/root/packs/uninstall/command-actions.d.ts.map +1 -0
  233. package/dist/src/root/packs/uninstall/command-actions.js +175 -0
  234. package/dist/src/root/packs/uninstall/command-actions.js.map +1 -0
  235. package/dist/src/root/packs/uninstall/command.d.ts +3 -0
  236. package/dist/src/root/packs/uninstall/command.d.ts.map +1 -0
  237. package/dist/src/root/packs/uninstall/command.js +31 -0
  238. package/dist/src/root/packs/uninstall/command.js.map +1 -0
  239. package/dist/src/root/packs/uninstall/handler.d.ts +8 -0
  240. package/dist/src/root/packs/uninstall/handler.d.ts.map +1 -0
  241. package/dist/src/root/packs/uninstall/handler.js +10 -0
  242. package/dist/src/root/packs/uninstall/handler.js.map +1 -0
  243. package/dist/src/root/packs/uninstall/intent.d.ts +13 -0
  244. package/dist/src/root/packs/uninstall/intent.d.ts.map +1 -0
  245. package/dist/src/root/packs/uninstall/intent.js +10 -0
  246. package/dist/src/root/packs/uninstall/intent.js.map +1 -0
  247. package/dist/src/root/packs/uninstall/plan.d.ts +60 -0
  248. package/dist/src/root/packs/uninstall/plan.d.ts.map +1 -0
  249. package/dist/src/root/packs/uninstall/plan.js +166 -0
  250. package/dist/src/root/packs/uninstall/plan.js.map +1 -0
  251. package/dist/src/root/packs/unpack/command.d.ts +3 -0
  252. package/dist/src/root/packs/unpack/command.d.ts.map +1 -0
  253. package/dist/src/root/packs/unpack/command.js +31 -0
  254. package/dist/src/root/packs/unpack/command.js.map +1 -0
  255. package/dist/src/root/packs/unpack/handler.d.ts +16 -0
  256. package/dist/src/root/packs/unpack/handler.d.ts.map +1 -0
  257. package/dist/src/root/packs/unpack/handler.js +117 -0
  258. package/dist/src/root/packs/unpack/handler.js.map +1 -0
  259. package/dist/src/root/packs/unpack/plan.d.ts +72 -0
  260. package/dist/src/root/packs/unpack/plan.d.ts.map +1 -0
  261. package/dist/src/root/packs/unpack/plan.js +120 -0
  262. package/dist/src/root/packs/unpack/plan.js.map +1 -0
  263. package/dist/src/root/shared/registry-install-target.d.ts +35 -0
  264. package/dist/src/root/shared/registry-install-target.d.ts.map +1 -0
  265. package/dist/src/root/shared/registry-install-target.js +66 -0
  266. package/dist/src/root/shared/registry-install-target.js.map +1 -0
  267. package/dist/src/root/skills/_skills.d.ts +3 -0
  268. package/dist/src/root/skills/_skills.d.ts.map +1 -0
  269. package/dist/src/root/skills/_skills.js +38 -0
  270. package/dist/src/root/skills/_skills.js.map +1 -0
  271. package/dist/src/root/skills/disable.d.ts +15 -0
  272. package/dist/src/root/skills/disable.d.ts.map +1 -0
  273. package/dist/src/root/skills/disable.js +91 -0
  274. package/dist/src/root/skills/disable.js.map +1 -0
  275. package/dist/src/root/skills/enable.d.ts +16 -0
  276. package/dist/src/root/skills/enable.d.ts.map +1 -0
  277. package/dist/src/root/skills/enable.js +92 -0
  278. package/dist/src/root/skills/enable.js.map +1 -0
  279. package/dist/src/root/skills/fork.d.ts +22 -0
  280. package/dist/src/root/skills/fork.d.ts.map +1 -0
  281. package/dist/src/root/skills/fork.js +288 -0
  282. package/dist/src/root/skills/fork.js.map +1 -0
  283. package/dist/src/root/skills/install/command-actions.d.ts +76 -0
  284. package/dist/src/root/skills/install/command-actions.d.ts.map +1 -0
  285. package/dist/src/root/skills/install/command-actions.js +323 -0
  286. package/dist/src/root/skills/install/command-actions.js.map +1 -0
  287. package/dist/src/root/skills/install/command.d.ts +3 -0
  288. package/dist/src/root/skills/install/command.d.ts.map +1 -0
  289. package/dist/src/root/skills/install/command.js +46 -0
  290. package/dist/src/root/skills/install/command.js.map +1 -0
  291. package/dist/src/root/skills/install/handler.d.ts +15 -0
  292. package/dist/src/root/skills/install/handler.d.ts.map +1 -0
  293. package/dist/src/root/skills/install/handler.js +39 -0
  294. package/dist/src/root/skills/install/handler.js.map +1 -0
  295. package/dist/src/root/skills/install/intent.d.ts +21 -0
  296. package/dist/src/root/skills/install/intent.d.ts.map +1 -0
  297. package/dist/src/root/skills/install/intent.js +7 -0
  298. package/dist/src/root/skills/install/intent.js.map +1 -0
  299. package/dist/src/root/skills/install/plan.d.ts +43 -0
  300. package/dist/src/root/skills/install/plan.d.ts.map +1 -0
  301. package/dist/src/root/skills/install/plan.js +82 -0
  302. package/dist/src/root/skills/install/plan.js.map +1 -0
  303. package/dist/src/root/skills/install/resolve-skill-install-source.d.ts +17 -0
  304. package/dist/src/root/skills/install/resolve-skill-install-source.d.ts.map +1 -0
  305. package/dist/src/root/skills/install/resolve-skill-install-source.js +271 -0
  306. package/dist/src/root/skills/install/resolve-skill-install-source.js.map +1 -0
  307. package/dist/src/root/skills/install/select-skills.d.ts +37 -0
  308. package/dist/src/root/skills/install/select-skills.d.ts.map +1 -0
  309. package/dist/src/root/skills/install/select-skills.js +91 -0
  310. package/dist/src/root/skills/install/select-skills.js.map +1 -0
  311. package/dist/src/root/skills/list.d.ts +10 -0
  312. package/dist/src/root/skills/list.d.ts.map +1 -0
  313. package/dist/src/root/skills/list.js +68 -0
  314. package/dist/src/root/skills/list.js.map +1 -0
  315. package/dist/src/root/skills/new.d.ts +19 -0
  316. package/dist/src/root/skills/new.d.ts.map +1 -0
  317. package/dist/src/root/skills/new.js +113 -0
  318. package/dist/src/root/skills/new.js.map +1 -0
  319. package/dist/src/root/skills/publish.d.ts +20 -0
  320. package/dist/src/root/skills/publish.d.ts.map +1 -0
  321. package/dist/src/root/skills/publish.js +230 -0
  322. package/dist/src/root/skills/publish.js.map +1 -0
  323. package/dist/src/root/skills/rename.d.ts +16 -0
  324. package/dist/src/root/skills/rename.d.ts.map +1 -0
  325. package/dist/src/root/skills/rename.js +84 -0
  326. package/dist/src/root/skills/rename.js.map +1 -0
  327. package/dist/src/root/skills/uninstall/command-actions.d.ts +39 -0
  328. package/dist/src/root/skills/uninstall/command-actions.d.ts.map +1 -0
  329. package/dist/src/root/skills/uninstall/command-actions.js +85 -0
  330. package/dist/src/root/skills/uninstall/command-actions.js.map +1 -0
  331. package/dist/src/root/skills/uninstall/command.d.ts +3 -0
  332. package/dist/src/root/skills/uninstall/command.d.ts.map +1 -0
  333. package/dist/src/root/skills/uninstall/command.js +24 -0
  334. package/dist/src/root/skills/uninstall/command.js.map +1 -0
  335. package/dist/src/root/skills/uninstall/handler.d.ts +8 -0
  336. package/dist/src/root/skills/uninstall/handler.d.ts.map +1 -0
  337. package/dist/src/root/skills/uninstall/handler.js +10 -0
  338. package/dist/src/root/skills/uninstall/handler.js.map +1 -0
  339. package/dist/src/root/skills/uninstall/intent.d.ts +17 -0
  340. package/dist/src/root/skills/uninstall/intent.d.ts.map +1 -0
  341. package/dist/src/root/skills/uninstall/intent.js +7 -0
  342. package/dist/src/root/skills/uninstall/intent.js.map +1 -0
  343. package/dist/src/root/skills/uninstall/plan.d.ts +35 -0
  344. package/dist/src/root/skills/uninstall/plan.d.ts.map +1 -0
  345. package/dist/src/root/skills/uninstall/plan.js +66 -0
  346. package/dist/src/root/skills/uninstall/plan.js.map +1 -0
  347. package/dist/src/root/skills/update/command.d.ts +3 -0
  348. package/dist/src/root/skills/update/command.d.ts.map +1 -0
  349. package/dist/src/root/skills/update/command.js +31 -0
  350. package/dist/src/root/skills/update/command.js.map +1 -0
  351. package/dist/src/root/skills/update/constraint-resolution.d.ts +70 -0
  352. package/dist/src/root/skills/update/constraint-resolution.d.ts.map +1 -0
  353. package/dist/src/root/skills/update/constraint-resolution.js +94 -0
  354. package/dist/src/root/skills/update/constraint-resolution.js.map +1 -0
  355. package/dist/src/root/skills/update/handler.d.ts +18 -0
  356. package/dist/src/root/skills/update/handler.d.ts.map +1 -0
  357. package/dist/src/root/skills/update/handler.js +409 -0
  358. package/dist/src/root/skills/update/handler.js.map +1 -0
  359. package/dist/src/root/skills/update/plan.d.ts +35 -0
  360. package/dist/src/root/skills/update/plan.d.ts.map +1 -0
  361. package/dist/src/root/skills/update/plan.js +92 -0
  362. package/dist/src/root/skills/update/plan.js.map +1 -0
  363. package/dist/src/root/subagents/_subagents.d.ts +3 -0
  364. package/dist/src/root/subagents/_subagents.d.ts.map +1 -0
  365. package/dist/src/root/subagents/_subagents.js +31 -0
  366. package/dist/src/root/subagents/_subagents.js.map +1 -0
  367. package/dist/src/root/subagents/disable/command.d.ts +3 -0
  368. package/dist/src/root/subagents/disable/command.d.ts.map +1 -0
  369. package/dist/src/root/subagents/disable/command.js +24 -0
  370. package/dist/src/root/subagents/disable/command.js.map +1 -0
  371. package/dist/src/root/subagents/disable/handler.d.ts +14 -0
  372. package/dist/src/root/subagents/disable/handler.d.ts.map +1 -0
  373. package/dist/src/root/subagents/disable/handler.js +71 -0
  374. package/dist/src/root/subagents/disable/handler.js.map +1 -0
  375. package/dist/src/root/subagents/enable/command.d.ts +3 -0
  376. package/dist/src/root/subagents/enable/command.d.ts.map +1 -0
  377. package/dist/src/root/subagents/enable/command.js +24 -0
  378. package/dist/src/root/subagents/enable/command.js.map +1 -0
  379. package/dist/src/root/subagents/enable/handler.d.ts +14 -0
  380. package/dist/src/root/subagents/enable/handler.d.ts.map +1 -0
  381. package/dist/src/root/subagents/enable/handler.js +71 -0
  382. package/dist/src/root/subagents/enable/handler.js.map +1 -0
  383. package/dist/src/root/subagents/install/command-actions.d.ts +58 -0
  384. package/dist/src/root/subagents/install/command-actions.d.ts.map +1 -0
  385. package/dist/src/root/subagents/install/command-actions.js +258 -0
  386. package/dist/src/root/subagents/install/command-actions.js.map +1 -0
  387. package/dist/src/root/subagents/install/command.d.ts +3 -0
  388. package/dist/src/root/subagents/install/command.d.ts.map +1 -0
  389. package/dist/src/root/subagents/install/command.js +46 -0
  390. package/dist/src/root/subagents/install/command.js.map +1 -0
  391. package/dist/src/root/subagents/install/handler.d.ts +15 -0
  392. package/dist/src/root/subagents/install/handler.d.ts.map +1 -0
  393. package/dist/src/root/subagents/install/handler.js +39 -0
  394. package/dist/src/root/subagents/install/handler.js.map +1 -0
  395. package/dist/src/root/subagents/install/intent.d.ts +21 -0
  396. package/dist/src/root/subagents/install/intent.d.ts.map +1 -0
  397. package/dist/src/root/subagents/install/intent.js +7 -0
  398. package/dist/src/root/subagents/install/intent.js.map +1 -0
  399. package/dist/src/root/subagents/install/plan.d.ts +44 -0
  400. package/dist/src/root/subagents/install/plan.d.ts.map +1 -0
  401. package/dist/src/root/subagents/install/plan.js +74 -0
  402. package/dist/src/root/subagents/install/plan.js.map +1 -0
  403. package/dist/src/root/subagents/install/resolve-subagent-install-source.d.ts +17 -0
  404. package/dist/src/root/subagents/install/resolve-subagent-install-source.d.ts.map +1 -0
  405. package/dist/src/root/subagents/install/resolve-subagent-install-source.js +265 -0
  406. package/dist/src/root/subagents/install/resolve-subagent-install-source.js.map +1 -0
  407. package/dist/src/root/subagents/install/select-subagents.d.ts +43 -0
  408. package/dist/src/root/subagents/install/select-subagents.d.ts.map +1 -0
  409. package/dist/src/root/subagents/install/select-subagents.js +90 -0
  410. package/dist/src/root/subagents/install/select-subagents.js.map +1 -0
  411. package/dist/src/root/subagents/list/command.d.ts +3 -0
  412. package/dist/src/root/subagents/list/command.d.ts.map +1 -0
  413. package/dist/src/root/subagents/list/command.js +21 -0
  414. package/dist/src/root/subagents/list/command.js.map +1 -0
  415. package/dist/src/root/subagents/list/handler.d.ts +8 -0
  416. package/dist/src/root/subagents/list/handler.d.ts.map +1 -0
  417. package/dist/src/root/subagents/list/handler.js +56 -0
  418. package/dist/src/root/subagents/list/handler.js.map +1 -0
  419. package/dist/src/root/subagents/new/command.d.ts +3 -0
  420. package/dist/src/root/subagents/new/command.d.ts.map +1 -0
  421. package/dist/src/root/subagents/new/command.js +42 -0
  422. package/dist/src/root/subagents/new/command.js.map +1 -0
  423. package/dist/src/root/subagents/new/handler.d.ts +21 -0
  424. package/dist/src/root/subagents/new/handler.d.ts.map +1 -0
  425. package/dist/src/root/subagents/new/handler.js +199 -0
  426. package/dist/src/root/subagents/new/handler.js.map +1 -0
  427. package/dist/src/root/subagents/publish/command.d.ts +3 -0
  428. package/dist/src/root/subagents/publish/command.d.ts.map +1 -0
  429. package/dist/src/root/subagents/publish/command.js +28 -0
  430. package/dist/src/root/subagents/publish/command.js.map +1 -0
  431. package/dist/src/root/subagents/publish/handler.d.ts +18 -0
  432. package/dist/src/root/subagents/publish/handler.d.ts.map +1 -0
  433. package/dist/src/root/subagents/publish/handler.js +204 -0
  434. package/dist/src/root/subagents/publish/handler.js.map +1 -0
  435. package/dist/src/root/subagents/rename/command.d.ts +3 -0
  436. package/dist/src/root/subagents/rename/command.d.ts.map +1 -0
  437. package/dist/src/root/subagents/rename/command.js +25 -0
  438. package/dist/src/root/subagents/rename/command.js.map +1 -0
  439. package/dist/src/root/subagents/rename/handler.d.ts +15 -0
  440. package/dist/src/root/subagents/rename/handler.d.ts.map +1 -0
  441. package/dist/src/root/subagents/rename/handler.js +174 -0
  442. package/dist/src/root/subagents/rename/handler.js.map +1 -0
  443. package/dist/src/root/subagents/uninstall/command-actions.d.ts +39 -0
  444. package/dist/src/root/subagents/uninstall/command-actions.d.ts.map +1 -0
  445. package/dist/src/root/subagents/uninstall/command-actions.js +85 -0
  446. package/dist/src/root/subagents/uninstall/command-actions.js.map +1 -0
  447. package/dist/src/root/subagents/uninstall/command.d.ts +3 -0
  448. package/dist/src/root/subagents/uninstall/command.d.ts.map +1 -0
  449. package/dist/src/root/subagents/uninstall/command.js +27 -0
  450. package/dist/src/root/subagents/uninstall/command.js.map +1 -0
  451. package/dist/src/root/subagents/uninstall/handler.d.ts +8 -0
  452. package/dist/src/root/subagents/uninstall/handler.d.ts.map +1 -0
  453. package/dist/src/root/subagents/uninstall/handler.js +10 -0
  454. package/dist/src/root/subagents/uninstall/handler.js.map +1 -0
  455. package/dist/src/root/subagents/uninstall/intent.d.ts +17 -0
  456. package/dist/src/root/subagents/uninstall/intent.d.ts.map +1 -0
  457. package/dist/src/root/subagents/uninstall/intent.js +7 -0
  458. package/dist/src/root/subagents/uninstall/intent.js.map +1 -0
  459. package/dist/src/root/subagents/update/command.d.ts +3 -0
  460. package/dist/src/root/subagents/update/command.d.ts.map +1 -0
  461. package/dist/src/root/subagents/update/command.js +41 -0
  462. package/dist/src/root/subagents/update/command.js.map +1 -0
  463. package/dist/src/root/subagents/update/handler.d.ts +16 -0
  464. package/dist/src/root/subagents/update/handler.d.ts.map +1 -0
  465. package/dist/src/root/subagents/update/handler.js +188 -0
  466. package/dist/src/root/subagents/update/handler.js.map +1 -0
  467. package/dist/src/root/subagents/update/plan.d.ts +39 -0
  468. package/dist/src/root/subagents/update/plan.d.ts.map +1 -0
  469. package/dist/src/root/subagents/update/plan.js +81 -0
  470. package/dist/src/root/subagents/update/plan.js.map +1 -0
  471. package/dist/src/root/sync.d.ts +15 -0
  472. package/dist/src/root/sync.d.ts.map +1 -0
  473. package/dist/src/root/sync.js +82 -0
  474. package/dist/src/root/sync.js.map +1 -0
  475. package/dist/src/root/upgrade/handler.d.ts +21 -0
  476. package/dist/src/root/upgrade/handler.d.ts.map +1 -0
  477. package/dist/src/root/upgrade/handler.js +303 -0
  478. package/dist/src/root/upgrade/handler.js.map +1 -0
  479. package/dist/src/root/upgrade/upgrade.d.ts +3 -0
  480. package/dist/src/root/upgrade/upgrade.d.ts.map +1 -0
  481. package/dist/src/root/upgrade/upgrade.js +18 -0
  482. package/dist/src/root/upgrade/upgrade.js.map +1 -0
  483. package/dist/src/runtime.d.ts +39 -0
  484. package/dist/src/runtime.d.ts.map +1 -0
  485. package/dist/src/runtime.js +144 -0
  486. package/dist/src/runtime.js.map +1 -0
  487. package/dist/src/test-helpers.d.ts +101 -0
  488. package/dist/src/test-helpers.d.ts.map +1 -0
  489. package/dist/src/test-helpers.js +153 -0
  490. package/dist/src/test-helpers.js.map +1 -0
  491. package/dist/src/test-stubs.d.ts +128 -0
  492. package/dist/src/test-stubs.d.ts.map +1 -0
  493. package/dist/src/test-stubs.js +227 -0
  494. package/dist/src/test-stubs.js.map +1 -0
  495. package/dist/src/update-check-startup.d.ts +68 -0
  496. package/dist/src/update-check-startup.d.ts.map +1 -0
  497. package/dist/src/update-check-startup.js +127 -0
  498. package/dist/src/update-check-startup.js.map +1 -0
  499. package/dist/src/version.d.ts +2 -0
  500. package/dist/src/version.d.ts.map +1 -0
  501. package/dist/src/version.js +23 -0
  502. package/dist/src/version.js.map +1 -0
  503. package/package.json +96 -0
@@ -0,0 +1,82 @@
1
+ import * as FileSystem from "effect/FileSystem";
2
+ import * as Path from "effect/Path";
3
+ import * as Effect from "effect/Effect";
4
+ import * as Option from "effect/Option";
5
+ import { Command, Flag } from "effect/unstable/cli";
6
+ import { CodingAgentRepository } from "@agentxm/client-core/unstable/agents";
7
+ import { previewFlag, yesFlag } from "@agentxm/client-core/unstable/cli-flags";
8
+ import { CliRenderer } from "@agentxm/client-core/unstable/cli-renderer";
9
+ import { withArgvTracking } from "@agentxm/client-core/unstable/cli-runtime";
10
+ import { SourceHostProviders } from "@agentxm/client-core/unstable/source-resolution";
11
+ import { formatWorkspaceSyncBlockersHowToFix, getWorkspaceSyncReadiness, syncWorkspace, previewOrApplyPlan, Workspace, } from "@agentxm/client-core/unstable/workspace";
12
+ import { emitPlanResolutionResult } from "../json-output.js";
13
+ import { scopeFlag } from "../cli-flags.js";
14
+ import { withRuntime, withWorkspace } from "../runtime.js";
15
+ import { buildWorkspaceInstallPlan } from "./install/workspace-install.js";
16
+ const formatEntryCount = (entryCount) => entryCount === 1 ? "1 entry" : `${entryCount} entries`;
17
+ const flattenPlanSteps = (plan) => plan.jobs.flatMap((job) => job.steps);
18
+ const makeSyncPlan = (steps) => ({
19
+ _tag: "Plan",
20
+ name: "Sync workspace",
21
+ description: Option.some("Synchronize managed workspace state from settings.json"),
22
+ jobs: [{ concurrency: 1, steps }],
23
+ });
24
+ export const handleSync = Effect.fn("Sync.handle")(function* (args) {
25
+ const renderer = yield* CliRenderer;
26
+ const ws = yield* Workspace;
27
+ const fs = yield* FileSystem.FileSystem;
28
+ const path = yield* Path.Path;
29
+ const sources = yield* SourceHostProviders;
30
+ const agentRepo = yield* CodingAgentRepository;
31
+ const syncReadiness = yield* getWorkspaceSyncReadiness();
32
+ const syncStep = {
33
+ readiness: "ready",
34
+ label: "Managed extensions and axm-lock.yaml",
35
+ run: syncWorkspace().pipe(Effect.map((entryCount) => ({
36
+ result: "success",
37
+ message: `Synchronized managed workspace state (${formatEntryCount(entryCount)} in axm-lock.yaml)`,
38
+ })), Effect.provideService(Workspace, ws), Effect.provideService(FileSystem.FileSystem, fs), Effect.provideService(Path.Path, path), Effect.provideService(SourceHostProviders, sources), Effect.provideService(CodingAgentRepository, agentRepo), Effect.scoped),
39
+ };
40
+ const plan = syncReadiness.canSync
41
+ ? yield* Effect.gen(function* () {
42
+ const installPlanResult = yield* buildWorkspaceInstallPlan({
43
+ type: Option.none(),
44
+ planName: "Install configured extensions",
45
+ planDescription: Option.some("Install configured workspace extensions"),
46
+ });
47
+ const installSteps = installPlanResult._tag === "WorkspaceInstallPlan"
48
+ ? flattenPlanSteps(installPlanResult.plan)
49
+ : [];
50
+ return makeSyncPlan([...installSteps, syncStep]);
51
+ })
52
+ : makeSyncPlan(syncReadiness.blockers.map((blocker) => ({
53
+ readiness: "error",
54
+ label: `${blocker.subject.kind}:${blocker.subject.ref}`,
55
+ errorMessage: blocker.message,
56
+ })));
57
+ yield* renderer.info("axm sync");
58
+ const resolution = yield* previewOrApplyPlan(plan, {
59
+ yes: args.yes,
60
+ force: false,
61
+ preview: args.preview,
62
+ ...(syncReadiness.canSync
63
+ ? {}
64
+ : {
65
+ blockedByErrorsHowToFix: formatWorkspaceSyncBlockersHowToFix(syncReadiness.blockers),
66
+ }),
67
+ });
68
+ yield* emitPlanResolutionResult("sync", resolution);
69
+ if (resolution._tag === "ExecutedPlan") {
70
+ yield* renderer.success("Done");
71
+ }
72
+ });
73
+ const syncConfig = {
74
+ scope: scopeFlag.pipe(Flag.withDescription("Sync the project (default) or user-level workspace")),
75
+ yes: yesFlag.pipe(Flag.withDescription("Apply previewed sync changes without prompting")),
76
+ preview: previewFlag.pipe(Flag.withDescription("Show what would be synchronized without modifying the workspace")),
77
+ };
78
+ export const syncCommand = Command.make("sync", syncConfig, ({ scope, yes, preview }) => handleSync({ yes, preview }).pipe(withWorkspace(scope), withRuntime("sync"))).pipe(withArgvTracking(syncConfig), Command.withDescription("Synchronize managed workspace state from settings.json"), Command.withExamples([
79
+ { command: "axm sync", description: "Synchronize managed workspace state from settings.json" },
80
+ { command: "axm sync --preview", description: "Preview workspace synchronization" },
81
+ ]));
82
+ //# sourceMappingURL=sync.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sync.js","sourceRoot":"","sources":["../../../src/root/sync.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,UAAU,MAAM,mBAAmB,CAAC;AAChD,OAAO,KAAK,IAAI,MAAM,aAAa,CAAC;AACpC,OAAO,KAAK,MAAM,MAAM,eAAe,CAA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CAAC,wBAAwB,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC;IAEpD,IAAI,UAAU,CAAC,IAAI,KAAK,cAAc,EAAE,CAAC;QACvC,KAAK,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;IAClC,CAAC;AACH,CAAC,CAAC,CAAC;AAEH,MAAM,UAAU,GAAG;IACjB,KAAK,EAAE,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,eAAe,CAAC,oDAAoD,CAAC,CAAC;IACjG,GAAG,EAAE,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,eAAe,CAAC,gDAAgD,CAAC,CAAC;IACzF,OAAO,EAAE,WAAW,CAAC,IAAI,CACvB,IAAI,CAAC,eAAe,CAAC,iEAAiE,CAAC,CACxF;CACO,CAAC;AAEX,MAAM,CAAC,MAAM,WAAW,GAAG,OAAO,CAAC,IAAI,CAAC,MAAM,EAAE,UAAU,EAAE,CAAC,EAAE,KAAK,EAAE,GAAG,EAAE,OAAO,EAAE,EAAE,EAAE,CACtF,UAAU,CAAC,EAAE,GAAG,EAAE,OAAO,EAAE,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC,CAC7E,CAAC,IAAI,CACJ,gBAAgB,CAAC,UAAU,CAAC,EAC5B,OAAO,CAAC,eAAe,CAAC,wDAAwD,CAAC,EACjF,OAAO,CAAC,YAAY,CAAC;IACnB,EAAE,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,wDAAwD,EAAE;IAC9F,EAAE,OAAO,EAAE,oBAAoB,EAAE,WAAW,EAAE,mCAAmC,EAAE;CACpF,CAAC,CACH,CAAC"}
@@ -0,0 +1,21 @@
1
+ import * as Effect from "effect/Effect";
2
+ import * as FileSystem from "effect/FileSystem";
3
+ import * as Option from "effect/Option";
4
+ import * as Path from "effect/Path";
5
+ import * as HttpClient from "effect/unstable/http/HttpClient";
6
+ import { CliRenderer } from "@agentxm/client-core/unstable/cli-renderer";
7
+ import { InstallMeta } from "@agentxm/client-core/unstable/install-meta";
8
+ import { InstallMethod } from "@agentxm/client-core/unstable/install-method";
9
+ export interface UpgradeHandlerArgs {
10
+ readonly force: boolean;
11
+ }
12
+ interface PlatformBinaryInfo {
13
+ readonly binaryName: string;
14
+ readonly platform: string;
15
+ readonly arch: string;
16
+ }
17
+ export declare const resolvePlatformBinary: (platform: string, arch: string) => Option.Option<PlatformBinaryInfo>;
18
+ export declare const makeDownloadUrl: (repo: string, version: string, binaryName: string) => string;
19
+ export declare const handleUpgrade: (args: UpgradeHandlerArgs) => Effect.Effect<void, import("@agentxm/client-core/unstable/app-error").AppError, CliRenderer | FileSystem.FileSystem | Path.Path | HttpClient.HttpClient | InstallMethod | InstallMeta>;
20
+ export {};
21
+ //# sourceMappingURL=handler.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../../../src/root/upgrade/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,UAAU,MAAM,mBAAmB,CAAC;AAChD,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,IAAI,MAAM,aAAa,CAAC;AAEpC,OAAO,KAAK,UAAU,MAAM,iCAAiC,CAAC;AAG9D,OAAO,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AACzE,OAAO,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AACzE,OAAO,EACL,aAAa,EAEd,MAAM,8CAA8C,CAAC;AAOtD,MAAM,WAAW,kBAAkB;IACjC,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;CACzB;AAgBD,UAAU,kBAAkB;IAC1B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;CACvB;AAUD,eAAO,MAAM,qBAAqB,GAAI,UAAU,MAAM,EAAE,MAAM,MAAM,sCAMnE,CAAC;AAEF,eAAO,MAAM,eAAe,GAAI,MAAM,MAAM,EAAE,SAAS,MAAM,EAAE,YAAY,MAAM,WACH,CAAC;AAiU/E,eAAO,MAAM,aAAa,sNAyBT,CAAC"}
@@ -0,0 +1,303 @@
1
+ import * as Effect from "effect/Effect";
2
+ import * as FileSystem from "effect/FileSystem";
3
+ import * as Option from "effect/Option";
4
+ import * as Path from "effect/Path";
5
+ import * as Schema from "effect/Schema";
6
+ import * as HttpClient from "effect/unstable/http/HttpClient";
7
+ import { makeAppError } from "@agentxm/client-core/unstable/app-error";
8
+ import { CliRenderer } from "@agentxm/client-core/unstable/cli-renderer";
9
+ import { InstallMeta } from "@agentxm/client-core/unstable/install-meta";
10
+ import { InstallMethod, } from "@agentxm/client-core/unstable/install-method";
11
+ import { resolveLatestVersion, DEFAULT_GITHUB_REPO, } from "@agentxm/client-core/unstable/version-resolution";
12
+ import { loadVersion } from "../../version.js";
13
+ const UpgradeResultSchema = Schema.Struct({
14
+ status: Schema.Literals(["already-up-to-date", "reinstalled", "upgraded", "delegated"]),
15
+ installMethod: Schema.Literals(["script", "homebrew", "npm", "unknown"]),
16
+ localVersion: Schema.String,
17
+ targetVersion: Schema.optional(Schema.String),
18
+ delegatedCommand: Schema.optional(Schema.String),
19
+ force: Schema.Boolean,
20
+ });
21
+ const UpgradeDocumentFields = {
22
+ result: UpgradeResultSchema,
23
+ };
24
+ const SUPPORTED_TARGETS = [
25
+ { platform: "darwin", arch: "arm64", binaryName: "axm-darwin-arm64" },
26
+ { platform: "darwin", arch: "x64", binaryName: "axm-darwin-x64" },
27
+ { platform: "linux", arch: "arm64", binaryName: "axm-linux-arm64" },
28
+ { platform: "linux", arch: "x64", binaryName: "axm-linux-x64" },
29
+ { platform: "win32", arch: "x64", binaryName: "axm-windows-x64.exe" },
30
+ ];
31
+ export const resolvePlatformBinary = (platform, arch) => {
32
+ const target = SUPPORTED_TARGETS.find((t) => t.platform === platform && t.arch === arch);
33
+ if (target === undefined) {
34
+ return Option.none();
35
+ }
36
+ return Option.some(target);
37
+ };
38
+ export const makeDownloadUrl = (repo, version, binaryName) => `https://github.com/${repo}/releases/download/cli-v${version}/${binaryName}`;
39
+ const resolveGithubRepo = () =>
40
+ // eslint-disable-next-line no-restricted-properties -- Centralized env var access for GitHub repo override
41
+ Effect.sync(() => process.env["AXM_INSTALL_GITHUB_REPO"] ?? DEFAULT_GITHUB_REPO);
42
+ const fetchBinaryResponse = (httpClient, url) => httpClient
43
+ .get(url, {
44
+ headers: {
45
+ Accept: "application/octet-stream",
46
+ "User-Agent": "axm-cli",
47
+ },
48
+ })
49
+ .pipe(Effect.mapError((cause) => makeAppError({
50
+ code: "UPGRADE_DOWNLOAD_FAILED",
51
+ what: "Failed to download update",
52
+ howToFix: "Check your network connection and try again.",
53
+ cause,
54
+ })), Effect.timeoutOrElse({
55
+ duration: "60 seconds",
56
+ orElse: () => Effect.fail(makeAppError({
57
+ code: "UPGRADE_DOWNLOAD_TIMEOUT",
58
+ what: "Download timed out",
59
+ howToFix: "Check your network connection and try again.",
60
+ })),
61
+ }));
62
+ const downloadBinary = (httpClient, url, destPath) => Effect.gen(function* () {
63
+ const fs = yield* FileSystem.FileSystem;
64
+ const response = yield* fetchBinaryResponse(httpClient, url);
65
+ if (response.status !== 200) {
66
+ return yield* makeAppError({
67
+ code: "UPGRADE_DOWNLOAD_FAILED",
68
+ what: `Download failed with status ${String(response.status)}`,
69
+ howToFix: "Check your network connection and try again.",
70
+ });
71
+ }
72
+ const body = yield* response.arrayBuffer.pipe(Effect.mapError((cause) => makeAppError({
73
+ code: "UPGRADE_DOWNLOAD_FAILED",
74
+ what: "Failed to read downloaded data",
75
+ howToFix: "Check your network connection and try again.",
76
+ cause,
77
+ })));
78
+ const bytes = new Uint8Array(body);
79
+ if (bytes.length === 0) {
80
+ return yield* makeAppError({
81
+ code: "UPGRADE_DOWNLOAD_EMPTY",
82
+ what: "Downloaded file is empty",
83
+ howToFix: "Try again. If the problem persists, download manually.",
84
+ });
85
+ }
86
+ yield* fs.writeFile(destPath, bytes).pipe(Effect.mapError((cause) => makeAppError({
87
+ code: "UPGRADE_PERMISSION_DENIED",
88
+ what: `Permission denied writing to ${destPath}`,
89
+ howToFix: "Re-run the install script to fix permissions, or run with appropriate privileges.",
90
+ cause,
91
+ })));
92
+ });
93
+ const makeExecutable = (filePath, platform) => Effect.gen(function* () {
94
+ if (platform === "win32")
95
+ return;
96
+ const fs = yield* FileSystem.FileSystem;
97
+ yield* fs.chmod(filePath, 0o755).pipe(Effect.catch(() => Effect.void));
98
+ });
99
+ const atomicReplace = (sourcePath, targetPath, platform) => Effect.gen(function* () {
100
+ const fs = yield* FileSystem.FileSystem;
101
+ if (platform === "win32") {
102
+ // Windows: rename-aside then rename-new
103
+ const oldPath = `${targetPath}.old`;
104
+ yield* fs.rename(targetPath, oldPath).pipe(Effect.catch(() => Effect.void));
105
+ yield* fs.rename(sourcePath, targetPath).pipe(Effect.mapError((cause) => makeAppError({
106
+ code: "UPGRADE_PERMISSION_DENIED",
107
+ what: `Permission denied replacing ${targetPath}`,
108
+ howToFix: "Re-run the install script to fix permissions, or run with appropriate privileges.",
109
+ cause,
110
+ })));
111
+ }
112
+ else {
113
+ // Unix: rename over
114
+ yield* fs.rename(sourcePath, targetPath).pipe(Effect.mapError((cause) => makeAppError({
115
+ code: "UPGRADE_PERMISSION_DENIED",
116
+ what: `Permission denied replacing ${targetPath}`,
117
+ howToFix: "Re-run the install script to fix permissions, or run with appropriate privileges.",
118
+ cause,
119
+ })));
120
+ }
121
+ });
122
+ const verifyBinary = (binaryPath) => Effect.tryPromise({
123
+ try: () => new Promise((resolve, reject) => {
124
+ import("node:child_process")
125
+ .then(({ execFile }) => {
126
+ execFile(binaryPath, ["--version"], { timeout: 10_000 }, (error, stdout) => {
127
+ if (error) {
128
+ reject(error);
129
+ }
130
+ else {
131
+ resolve(stdout.trim());
132
+ }
133
+ });
134
+ })
135
+ .catch(reject);
136
+ }),
137
+ catch: () => makeAppError({
138
+ code: "UPGRADE_VERIFY_FAILED",
139
+ what: "Failed to verify new binary",
140
+ howToFix: "The upgrade may have succeeded. Try running `axm --version` to check.",
141
+ }),
142
+ });
143
+ const cleanupWindowsOld = (targetPath) => Effect.gen(function* () {
144
+ if (process.platform !== "win32")
145
+ return;
146
+ const fs = yield* FileSystem.FileSystem;
147
+ const oldPath = `${targetPath}.old`;
148
+ yield* fs.remove(oldPath).pipe(Effect.catch(() => Effect.void));
149
+ });
150
+ const handleHomebrew = (force) => Effect.gen(function* () {
151
+ const renderer = yield* CliRenderer;
152
+ const localVersion = loadVersion();
153
+ if (force) {
154
+ yield* renderer.info("--force has no effect for Homebrew installs.");
155
+ }
156
+ yield* renderer.info("Installed via Homebrew");
157
+ yield* renderer.info("Run: brew upgrade agentxm/tap/axm");
158
+ return {
159
+ status: "delegated",
160
+ installMethod: "homebrew",
161
+ localVersion,
162
+ delegatedCommand: "brew upgrade agentxm/tap/axm",
163
+ force,
164
+ };
165
+ });
166
+ const handleNpm = (force) => Effect.gen(function* () {
167
+ const renderer = yield* CliRenderer;
168
+ const localVersion = loadVersion();
169
+ if (force) {
170
+ yield* renderer.info("--force has no effect for npm installs.");
171
+ }
172
+ yield* renderer.info("Installed via npm");
173
+ yield* renderer.info("Run: npm update -g axm.sh");
174
+ return {
175
+ status: "delegated",
176
+ installMethod: "npm",
177
+ localVersion,
178
+ delegatedCommand: "npm update -g axm.sh",
179
+ force,
180
+ };
181
+ });
182
+ const handleUnknown = (force) => Effect.gen(function* () {
183
+ const renderer = yield* CliRenderer;
184
+ const localVersion = loadVersion();
185
+ if (force) {
186
+ yield* renderer.info("--force has no effect for this install method.");
187
+ }
188
+ yield* renderer.info("Install method could not be determined.");
189
+ yield* renderer.info("To install or update, run:");
190
+ yield* renderer.info(" curl -fsSL https://get.agentxm.ai | sh");
191
+ return {
192
+ status: "delegated",
193
+ installMethod: "unknown",
194
+ localVersion,
195
+ delegatedCommand: "curl -fsSL https://get.agentxm.ai | sh",
196
+ force,
197
+ };
198
+ });
199
+ const handleScript = (method, force) => Effect.gen(function* () {
200
+ const renderer = yield* CliRenderer;
201
+ const httpClient = yield* HttpClient.HttpClient;
202
+ const installMeta = yield* InstallMeta;
203
+ const pathService = yield* Path.Path;
204
+ const repo = yield* resolveGithubRepo();
205
+ const localVersion = loadVersion();
206
+ // Step 1: Resolve latest version
207
+ const resolution = yield* resolveLatestVersion(httpClient, localVersion, repo);
208
+ // Step 2: Check if up to date
209
+ if (!resolution.isStale && !force) {
210
+ yield* renderer.info(`Already up to date (${resolution.localVersion})`);
211
+ return {
212
+ status: "already-up-to-date",
213
+ installMethod: "script",
214
+ localVersion,
215
+ targetVersion: resolution.remoteVersion,
216
+ force,
217
+ };
218
+ }
219
+ // Step 3: Resolve platform binary
220
+ const platform = process.platform;
221
+ const arch = process.arch;
222
+ const binaryInfoOpt = resolvePlatformBinary(platform, arch);
223
+ if (Option.isNone(binaryInfoOpt)) {
224
+ const supported = SUPPORTED_TARGETS.map((t) => `${t.platform}-${t.arch}`).join(", ");
225
+ return yield* makeAppError({
226
+ code: "UPGRADE_UNSUPPORTED_PLATFORM",
227
+ what: `Unsupported platform: ${platform}-${arch}`,
228
+ details: [`Supported targets: ${supported}`],
229
+ howToFix: "Build from source or use a supported platform.",
230
+ });
231
+ }
232
+ const binaryInfo = binaryInfoOpt.value;
233
+ const targetVersion = resolution.remoteVersion;
234
+ if (force && !resolution.isStale) {
235
+ yield* renderer.info(`Reinstalling ${localVersion}`);
236
+ }
237
+ else {
238
+ yield* renderer.info(`Upgrading: ${localVersion} → ${targetVersion}`);
239
+ }
240
+ // Step 4: Download
241
+ const downloadUrl = makeDownloadUrl(repo, targetVersion, binaryInfo.binaryName);
242
+ const targetDir = pathService.dirname(method.execPath);
243
+ const tempPath = pathService.join(targetDir, `.axm-upgrade-${Date.now()}.tmp`);
244
+ const fs = yield* FileSystem.FileSystem;
245
+ yield* renderer.withSpinner(`Downloading ${binaryInfo.binaryName}...`, () => downloadBinary(httpClient, downloadUrl, tempPath).pipe(Effect.onInterrupt(() => fs.remove(tempPath).pipe(Effect.catch(() => Effect.void)))), { successMessage: `Downloaded ${binaryInfo.binaryName}` });
246
+ // Step 5: Make executable
247
+ yield* makeExecutable(tempPath, platform);
248
+ // Step 6: Atomic replace
249
+ yield* atomicReplace(tempPath, method.execPath, platform);
250
+ // Step 7: Verify
251
+ yield* verifyBinary(method.execPath).pipe(Effect.catch(() => renderer.warn("Could not verify new binary. Try running `axm --version` to check.")), Effect.asVoid);
252
+ // Step 8: Update install metadata
253
+ yield* installMeta.write({
254
+ method: "script",
255
+ installedAt: new Date().toISOString(),
256
+ });
257
+ // Step 9: Clean up .old file on Windows
258
+ yield* cleanupWindowsOld(method.execPath);
259
+ if (force && !resolution.isStale) {
260
+ yield* renderer.success(`Reinstalled ${targetVersion}`);
261
+ return {
262
+ status: "reinstalled",
263
+ installMethod: "script",
264
+ localVersion,
265
+ targetVersion,
266
+ force,
267
+ };
268
+ }
269
+ else {
270
+ yield* renderer.success(`Upgraded to ${targetVersion}`);
271
+ return {
272
+ status: "upgraded",
273
+ installMethod: "script",
274
+ localVersion,
275
+ targetVersion,
276
+ force,
277
+ };
278
+ }
279
+ });
280
+ export const handleUpgrade = Effect.fn("Upgrade.handle")(function* (args) {
281
+ const installMethod = yield* InstallMethod;
282
+ const renderer = yield* CliRenderer;
283
+ const method = yield* installMethod.detect();
284
+ const result = yield* (() => {
285
+ switch (method._tag) {
286
+ case "Script":
287
+ return handleScript(method, args.force);
288
+ case "Homebrew":
289
+ return handleHomebrew(args.force);
290
+ case "Npm":
291
+ return handleNpm(args.force);
292
+ case "Unknown":
293
+ return handleUnknown(args.force);
294
+ }
295
+ })();
296
+ if (yield* renderer.document("upgrade", { result }, UpgradeDocumentFields)) {
297
+ return;
298
+ }
299
+ if (result.status === "delegated") {
300
+ yield* renderer.success("Done");
301
+ }
302
+ }, Effect.asVoid);
303
+ //# sourceMappingURL=handler.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../../src/root/upgrade/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,UAAU,MAAM,mBAAmB,CAAC;AAChD,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,IAAI,MAAM,aAAa,CAAC;AACpC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,UAAU,MAAM,iCAAiC,CAAC;AAE9D,OAAO,EAAE,YAAY,EAAE,MAAM,yCAAyC,CAAC;AACvE,OAAO,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AACzE,OAAO,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AACzE,OAAO,EACL,aAAa,GAEd,MAAM,8CAA8C,CAAC;AACtD,OAAO,EACL,oBAAoB,EACpB,mBAAmB,GACpB,MAAM,kDAAkD,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAM/C,MAAM,mBAAmB,GAAG,MAAM,CAAC,MAAM,CAAC;IACxC,MAAM,EAAE,MAAM,CAAC,QAAQ,CAAC,CAAC,oBAAoB,EAAE,aAAa,EAAE,UAAU,EAAE,WAAW,CAAU,CAAC;IAChG,aAAa,EAAE,MAAM,CAAC,QAAQ,CAAC,CAAC,QAAQ,EAAE,UAAU,EAAE,KAAK,EAAE,SAAS,CAAU,CAAC;IACjF,YAAY,EAAE,MAAM,CAAC,MAAM;IAC3B,aAAa,EAAE,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC;IAC7C,gBAAgB,EAAE,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC;IAChD,KAAK,EAAE,MAAM,CAAC,OAAO;CACtB,CAAC,CAAC;AAGH,MAAM,qBAAqB,GAAG;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AK,SAAS;gBACZ,OAAO,aAAa,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QACrC,CAAC;IACH,CAAC,CAAC,EAAE,CAAC;IAEL,IAAI,KAAK,CAAC,CAAC,QAAQ,CAAC,QAAQ,CAAC,SAAS,EAAE,EAAE,MAAM,EAAE,EAAE,qBAAqB,CAAC,EAAE,CAAC;QAC3E,OAAO;IACT,CAAC;IAED,IAAI,MAAM,CAAC,MAAM,KAAK,WAAW,EAAE,CAAC;QAClC,KAAK,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;IAClC,CAAC;AACH,CAAC,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { Command } from "effect/unstable/cli";
2
+ export declare const upgradeCommand: Command.Command<"upgrade", Record<string, unknown>, {}, never, "effect/unstable/cli/GlobalFlag/axm-non-interactive" | "effect/unstable/cli/GlobalFlag/axm-json" | "effect/unstable/cli/GlobalFlag/axm-quiet" | "effect/unstable/cli/GlobalFlag/axm-verbose" | "effect/unstable/cli/GlobalFlag/axm-debug">;
3
+ //# sourceMappingURL=upgrade.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"upgrade.d.ts","sourceRoot":"","sources":["../../../../src/root/upgrade/upgrade.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,OAAO,EAAQ,MAAM,qBAAqB,CAAC;AAapD,eAAO,MAAM,cAAc,2SAS1B,CAAC"}
@@ -0,0 +1,18 @@
1
+ import * as Effect from "effect/Effect";
2
+ import * as Layer from "effect/Layer";
3
+ import { forceFlag } from "@agentxm/client-core/unstable/cli-flags";
4
+ import { withArgvTracking } from "@agentxm/client-core/unstable/cli-runtime";
5
+ import { InstallMethodLive } from "@agentxm/client-core/unstable/install-method";
6
+ import { InstallMetaLive } from "@agentxm/client-core/unstable/install-meta";
7
+ import { Command, Flag } from "effect/unstable/cli";
8
+ import { withRuntime } from "../../runtime.js";
9
+ import { handleUpgrade } from "./handler.js";
10
+ const upgradeLayer = Layer.mergeAll(InstallMethodLive, InstallMetaLive);
11
+ const upgradeConfig = {
12
+ force: forceFlag.pipe(Flag.withDescription("Re-download even if already up to date (script installs only)")),
13
+ };
14
+ export const upgradeCommand = Command.make("upgrade", upgradeConfig, ({ force }) => Effect.provide(handleUpgrade({ force }), upgradeLayer).pipe(withRuntime("upgrade"))).pipe(withArgvTracking(upgradeConfig), Command.withDescription("Update axm to the latest version"), Command.withExamples([
15
+ { command: "axm upgrade", description: "Download and install the latest version" },
16
+ { command: "axm upgrade --force", description: "Re-download even if already up to date" },
17
+ ]));
18
+ //# sourceMappingURL=upgrade.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"upgrade.js","sourceRoot":"","sources":["../../../../src/root/upgrade/upgrade.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAC;AAC7E,OAAO,EAAE,iBAAiB,EAAE,MAAM,8CAA8C,CAAC;AACjF,OAAO,EAAE,eAAe,EAAE,MAAM,4CAA4C,CAAC;AAC7E,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/C,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAE7C,MAAM,YAAY,GAAG,KAAK,CAAC,QAAQ,CAAC,iBAAiB,EAAE,eAAe,CAAC,CAAC;AAExE,MAAM,aAAa,GAAG;IACpB,KAAK,EAAE,SAAS,CAAC,IAAI,CACnB,IAAI,CAAC,eAAe,CAAC,+DAA+D,CAAC,CACtF;CACO,CAAC;AAEX,MAAM,CAAC,MAAM,cAAc,GAAG,OAAO,CAAC,IAAI,CAAC,SAAS,EAAE,aAAa,EAAE,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,CACjF,MAAM,CAAC,OAAO,CAAC,aAAa,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,YAAY,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC,CACpF,CAAC,IAAI,CACJ,gBAAgB,CAAC,aAAa,CAAC,EAC/B,OAAO,CAAC,eAAe,CAAC,kCAAkC,CAAC,EAC3D,OAAO,CAAC,YAAY,CAAC;IACnB,EAAE,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,yCAAyC,EAAE;IAClF,EAAE,OAAO,EAAE,qBAAqB,EAAE,WAAW,EAAE,wCAAwC,EAAE;CAC1F,CAAC,CACH,CAAC"}
@@ -0,0 +1,39 @@
1
+ import * as NodeServices from "@effect/platform-node/NodeServices";
2
+ import * as Effect from "effect/Effect";
3
+ import * as Layer from "effect/Layer";
4
+ import * as Option from "effect/Option";
5
+ import type { AppError } from "@agentxm/client-core/unstable/app-error";
6
+ import type { PromptCancelled } from "@agentxm/client-core/unstable/prompt-cancelled";
7
+ import { Verbosity, verboseFlag, debugFlag } from "@agentxm/client-core/unstable/cli-flags";
8
+ import { RegistryUrl } from "@agentxm/client-core/unstable/auth";
9
+ import type { WorkspaceContextOptions, WorkspaceScope } from "@agentxm/client-core/unstable/workspace";
10
+ export { verboseFlag, debugFlag };
11
+ export declare const axmGlobalFlags: readonly [import("effect/unstable/cli/GlobalFlag").Setting<"axm-non-interactive", Option.Option<boolean>>, import("effect/unstable/cli/GlobalFlag").Setting<"axm-verbose", boolean>, import("effect/unstable/cli/GlobalFlag").Setting<"axm-debug", boolean>, import("effect/unstable/cli/GlobalFlag").Setting<"axm-quiet", boolean>, import("effect/unstable/cli/GlobalFlag").Setting<"axm-json", Option.Option<boolean>>];
12
+ export declare const runtimeBaseLayer: Layer.Layer<NodeServices.NodeServices | RegistryUrl | import("@agentxm/client-core/unstable/auth").DeviceLoginInteraction | import("@agentxm/client-core/unstable/auth").AuthLoginInteraction, never, never>;
13
+ export declare const baseLayer: Layer.Layer<NodeServices.NodeServices | import("effect/unstable/http/HttpClient").HttpClient | RegistryUrl | import("@agentxm/client-core/unstable/auth").DeviceLoginInteraction | import("@agentxm/client-core/unstable/auth").AuthLoginInteraction, never, never>;
14
+ export declare const resolveBuiltInRegistryLocation: (env: NodeJS.ProcessEnv, registryUrl: string) => string;
15
+ export declare const resolveBuiltInSources: Effect.Effect<readonly ({
16
+ readonly type: "github";
17
+ readonly name: string;
18
+ readonly url: URL;
19
+ } | {
20
+ readonly type: "gitlab";
21
+ readonly name: string;
22
+ readonly url: URL;
23
+ } | {
24
+ readonly type: "bitbucket";
25
+ readonly name: string;
26
+ readonly url: URL;
27
+ } | {
28
+ readonly type: "azurerepos";
29
+ readonly name: string;
30
+ readonly url: URL;
31
+ } | {
32
+ readonly type: "registry";
33
+ readonly name: string;
34
+ readonly location: URL;
35
+ })[], never, RegistryUrl>;
36
+ export declare const withWorkspace: (options: WorkspaceScope | Omit<WorkspaceContextOptions, "builtInSources">) => <A, E, R>(program: Effect.Effect<A, E, R>) => Effect.Effect<A, AppError | E, import("packages/core/src/unstable/cli-renderer/cli-renderer.ts").CliRenderer | import("effect/FileSystem").FileSystem | import("effect/Path").Path | import("effect/Terminal").Terminal | "effect/unstable/cli/GlobalFlag/axm-non-interactive" | RegistryUrl | Exclude<R, import("@agentxm/client-core/unstable/workspace").Workspace | import("@agentxm/client-core/unstable/agents").CodingAgentRepository | import("@agentxm/client-core/unstable/source-resolution").SourceHostProviders | import("@agentxm/client-core/unstable/commands").CommandManager | import("@agentxm/client-core/unstable/mcp-servers").McpServerManager | import("@agentxm/client-core/unstable/packs").ExtensionPackManager | import("@agentxm/client-core/unstable/subagents").SubagentManager | import("@agentxm/client-core/unstable/skills").SkillManager | import("./root/commands/install/command-actions.js").InstallCommandCommandWorkflowActions | import("./root/commands/uninstall/command-actions.js").UninstallCommandCommandWorkflowActions | import("./root/mcp-servers/install/command-actions.js").InstallMcpServerCommandWorkflowActions | import("./root/mcp-servers/uninstall/command-actions.js").UninstallMcpServerCommandWorkflowActions | import("./root/packs/install/command-actions.js").InstallPackCommandWorkflowActions | import("./root/packs/uninstall/command-actions.js").UninstallPackCommandWorkflowActions | import("./root/skills/install/command-actions.js").InstallSkillCommandWorkflowActions | import("./root/skills/uninstall/command-actions.js").UninstallSkillCommandWorkflowActions | import("./root/subagents/install/command-actions.js").InstallSubagentCommandWorkflowActions | import("./root/subagents/uninstall/command-actions.js").UninstallSubagentCommandWorkflowActions>>;
37
+ export declare const withAuthRuntime: (command?: string) => <A, R>(program: Effect.Effect<A, AppError | PromptCancelled, R>) => Effect.Effect<A, never, "effect/unstable/cli/GlobalFlag/axm-non-interactive" | "effect/unstable/cli/GlobalFlag/axm-json" | "effect/unstable/cli/GlobalFlag/axm-quiet" | "effect/unstable/cli/GlobalFlag/axm-verbose" | "effect/unstable/cli/GlobalFlag/axm-debug" | Exclude<Exclude<Exclude<Exclude<Exclude<R, NodeServices.NodeServices | import("effect/unstable/http/HttpClient").HttpClient | import("@agentxm/client-core/unstable/auth").CredentialStore | RegistryUrl | import("@agentxm/client-core/unstable/auth").AuthClient>, import("packages/core/src/unstable/cli-renderer/cli-renderer.ts").CliRenderer | Verbosity | import("@agentxm/client-core/unstable/workspace").WorkspaceInitializationInteraction | import("@agentxm/client-core/unstable/workspace").ResolvePlanInteraction | import("@agentxm/client-core/unstable/auth").AuthGuardInteraction>, import("effect/Scope").Scope>, import("@agentxm/client-core/unstable/telemetry").TelemetryClient | import("@agentxm/client-core/unstable/cli-runtime").CommandSemanticProperties>, NodeServices.NodeServices | import("effect/unstable/http/HttpClient").HttpClient | RegistryUrl>>;
38
+ export declare const withRuntime: (command?: string) => <A, R>(program: Effect.Effect<A, AppError | PromptCancelled, R>) => Effect.Effect<A, never, "effect/unstable/cli/GlobalFlag/axm-non-interactive" | "effect/unstable/cli/GlobalFlag/axm-json" | "effect/unstable/cli/GlobalFlag/axm-quiet" | "effect/unstable/cli/GlobalFlag/axm-verbose" | "effect/unstable/cli/GlobalFlag/axm-debug" | Exclude<Exclude<Exclude<Exclude<R, import("packages/core/src/unstable/cli-renderer/cli-renderer.ts").CliRenderer | Verbosity | import("@agentxm/client-core/unstable/workspace").WorkspaceInitializationInteraction | import("@agentxm/client-core/unstable/workspace").ResolvePlanInteraction | import("@agentxm/client-core/unstable/auth").AuthGuardInteraction>, import("effect/Scope").Scope>, import("@agentxm/client-core/unstable/telemetry").TelemetryClient | import("@agentxm/client-core/unstable/cli-runtime").CommandSemanticProperties>, NodeServices.NodeServices | import("effect/unstable/http/HttpClient").HttpClient | RegistryUrl>>;
39
+ //# sourceMappingURL=runtime.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../../src/runtime.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,YAAY,MAAM,oCAAoC,CAAC;AAGnE,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AAEtC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAGxC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,yCAAyC,CAAC;AACxE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gDAAgD,CAAC;AAQtF,OAAO,EACL,SAAS,EAGT,WAAW,EACX,SAAS,EAEV,MAAM,yCAAyC,CAAC;AAQjD,OAAO,EAML,WAAW,EACZ,MAAM,oCAAoC,CAAC;AAY5C,OAAO,KAAK,EACV,uBAAuB,EACvB,cAAc,EACf,MAAM,yCAAyC,CAAC;AASjD,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,CAAC;AAElC,eAAO,MAAM,cAAc,4ZAMjB,CAAC;AA6BX,eAAO,MAAM,gBAAgB,8MAK5B,CAAC;AAEF,eAAO,MAAM,SAAS,qQAAkD,CAAC;AA8BzE,eAAO,MAAM,8BAA8B,GACzC,KAAK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