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.
- package/LICENSE +21 -0
- package/README.md +26 -0
- package/dist/src/app.d.ts +7 -0
- package/dist/src/app.d.ts.map +1 -0
- package/dist/src/app.js +96 -0
- package/dist/src/app.js.map +1 -0
- package/dist/src/cli-flags.d.ts +3 -0
- package/dist/src/cli-flags.d.ts.map +1 -0
- package/dist/src/cli-flags.js +4 -0
- package/dist/src/cli-flags.js.map +1 -0
- package/dist/src/formatter.d.ts +22 -0
- package/dist/src/formatter.d.ts.map +1 -0
- package/dist/src/formatter.js +170 -0
- package/dist/src/formatter.js.map +1 -0
- package/dist/src/json-output.d.ts +41 -0
- package/dist/src/json-output.d.ts.map +1 -0
- package/dist/src/json-output.js +171 -0
- package/dist/src/json-output.js.map +1 -0
- package/dist/src/main.d.ts +3 -0
- package/dist/src/main.d.ts.map +1 -0
- package/dist/src/main.js +4 -0
- package/dist/src/main.js.map +1 -0
- package/dist/src/root/auth/_auth.d.ts +3 -0
- package/dist/src/root/auth/_auth.d.ts.map +1 -0
- package/dist/src/root/auth/_auth.js +11 -0
- package/dist/src/root/auth/_auth.js.map +1 -0
- package/dist/src/root/auth/login.d.ts +15 -0
- package/dist/src/root/auth/login.d.ts.map +1 -0
- package/dist/src/root/auth/login.js +55 -0
- package/dist/src/root/auth/login.js.map +1 -0
- package/dist/src/root/auth/logout.d.ts +7 -0
- package/dist/src/root/auth/logout.d.ts.map +1 -0
- package/dist/src/root/auth/logout.js +59 -0
- package/dist/src/root/auth/logout.js.map +1 -0
- package/dist/src/root/auth/token.d.ts +7 -0
- package/dist/src/root/auth/token.d.ts.map +1 -0
- package/dist/src/root/auth/token.js +45 -0
- package/dist/src/root/auth/token.js.map +1 -0
- package/dist/src/root/auth/whoami.d.ts +7 -0
- package/dist/src/root/auth/whoami.d.ts.map +1 -0
- package/dist/src/root/auth/whoami.js +73 -0
- package/dist/src/root/auth/whoami.js.map +1 -0
- package/dist/src/root/commands/_commands.d.ts +3 -0
- package/dist/src/root/commands/_commands.d.ts.map +1 -0
- package/dist/src/root/commands/_commands.js +45 -0
- package/dist/src/root/commands/_commands.js.map +1 -0
- package/dist/src/root/commands/disable.d.ts +17 -0
- package/dist/src/root/commands/disable.d.ts.map +1 -0
- package/dist/src/root/commands/disable.js +100 -0
- package/dist/src/root/commands/disable.js.map +1 -0
- package/dist/src/root/commands/enable.d.ts +17 -0
- package/dist/src/root/commands/enable.d.ts.map +1 -0
- package/dist/src/root/commands/enable.js +101 -0
- package/dist/src/root/commands/enable.js.map +1 -0
- package/dist/src/root/commands/install/command-actions.d.ts +61 -0
- package/dist/src/root/commands/install/command-actions.d.ts.map +1 -0
- package/dist/src/root/commands/install/command-actions.js +211 -0
- package/dist/src/root/commands/install/command-actions.js.map +1 -0
- package/dist/src/root/commands/install/command.d.ts +3 -0
- package/dist/src/root/commands/install/command.d.ts.map +1 -0
- package/dist/src/root/commands/install/command.js +32 -0
- package/dist/src/root/commands/install/command.js.map +1 -0
- package/dist/src/root/commands/install/handler.d.ts +11 -0
- package/dist/src/root/commands/install/handler.d.ts.map +1 -0
- package/dist/src/root/commands/install/handler.js +31 -0
- package/dist/src/root/commands/install/handler.js.map +1 -0
- package/dist/src/root/commands/install/intent.d.ts +19 -0
- package/dist/src/root/commands/install/intent.d.ts.map +1 -0
- package/dist/src/root/commands/install/intent.js +9 -0
- package/dist/src/root/commands/install/intent.js.map +1 -0
- package/dist/src/root/commands/job-step-result.d.ts +21 -0
- package/dist/src/root/commands/job-step-result.d.ts.map +1 -0
- package/dist/src/root/commands/job-step-result.js +17 -0
- package/dist/src/root/commands/job-step-result.js.map +1 -0
- package/dist/src/root/commands/list.d.ts +7 -0
- package/dist/src/root/commands/list.d.ts.map +1 -0
- package/dist/src/root/commands/list.js +63 -0
- package/dist/src/root/commands/list.js.map +1 -0
- package/dist/src/root/commands/new.d.ts +19 -0
- package/dist/src/root/commands/new.d.ts.map +1 -0
- package/dist/src/root/commands/new.js +111 -0
- package/dist/src/root/commands/new.js.map +1 -0
- package/dist/src/root/commands/preview-sections.d.ts +11 -0
- package/dist/src/root/commands/preview-sections.d.ts.map +1 -0
- package/dist/src/root/commands/preview-sections.js +25 -0
- package/dist/src/root/commands/preview-sections.js.map +1 -0
- package/dist/src/root/commands/publish.d.ts +20 -0
- package/dist/src/root/commands/publish.d.ts.map +1 -0
- package/dist/src/root/commands/publish.js +238 -0
- package/dist/src/root/commands/publish.js.map +1 -0
- package/dist/src/root/commands/uninstall/command-actions.d.ts +31 -0
- package/dist/src/root/commands/uninstall/command-actions.d.ts.map +1 -0
- package/dist/src/root/commands/uninstall/command-actions.js +85 -0
- package/dist/src/root/commands/uninstall/command-actions.js.map +1 -0
- package/dist/src/root/commands/uninstall/command.d.ts +3 -0
- package/dist/src/root/commands/uninstall/command.d.ts.map +1 -0
- package/dist/src/root/commands/uninstall/command.js +27 -0
- package/dist/src/root/commands/uninstall/command.js.map +1 -0
- package/dist/src/root/commands/uninstall/handler.d.ts +8 -0
- package/dist/src/root/commands/uninstall/handler.d.ts.map +1 -0
- package/dist/src/root/commands/uninstall/handler.js +10 -0
- package/dist/src/root/commands/uninstall/handler.js.map +1 -0
- package/dist/src/root/commands/uninstall/intent.d.ts +15 -0
- package/dist/src/root/commands/uninstall/intent.d.ts.map +1 -0
- package/dist/src/root/commands/uninstall/intent.js +9 -0
- package/dist/src/root/commands/uninstall/intent.js.map +1 -0
- package/dist/src/root/commands/update.d.ts +18 -0
- package/dist/src/root/commands/update.d.ts.map +1 -0
- package/dist/src/root/commands/update.js +145 -0
- package/dist/src/root/commands/update.js.map +1 -0
- package/dist/src/root/discover/command.d.ts +6 -0
- package/dist/src/root/discover/command.d.ts.map +1 -0
- package/dist/src/root/discover/command.js +22 -0
- package/dist/src/root/discover/command.js.map +1 -0
- package/dist/src/root/discover/handler.d.ts +52 -0
- package/dist/src/root/discover/handler.d.ts.map +1 -0
- package/dist/src/root/discover/handler.js +102 -0
- package/dist/src/root/discover/handler.js.map +1 -0
- package/dist/src/root/doctor/command.d.ts +3 -0
- package/dist/src/root/doctor/command.d.ts.map +1 -0
- package/dist/src/root/doctor/command.js +19 -0
- package/dist/src/root/doctor/command.js.map +1 -0
- package/dist/src/root/doctor/handler.d.ts +10 -0
- package/dist/src/root/doctor/handler.d.ts.map +1 -0
- package/dist/src/root/doctor/handler.js +27 -0
- package/dist/src/root/doctor/handler.js.map +1 -0
- package/dist/src/root/doctor/render.d.ts +8 -0
- package/dist/src/root/doctor/render.d.ts.map +1 -0
- package/dist/src/root/doctor/render.js +183 -0
- package/dist/src/root/doctor/render.js.map +1 -0
- package/dist/src/root/init.d.ts +10 -0
- package/dist/src/root/init.d.ts.map +1 -0
- package/dist/src/root/init.js +133 -0
- package/dist/src/root/init.js.map +1 -0
- package/dist/src/root/install/command.d.ts +3 -0
- package/dist/src/root/install/command.d.ts.map +1 -0
- package/dist/src/root/install/command.js +32 -0
- package/dist/src/root/install/command.js.map +1 -0
- package/dist/src/root/install/handler.d.ts +17 -0
- package/dist/src/root/install/handler.d.ts.map +1 -0
- package/dist/src/root/install/handler.js +62 -0
- package/dist/src/root/install/handler.js.map +1 -0
- package/dist/src/root/install/resolve-root-install-intent.d.ts +16 -0
- package/dist/src/root/install/resolve-root-install-intent.d.ts.map +1 -0
- package/dist/src/root/install/resolve-root-install-intent.js +75 -0
- package/dist/src/root/install/resolve-root-install-intent.js.map +1 -0
- package/dist/src/root/install/workspace-install-handler.d.ts +23 -0
- package/dist/src/root/install/workspace-install-handler.d.ts.map +1 -0
- package/dist/src/root/install/workspace-install-handler.js +52 -0
- package/dist/src/root/install/workspace-install-handler.js.map +1 -0
- package/dist/src/root/install/workspace-install.d.ts +38 -0
- package/dist/src/root/install/workspace-install.d.ts.map +1 -0
- package/dist/src/root/install/workspace-install.js +160 -0
- package/dist/src/root/install/workspace-install.js.map +1 -0
- package/dist/src/root/mcp-servers/_mcp-servers.d.ts +3 -0
- package/dist/src/root/mcp-servers/_mcp-servers.d.ts.map +1 -0
- package/dist/src/root/mcp-servers/_mcp-servers.js +14 -0
- package/dist/src/root/mcp-servers/_mcp-servers.js.map +1 -0
- package/dist/src/root/mcp-servers/install/command-actions.d.ts +48 -0
- package/dist/src/root/mcp-servers/install/command-actions.d.ts.map +1 -0
- package/dist/src/root/mcp-servers/install/command-actions.js +185 -0
- package/dist/src/root/mcp-servers/install/command-actions.js.map +1 -0
- package/dist/src/root/mcp-servers/install/command.d.ts +3 -0
- package/dist/src/root/mcp-servers/install/command.d.ts.map +1 -0
- package/dist/src/root/mcp-servers/install/command.js +32 -0
- package/dist/src/root/mcp-servers/install/command.js.map +1 -0
- package/dist/src/root/mcp-servers/install/handler.d.ts +13 -0
- package/dist/src/root/mcp-servers/install/handler.d.ts.map +1 -0
- package/dist/src/root/mcp-servers/install/handler.js +22 -0
- package/dist/src/root/mcp-servers/install/handler.js.map +1 -0
- package/dist/src/root/mcp-servers/install/intent.d.ts +18 -0
- package/dist/src/root/mcp-servers/install/intent.d.ts.map +1 -0
- package/dist/src/root/mcp-servers/install/intent.js +9 -0
- package/dist/src/root/mcp-servers/install/intent.js.map +1 -0
- package/dist/src/root/mcp-servers/uninstall/command-actions.d.ts +31 -0
- package/dist/src/root/mcp-servers/uninstall/command-actions.d.ts.map +1 -0
- package/dist/src/root/mcp-servers/uninstall/command-actions.js +68 -0
- package/dist/src/root/mcp-servers/uninstall/command-actions.js.map +1 -0
- package/dist/src/root/mcp-servers/uninstall/command.d.ts +3 -0
- package/dist/src/root/mcp-servers/uninstall/command.d.ts.map +1 -0
- package/dist/src/root/mcp-servers/uninstall/command.js +27 -0
- package/dist/src/root/mcp-servers/uninstall/command.js.map +1 -0
- package/dist/src/root/mcp-servers/uninstall/handler.d.ts +8 -0
- package/dist/src/root/mcp-servers/uninstall/handler.d.ts.map +1 -0
- package/dist/src/root/mcp-servers/uninstall/handler.js +10 -0
- package/dist/src/root/mcp-servers/uninstall/handler.js.map +1 -0
- package/dist/src/root/mcp-servers/uninstall/intent.d.ts +15 -0
- package/dist/src/root/mcp-servers/uninstall/intent.d.ts.map +1 -0
- package/dist/src/root/mcp-servers/uninstall/intent.js +9 -0
- package/dist/src/root/mcp-servers/uninstall/intent.js.map +1 -0
- package/dist/src/root/packs/_packs.d.ts +3 -0
- package/dist/src/root/packs/_packs.d.ts.map +1 -0
- package/dist/src/root/packs/_packs.js +35 -0
- package/dist/src/root/packs/_packs.js.map +1 -0
- package/dist/src/root/packs/add.d.ts +16 -0
- package/dist/src/root/packs/add.d.ts.map +1 -0
- package/dist/src/root/packs/add.js +198 -0
- package/dist/src/root/packs/add.js.map +1 -0
- package/dist/src/root/packs/install/command-actions.d.ts +56 -0
- package/dist/src/root/packs/install/command-actions.d.ts.map +1 -0
- package/dist/src/root/packs/install/command-actions.js +373 -0
- package/dist/src/root/packs/install/command-actions.js.map +1 -0
- package/dist/src/root/packs/install/command.d.ts +3 -0
- package/dist/src/root/packs/install/command.d.ts.map +1 -0
- package/dist/src/root/packs/install/command.js +36 -0
- package/dist/src/root/packs/install/command.js.map +1 -0
- package/dist/src/root/packs/install/handler.d.ts +13 -0
- package/dist/src/root/packs/install/handler.d.ts.map +1 -0
- package/dist/src/root/packs/install/handler.js +22 -0
- package/dist/src/root/packs/install/handler.js.map +1 -0
- package/dist/src/root/packs/install/intent.d.ts +15 -0
- package/dist/src/root/packs/install/intent.d.ts.map +1 -0
- package/dist/src/root/packs/install/intent.js +9 -0
- package/dist/src/root/packs/install/intent.js.map +1 -0
- package/dist/src/root/packs/install/plan.d.ts +63 -0
- package/dist/src/root/packs/install/plan.d.ts.map +1 -0
- package/dist/src/root/packs/install/plan.js +181 -0
- package/dist/src/root/packs/install/plan.js.map +1 -0
- package/dist/src/root/packs/new.d.ts +18 -0
- package/dist/src/root/packs/new.d.ts.map +1 -0
- package/dist/src/root/packs/new.js +103 -0
- package/dist/src/root/packs/new.js.map +1 -0
- package/dist/src/root/packs/publish.d.ts +30 -0
- package/dist/src/root/packs/publish.d.ts.map +1 -0
- package/dist/src/root/packs/publish.js +288 -0
- package/dist/src/root/packs/publish.js.map +1 -0
- package/dist/src/root/packs/remove.d.ts +16 -0
- package/dist/src/root/packs/remove.d.ts.map +1 -0
- package/dist/src/root/packs/remove.js +156 -0
- package/dist/src/root/packs/remove.js.map +1 -0
- package/dist/src/root/packs/uninstall/command-actions.d.ts +47 -0
- package/dist/src/root/packs/uninstall/command-actions.d.ts.map +1 -0
- package/dist/src/root/packs/uninstall/command-actions.js +175 -0
- package/dist/src/root/packs/uninstall/command-actions.js.map +1 -0
- package/dist/src/root/packs/uninstall/command.d.ts +3 -0
- package/dist/src/root/packs/uninstall/command.d.ts.map +1 -0
- package/dist/src/root/packs/uninstall/command.js +31 -0
- package/dist/src/root/packs/uninstall/command.js.map +1 -0
- package/dist/src/root/packs/uninstall/handler.d.ts +8 -0
- package/dist/src/root/packs/uninstall/handler.d.ts.map +1 -0
- package/dist/src/root/packs/uninstall/handler.js +10 -0
- package/dist/src/root/packs/uninstall/handler.js.map +1 -0
- package/dist/src/root/packs/uninstall/intent.d.ts +13 -0
- package/dist/src/root/packs/uninstall/intent.d.ts.map +1 -0
- package/dist/src/root/packs/uninstall/intent.js +10 -0
- package/dist/src/root/packs/uninstall/intent.js.map +1 -0
- package/dist/src/root/packs/uninstall/plan.d.ts +60 -0
- package/dist/src/root/packs/uninstall/plan.d.ts.map +1 -0
- package/dist/src/root/packs/uninstall/plan.js +166 -0
- package/dist/src/root/packs/uninstall/plan.js.map +1 -0
- package/dist/src/root/packs/unpack/command.d.ts +3 -0
- package/dist/src/root/packs/unpack/command.d.ts.map +1 -0
- package/dist/src/root/packs/unpack/command.js +31 -0
- package/dist/src/root/packs/unpack/command.js.map +1 -0
- package/dist/src/root/packs/unpack/handler.d.ts +16 -0
- package/dist/src/root/packs/unpack/handler.d.ts.map +1 -0
- package/dist/src/root/packs/unpack/handler.js +117 -0
- package/dist/src/root/packs/unpack/handler.js.map +1 -0
- package/dist/src/root/packs/unpack/plan.d.ts +72 -0
- package/dist/src/root/packs/unpack/plan.d.ts.map +1 -0
- package/dist/src/root/packs/unpack/plan.js +120 -0
- package/dist/src/root/packs/unpack/plan.js.map +1 -0
- package/dist/src/root/shared/registry-install-target.d.ts +35 -0
- package/dist/src/root/shared/registry-install-target.d.ts.map +1 -0
- package/dist/src/root/shared/registry-install-target.js +66 -0
- package/dist/src/root/shared/registry-install-target.js.map +1 -0
- package/dist/src/root/skills/_skills.d.ts +3 -0
- package/dist/src/root/skills/_skills.d.ts.map +1 -0
- package/dist/src/root/skills/_skills.js +38 -0
- package/dist/src/root/skills/_skills.js.map +1 -0
- package/dist/src/root/skills/disable.d.ts +15 -0
- package/dist/src/root/skills/disable.d.ts.map +1 -0
- package/dist/src/root/skills/disable.js +91 -0
- package/dist/src/root/skills/disable.js.map +1 -0
- package/dist/src/root/skills/enable.d.ts +16 -0
- package/dist/src/root/skills/enable.d.ts.map +1 -0
- package/dist/src/root/skills/enable.js +92 -0
- package/dist/src/root/skills/enable.js.map +1 -0
- package/dist/src/root/skills/fork.d.ts +22 -0
- package/dist/src/root/skills/fork.d.ts.map +1 -0
- package/dist/src/root/skills/fork.js +288 -0
- package/dist/src/root/skills/fork.js.map +1 -0
- package/dist/src/root/skills/install/command-actions.d.ts +76 -0
- package/dist/src/root/skills/install/command-actions.d.ts.map +1 -0
- package/dist/src/root/skills/install/command-actions.js +323 -0
- package/dist/src/root/skills/install/command-actions.js.map +1 -0
- package/dist/src/root/skills/install/command.d.ts +3 -0
- package/dist/src/root/skills/install/command.d.ts.map +1 -0
- package/dist/src/root/skills/install/command.js +46 -0
- package/dist/src/root/skills/install/command.js.map +1 -0
- package/dist/src/root/skills/install/handler.d.ts +15 -0
- package/dist/src/root/skills/install/handler.d.ts.map +1 -0
- package/dist/src/root/skills/install/handler.js +39 -0
- package/dist/src/root/skills/install/handler.js.map +1 -0
- package/dist/src/root/skills/install/intent.d.ts +21 -0
- package/dist/src/root/skills/install/intent.d.ts.map +1 -0
- package/dist/src/root/skills/install/intent.js +7 -0
- package/dist/src/root/skills/install/intent.js.map +1 -0
- package/dist/src/root/skills/install/plan.d.ts +43 -0
- package/dist/src/root/skills/install/plan.d.ts.map +1 -0
- package/dist/src/root/skills/install/plan.js +82 -0
- package/dist/src/root/skills/install/plan.js.map +1 -0
- package/dist/src/root/skills/install/resolve-skill-install-source.d.ts +17 -0
- package/dist/src/root/skills/install/resolve-skill-install-source.d.ts.map +1 -0
- package/dist/src/root/skills/install/resolve-skill-install-source.js +271 -0
- package/dist/src/root/skills/install/resolve-skill-install-source.js.map +1 -0
- package/dist/src/root/skills/install/select-skills.d.ts +37 -0
- package/dist/src/root/skills/install/select-skills.d.ts.map +1 -0
- package/dist/src/root/skills/install/select-skills.js +91 -0
- package/dist/src/root/skills/install/select-skills.js.map +1 -0
- package/dist/src/root/skills/list.d.ts +10 -0
- package/dist/src/root/skills/list.d.ts.map +1 -0
- package/dist/src/root/skills/list.js +68 -0
- package/dist/src/root/skills/list.js.map +1 -0
- package/dist/src/root/skills/new.d.ts +19 -0
- package/dist/src/root/skills/new.d.ts.map +1 -0
- package/dist/src/root/skills/new.js +113 -0
- package/dist/src/root/skills/new.js.map +1 -0
- package/dist/src/root/skills/publish.d.ts +20 -0
- package/dist/src/root/skills/publish.d.ts.map +1 -0
- package/dist/src/root/skills/publish.js +230 -0
- package/dist/src/root/skills/publish.js.map +1 -0
- package/dist/src/root/skills/rename.d.ts +16 -0
- package/dist/src/root/skills/rename.d.ts.map +1 -0
- package/dist/src/root/skills/rename.js +84 -0
- package/dist/src/root/skills/rename.js.map +1 -0
- package/dist/src/root/skills/uninstall/command-actions.d.ts +39 -0
- package/dist/src/root/skills/uninstall/command-actions.d.ts.map +1 -0
- package/dist/src/root/skills/uninstall/command-actions.js +85 -0
- package/dist/src/root/skills/uninstall/command-actions.js.map +1 -0
- package/dist/src/root/skills/uninstall/command.d.ts +3 -0
- package/dist/src/root/skills/uninstall/command.d.ts.map +1 -0
- package/dist/src/root/skills/uninstall/command.js +24 -0
- package/dist/src/root/skills/uninstall/command.js.map +1 -0
- package/dist/src/root/skills/uninstall/handler.d.ts +8 -0
- package/dist/src/root/skills/uninstall/handler.d.ts.map +1 -0
- package/dist/src/root/skills/uninstall/handler.js +10 -0
- package/dist/src/root/skills/uninstall/handler.js.map +1 -0
- package/dist/src/root/skills/uninstall/intent.d.ts +17 -0
- package/dist/src/root/skills/uninstall/intent.d.ts.map +1 -0
- package/dist/src/root/skills/uninstall/intent.js +7 -0
- package/dist/src/root/skills/uninstall/intent.js.map +1 -0
- package/dist/src/root/skills/uninstall/plan.d.ts +35 -0
- package/dist/src/root/skills/uninstall/plan.d.ts.map +1 -0
- package/dist/src/root/skills/uninstall/plan.js +66 -0
- package/dist/src/root/skills/uninstall/plan.js.map +1 -0
- package/dist/src/root/skills/update/command.d.ts +3 -0
- package/dist/src/root/skills/update/command.d.ts.map +1 -0
- package/dist/src/root/skills/update/command.js +31 -0
- package/dist/src/root/skills/update/command.js.map +1 -0
- package/dist/src/root/skills/update/constraint-resolution.d.ts +70 -0
- package/dist/src/root/skills/update/constraint-resolution.d.ts.map +1 -0
- package/dist/src/root/skills/update/constraint-resolution.js +94 -0
- package/dist/src/root/skills/update/constraint-resolution.js.map +1 -0
- package/dist/src/root/skills/update/handler.d.ts +18 -0
- package/dist/src/root/skills/update/handler.d.ts.map +1 -0
- package/dist/src/root/skills/update/handler.js +409 -0
- package/dist/src/root/skills/update/handler.js.map +1 -0
- package/dist/src/root/skills/update/plan.d.ts +35 -0
- package/dist/src/root/skills/update/plan.d.ts.map +1 -0
- package/dist/src/root/skills/update/plan.js +92 -0
- package/dist/src/root/skills/update/plan.js.map +1 -0
- package/dist/src/root/subagents/_subagents.d.ts +3 -0
- package/dist/src/root/subagents/_subagents.d.ts.map +1 -0
- package/dist/src/root/subagents/_subagents.js +31 -0
- package/dist/src/root/subagents/_subagents.js.map +1 -0
- package/dist/src/root/subagents/disable/command.d.ts +3 -0
- package/dist/src/root/subagents/disable/command.d.ts.map +1 -0
- package/dist/src/root/subagents/disable/command.js +24 -0
- package/dist/src/root/subagents/disable/command.js.map +1 -0
- package/dist/src/root/subagents/disable/handler.d.ts +14 -0
- package/dist/src/root/subagents/disable/handler.d.ts.map +1 -0
- package/dist/src/root/subagents/disable/handler.js +71 -0
- package/dist/src/root/subagents/disable/handler.js.map +1 -0
- package/dist/src/root/subagents/enable/command.d.ts +3 -0
- package/dist/src/root/subagents/enable/command.d.ts.map +1 -0
- package/dist/src/root/subagents/enable/command.js +24 -0
- package/dist/src/root/subagents/enable/command.js.map +1 -0
- package/dist/src/root/subagents/enable/handler.d.ts +14 -0
- package/dist/src/root/subagents/enable/handler.d.ts.map +1 -0
- package/dist/src/root/subagents/enable/handler.js +71 -0
- package/dist/src/root/subagents/enable/handler.js.map +1 -0
- package/dist/src/root/subagents/install/command-actions.d.ts +58 -0
- package/dist/src/root/subagents/install/command-actions.d.ts.map +1 -0
- package/dist/src/root/subagents/install/command-actions.js +258 -0
- package/dist/src/root/subagents/install/command-actions.js.map +1 -0
- package/dist/src/root/subagents/install/command.d.ts +3 -0
- package/dist/src/root/subagents/install/command.d.ts.map +1 -0
- package/dist/src/root/subagents/install/command.js +46 -0
- package/dist/src/root/subagents/install/command.js.map +1 -0
- package/dist/src/root/subagents/install/handler.d.ts +15 -0
- package/dist/src/root/subagents/install/handler.d.ts.map +1 -0
- package/dist/src/root/subagents/install/handler.js +39 -0
- package/dist/src/root/subagents/install/handler.js.map +1 -0
- package/dist/src/root/subagents/install/intent.d.ts +21 -0
- package/dist/src/root/subagents/install/intent.d.ts.map +1 -0
- package/dist/src/root/subagents/install/intent.js +7 -0
- package/dist/src/root/subagents/install/intent.js.map +1 -0
- package/dist/src/root/subagents/install/plan.d.ts +44 -0
- package/dist/src/root/subagents/install/plan.d.ts.map +1 -0
- package/dist/src/root/subagents/install/plan.js +74 -0
- package/dist/src/root/subagents/install/plan.js.map +1 -0
- package/dist/src/root/subagents/install/resolve-subagent-install-source.d.ts +17 -0
- package/dist/src/root/subagents/install/resolve-subagent-install-source.d.ts.map +1 -0
- package/dist/src/root/subagents/install/resolve-subagent-install-source.js +265 -0
- package/dist/src/root/subagents/install/resolve-subagent-install-source.js.map +1 -0
- package/dist/src/root/subagents/install/select-subagents.d.ts +43 -0
- package/dist/src/root/subagents/install/select-subagents.d.ts.map +1 -0
- package/dist/src/root/subagents/install/select-subagents.js +90 -0
- package/dist/src/root/subagents/install/select-subagents.js.map +1 -0
- package/dist/src/root/subagents/list/command.d.ts +3 -0
- package/dist/src/root/subagents/list/command.d.ts.map +1 -0
- package/dist/src/root/subagents/list/command.js +21 -0
- package/dist/src/root/subagents/list/command.js.map +1 -0
- package/dist/src/root/subagents/list/handler.d.ts +8 -0
- package/dist/src/root/subagents/list/handler.d.ts.map +1 -0
- package/dist/src/root/subagents/list/handler.js +56 -0
- package/dist/src/root/subagents/list/handler.js.map +1 -0
- package/dist/src/root/subagents/new/command.d.ts +3 -0
- package/dist/src/root/subagents/new/command.d.ts.map +1 -0
- package/dist/src/root/subagents/new/command.js +42 -0
- package/dist/src/root/subagents/new/command.js.map +1 -0
- package/dist/src/root/subagents/new/handler.d.ts +21 -0
- package/dist/src/root/subagents/new/handler.d.ts.map +1 -0
- package/dist/src/root/subagents/new/handler.js +199 -0
- package/dist/src/root/subagents/new/handler.js.map +1 -0
- package/dist/src/root/subagents/publish/command.d.ts +3 -0
- package/dist/src/root/subagents/publish/command.d.ts.map +1 -0
- package/dist/src/root/subagents/publish/command.js +28 -0
- package/dist/src/root/subagents/publish/command.js.map +1 -0
- package/dist/src/root/subagents/publish/handler.d.ts +18 -0
- package/dist/src/root/subagents/publish/handler.d.ts.map +1 -0
- package/dist/src/root/subagents/publish/handler.js +204 -0
- package/dist/src/root/subagents/publish/handler.js.map +1 -0
- package/dist/src/root/subagents/rename/command.d.ts +3 -0
- package/dist/src/root/subagents/rename/command.d.ts.map +1 -0
- package/dist/src/root/subagents/rename/command.js +25 -0
- package/dist/src/root/subagents/rename/command.js.map +1 -0
- package/dist/src/root/subagents/rename/handler.d.ts +15 -0
- package/dist/src/root/subagents/rename/handler.d.ts.map +1 -0
- package/dist/src/root/subagents/rename/handler.js +174 -0
- package/dist/src/root/subagents/rename/handler.js.map +1 -0
- package/dist/src/root/subagents/uninstall/command-actions.d.ts +39 -0
- package/dist/src/root/subagents/uninstall/command-actions.d.ts.map +1 -0
- package/dist/src/root/subagents/uninstall/command-actions.js +85 -0
- package/dist/src/root/subagents/uninstall/command-actions.js.map +1 -0
- package/dist/src/root/subagents/uninstall/command.d.ts +3 -0
- package/dist/src/root/subagents/uninstall/command.d.ts.map +1 -0
- package/dist/src/root/subagents/uninstall/command.js +27 -0
- package/dist/src/root/subagents/uninstall/command.js.map +1 -0
- package/dist/src/root/subagents/uninstall/handler.d.ts +8 -0
- package/dist/src/root/subagents/uninstall/handler.d.ts.map +1 -0
- package/dist/src/root/subagents/uninstall/handler.js +10 -0
- package/dist/src/root/subagents/uninstall/handler.js.map +1 -0
- package/dist/src/root/subagents/uninstall/intent.d.ts +17 -0
- package/dist/src/root/subagents/uninstall/intent.d.ts.map +1 -0
- package/dist/src/root/subagents/uninstall/intent.js +7 -0
- package/dist/src/root/subagents/uninstall/intent.js.map +1 -0
- package/dist/src/root/subagents/update/command.d.ts +3 -0
- package/dist/src/root/subagents/update/command.d.ts.map +1 -0
- package/dist/src/root/subagents/update/command.js +41 -0
- package/dist/src/root/subagents/update/command.js.map +1 -0
- package/dist/src/root/subagents/update/handler.d.ts +16 -0
- package/dist/src/root/subagents/update/handler.d.ts.map +1 -0
- package/dist/src/root/subagents/update/handler.js +188 -0
- package/dist/src/root/subagents/update/handler.js.map +1 -0
- package/dist/src/root/subagents/update/plan.d.ts +39 -0
- package/dist/src/root/subagents/update/plan.d.ts.map +1 -0
- package/dist/src/root/subagents/update/plan.js +81 -0
- package/dist/src/root/subagents/update/plan.js.map +1 -0
- package/dist/src/root/sync.d.ts +15 -0
- package/dist/src/root/sync.d.ts.map +1 -0
- package/dist/src/root/sync.js +82 -0
- package/dist/src/root/sync.js.map +1 -0
- package/dist/src/root/upgrade/handler.d.ts +21 -0
- package/dist/src/root/upgrade/handler.d.ts.map +1 -0
- package/dist/src/root/upgrade/handler.js +303 -0
- package/dist/src/root/upgrade/handler.js.map +1 -0
- package/dist/src/root/upgrade/upgrade.d.ts +3 -0
- package/dist/src/root/upgrade/upgrade.d.ts.map +1 -0
- package/dist/src/root/upgrade/upgrade.js +18 -0
- package/dist/src/root/upgrade/upgrade.js.map +1 -0
- package/dist/src/runtime.d.ts +39 -0
- package/dist/src/runtime.d.ts.map +1 -0
- package/dist/src/runtime.js +144 -0
- package/dist/src/runtime.js.map +1 -0
- package/dist/src/test-helpers.d.ts +101 -0
- package/dist/src/test-helpers.d.ts.map +1 -0
- package/dist/src/test-helpers.js +153 -0
- package/dist/src/test-helpers.js.map +1 -0
- package/dist/src/test-stubs.d.ts +128 -0
- package/dist/src/test-stubs.d.ts.map +1 -0
- package/dist/src/test-stubs.js +227 -0
- package/dist/src/test-stubs.js.map +1 -0
- package/dist/src/update-check-startup.d.ts +68 -0
- package/dist/src/update-check-startup.d.ts.map +1 -0
- package/dist/src/update-check-startup.js +127 -0
- package/dist/src/update-check-startup.js.map +1 -0
- package/dist/src/version.d.ts +2 -0
- package/dist/src/version.d.ts.map +1 -0
- package/dist/src/version.js +23 -0
- package/dist/src/version.js.map +1 -0
- package/package.json +96 -0
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Command uninstall workflow actions service.
|
|
3
|
+
*
|
|
4
|
+
* Implements UninstallExtensionCommandWorkflowActions for commands.
|
|
5
|
+
* The live layer captures all required services at construction time
|
|
6
|
+
* so action methods satisfy the `R = never` contract.
|
|
7
|
+
*
|
|
8
|
+
* @experimental This API is unstable and may change without notice.
|
|
9
|
+
*/
|
|
10
|
+
import * as ServiceMap from "effect/ServiceMap";
|
|
11
|
+
import * as Effect from "effect/Effect";
|
|
12
|
+
import * as Layer from "effect/Layer";
|
|
13
|
+
import * as Option from "effect/Option";
|
|
14
|
+
import { makeAppError } from "@agentxm/client-core/unstable/app-error";
|
|
15
|
+
import { Workspace } from "@agentxm/client-core/unstable/workspace";
|
|
16
|
+
import { CommandManager } from "@agentxm/client-core/unstable/commands";
|
|
17
|
+
import { buildUninstallOperation } from "@agentxm/client-core/unstable/extensions";
|
|
18
|
+
import { combinePlanSections, makeAgentSection, makeRenderedFilesSection, } from "../preview-sections.js";
|
|
19
|
+
// -----------------------------------------------------------------------------
|
|
20
|
+
// Service Tag
|
|
21
|
+
// -----------------------------------------------------------------------------
|
|
22
|
+
export class UninstallCommandCommandWorkflowActions extends ServiceMap.Service()("axm.sh/UninstallCommandCommandWorkflowActions") {
|
|
23
|
+
}
|
|
24
|
+
// -----------------------------------------------------------------------------
|
|
25
|
+
// Live Layer
|
|
26
|
+
// -----------------------------------------------------------------------------
|
|
27
|
+
/**
|
|
28
|
+
* Constructs the actions by resolving all services at layer-build time.
|
|
29
|
+
* Each action method closes over the captured services so `R = never`.
|
|
30
|
+
*/
|
|
31
|
+
export const UninstallCommandCommandWorkflowActionsLive = Layer.effect(UninstallCommandCommandWorkflowActions, Effect.gen(function* () {
|
|
32
|
+
const ws = yield* Workspace;
|
|
33
|
+
const commandMgr = yield* CommandManager;
|
|
34
|
+
const parseArgs = (args) => Effect.succeed({ commandName: args.commandName.trim() });
|
|
35
|
+
const finalizeIntent = (parsed) => Effect.gen(function* () {
|
|
36
|
+
const lockEntry = yield* ws.getLockedCommand(parsed.commandName);
|
|
37
|
+
if (Option.isNone(lockEntry)) {
|
|
38
|
+
return yield* makeAppError({
|
|
39
|
+
code: "COMMAND_NOT_INSTALLED",
|
|
40
|
+
what: `Command "${parsed.commandName}" is not installed`,
|
|
41
|
+
howToFix: "Check installed commands and verify the name.",
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
const target = {
|
|
45
|
+
type: "command",
|
|
46
|
+
name: parsed.commandName,
|
|
47
|
+
};
|
|
48
|
+
return { targets: [target] };
|
|
49
|
+
});
|
|
50
|
+
const buildUninstallPlan = (intent) => Effect.gen(function* () {
|
|
51
|
+
const retentionPolicy = {
|
|
52
|
+
isRequiredByInstalledPack: (args) => ws.isExtensionRequiredByInstalledExtensionPack(args.target),
|
|
53
|
+
markDependencyRetainedInLockfile: (args) => ws.markDependencyRetainedInLockfile(args.target),
|
|
54
|
+
};
|
|
55
|
+
const steps = intent.targets.map((target) => buildUninstallOperation(commandMgr, retentionPolicy, { target }));
|
|
56
|
+
const lockEntries = yield* Effect.forEach(intent.targets, (target) => ws.getLockedCommand(target.name), { concurrency: "inherit" });
|
|
57
|
+
const targetNames = intent.targets.map((t) => t.name).join(", ");
|
|
58
|
+
const affectedAgents = [
|
|
59
|
+
...new Set(lockEntries.flatMap((lockEntry) => Option.isSome(lockEntry) ? [...lockEntry.value.agents] : [])),
|
|
60
|
+
];
|
|
61
|
+
const filesByAgent = {};
|
|
62
|
+
for (const lockEntry of lockEntries) {
|
|
63
|
+
if (Option.isNone(lockEntry) || lockEntry.value.renderedFiles === undefined) {
|
|
64
|
+
continue;
|
|
65
|
+
}
|
|
66
|
+
for (const [agentId, files] of Object.entries(lockEntry.value.renderedFiles)) {
|
|
67
|
+
filesByAgent[agentId] = [...(filesByAgent[agentId] ?? []), ...files];
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
const sections = combinePlanSections(makeAgentSection("Affected agents", affectedAgents), makeRenderedFilesSection("Files that would be removed", filesByAgent));
|
|
71
|
+
return {
|
|
72
|
+
_tag: "Plan",
|
|
73
|
+
name: "Uninstall command",
|
|
74
|
+
description: Option.some(`Uninstall command ${targetNames}`),
|
|
75
|
+
jobs: [{ concurrency: 1, steps }],
|
|
76
|
+
...(sections === undefined ? {} : { sections }),
|
|
77
|
+
};
|
|
78
|
+
});
|
|
79
|
+
return {
|
|
80
|
+
parseArgs,
|
|
81
|
+
finalizeIntent,
|
|
82
|
+
buildUninstallPlan,
|
|
83
|
+
};
|
|
84
|
+
}));
|
|
85
|
+
//# sourceMappingURL=command-actions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"command-actions.js","sourceRoot":"","sources":["../../../../../src/root/commands/uninstall/command-actions.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAK,UAAU,MAAM,mBAAmB,CAAC;AAChD,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AACtC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,YAAY,EAAiB,MAAM,yCAAyC,CAAC;AACtF,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,cAAc,EAA4B,MAAM,wCAAwC,CAAC;AAMlG,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AAGnF,OAAO,EACL,mBAAmB,EACnB,gBAAgB,EAChB,wBAAwB,GACzB,MAAM,wBAAwB,CAAC;AAkBhC,gFAAgF;AAChF,cAAc;AACd,gFAAgF;AAEhF,MAAM,OAAO,sCAAuC,SAAQ,UAAU,CAAC,OAAO,EAO3E,CAAC,+CAA+C,CAAC;CAAG;AAEvD,gFAAgF;AAChF,aAAa;AACb,gFAAgF;AAEhF;;;GAGG;AACH,MAAM,CAAC,MAAM,0CAA0C,GAAG,KAAK,CAAC,MAAM,CACpE,sCAAsC,EACtC,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC;IAClB,MAAM,EAAE,GAAG,KAAK,CAAC,CAAC,SAAS,CAAC;IAC5B,MAAM,UAAU,GAAG,KAAK,CAAC,CAAC,cAAc,CAAC;IAEzC,MAAM,SAAS,GAAG,CAChB,IAAiC,EACoB,EAAE,CACvD,MAAM,CAAC,OAAO,CAAC,EAAE,WAAW,EAAE,IAAI,CAAC,WAAW,CAAC,IAAI,EAAE,EAAE,CAAC,CAA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AAM,CAAC,IAAI,CAAC,qBAAqB,WAAW,EAAE,CAAC;YAC5D,IAAI,EAAE,CAAC,EAAE,WAAW,EAAE,CAAU,EAAE,KAAK,EAAE,CAAC;YAC1C,GAAG,CAAC,QAAQ,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,CAAC;SACjC,CAAC;IACnB,CAAC,CAAC,CAAC;IAEL,OAAO;QACL,SAAS;QACT,cAAc;QACd,kBAAkB;KACnB,CAAC;AACJ,CAAC,CAAC,CACH,CAAC"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { Command } from "effect/unstable/cli";
|
|
2
|
+
export declare const uninstallCommand: Command.Command<"uninstall", 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=command.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"command.d.ts","sourceRoot":"","sources":["../../../../../src/root/commands/uninstall/command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,OAAO,EAAQ,MAAM,qBAAqB,CAAC;AAmB9D,eAAO,MAAM,gBAAgB,6SAyB5B,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { Argument, Command, Flag } from "effect/unstable/cli";
|
|
2
|
+
import { forceFlag, previewFlag, yesFlag } from "@agentxm/client-core/unstable/cli-flags";
|
|
3
|
+
import { withArgvTracking } from "@agentxm/client-core/unstable/cli-runtime";
|
|
4
|
+
import { handleUninstallCommand } from "./handler.js";
|
|
5
|
+
import { DEFAULT_WORKSPACE_SCOPE } from "@agentxm/client-core/unstable/workspace";
|
|
6
|
+
import { withRuntime, withWorkspace } from "../../../runtime.js";
|
|
7
|
+
const uninstallConfig = {
|
|
8
|
+
name: Argument.string("name").pipe(Argument.withDescription("Name of the command to uninstall")),
|
|
9
|
+
yes: yesFlag.pipe(Flag.withDescription("Skip the 'are you sure?' confirmation")),
|
|
10
|
+
force: forceFlag.pipe(Flag.withDescription("Remove even if the command is referenced by other extensions")),
|
|
11
|
+
preview: previewFlag.pipe(Flag.withDescription("Show what would be removed without making changes")),
|
|
12
|
+
};
|
|
13
|
+
export const uninstallCommand = Command.make("uninstall", uninstallConfig, ({ name, yes, force, preview }) => handleUninstallCommand({ commandName: name }, { yes, force, preview }).pipe(withWorkspace(DEFAULT_WORKSPACE_SCOPE), withRuntime("commands uninstall"))).pipe(withArgvTracking(uninstallConfig), Command.withDescription("Uninstall a command"), Command.withExamples([
|
|
14
|
+
{
|
|
15
|
+
command: "axm commands uninstall my-cmd",
|
|
16
|
+
description: "Remove a command you no longer need",
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
command: "axm commands uninstall my-cmd --preview",
|
|
20
|
+
description: "Check what would be removed first",
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
command: "axm commands uninstall my-cmd --yes",
|
|
24
|
+
description: "Remove without confirmation (scripts/CI)",
|
|
25
|
+
},
|
|
26
|
+
]));
|
|
27
|
+
//# sourceMappingURL=command.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"command.js","sourceRoot":"","sources":["../../../../../src/root/commands/uninstall/command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAE9D,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,OAAO,EAAE,MAAM,yCAAyC,CAAC;AAC1F,OAAO,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAC;AAC7E,OAAO,EAAE,sBAAsB,EAAE,MAAM,cAAc,CAAC;AACtD,OAAO,EAAE,uBAAuB,EAAE,MAAM,yCAAyC,CAAC;AAClF,O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allCommandCommandWorkflowActions, type UninstallCommandHandlerArgs } from "./command-actions.js";
|
|
3
|
+
export declare const handleUninstallCommand: (args: UninstallCommandHandlerArgs, flags: {
|
|
4
|
+
yes: boolean;
|
|
5
|
+
force: boolean;
|
|
6
|
+
preview: boolean;
|
|
7
|
+
}) => Effect.Effect<void, import("packages/core/src/unstable/app-error/app-error.ts").AppError | import("packages/core/src/unstable/cli-prompt/prompt-cancelled.ts").PromptCancelled, import("packages/core/src/unstable/cli-renderer/cli-renderer.ts").CliRenderer | import("packages/core/src/unstable/cli-flags/verbosity.ts").Verbosity | import("effect/FileSystem").FileSystem | import("effect/Path").Path | "effect/unstable/cli/GlobalFlag/axm-non-interactive" | import("packages/core/src/unstable/workspace/service-interface.ts").Workspace | UninstallCommandCommandWorkflowActions>;
|
|
8
|
+
//# sourceMappingURL=handler.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../../../../src/root/commands/uninstall/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAIxC,OAAO,EACL,sCAAsC,EACtC,KAAK,2BAA2B,EACjC,MAAM,sBAAsB,CAAC;AAE9B,eAAO,MAAM,sBAAsB,GACjC,MAAM,2BAA2B,EACjC,OAAO;IAAE,GAAG,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,OAAO,CAAC;IAAC,OAAO,EAAE,OAAO,CAAA;CAAE,ikBAMvD,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as Effect from "effect/Effect";
|
|
2
|
+
import { runUninstallCommandWorkflow } from "@agentxm/client-core/unstable/workflows";
|
|
3
|
+
import { emitPlanResolutionResult } from "../../../json-output.js";
|
|
4
|
+
import { UninstallCommandCommandWorkflowActions, } from "./command-actions.js";
|
|
5
|
+
export const handleUninstallCommand = (args, flags) => Effect.gen(function* () {
|
|
6
|
+
const actions = yield* UninstallCommandCommandWorkflowActions;
|
|
7
|
+
const resolution = yield* runUninstallCommandWorkflow(args, actions, flags);
|
|
8
|
+
yield* emitPlanResolutionResult("commands.uninstall", resolution);
|
|
9
|
+
});
|
|
10
|
+
//# sourceMappingURL=handler.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../../../src/root/commands/uninstall/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,2BAA2B,EAAE,MAAM,yCAAyC,CAAC;AAEtF,OAAO,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AACnE,OAAO,EACL,sCAAsC,GAEvC,MAAM,sBAAsB,CAAC;AAE9B,MAAM,CAAC,MAAM,sBAAsB,GAAG,CACpC,IAAiC,EACjC,KAAyD,EACzD,EAAE,CACF,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC;IAClB,MAAM,OAAO,GAAG,KAAK,CAAC,CAAC,sCAAsC,CAAC;IAC9D,MAAM,UAAU,GAAG,KAAK,CAAC,CAAC,2BAA2B,CAAC,IAAI,EAAE,OAAO,EAAE,KAAK,CAAC,CAAC;IAC5E,KAAK,CAAC,CAAC,wBAAwB,CAAC,oBAAoB,EAAE,UAAU,CAAC,CAAC;AACpE,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Uninstall command intent type.
|
|
3
|
+
*
|
|
4
|
+
* Immutable intent payload for the `axm commands uninstall` workflow.
|
|
5
|
+
*
|
|
6
|
+
* @experimental This API is unstable and may change without notice.
|
|
7
|
+
*/
|
|
8
|
+
import type { CommandExtensionTarget } from "@agentxm/client-core/unstable/workspace";
|
|
9
|
+
/**
|
|
10
|
+
* Intent for uninstalling a command extension.
|
|
11
|
+
*/
|
|
12
|
+
export interface UninstallCommandCommandIntent {
|
|
13
|
+
readonly targets: ReadonlyArray<CommandExtensionTarget>;
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=intent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"intent.d.ts","sourceRoot":"","sources":["../../../../../src/root/commands/uninstall/intent.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AAEtF;;GAEG;AACH,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,CAAC,OAAO,EAAE,aAAa,CAAC,sBAAsB,CAAC,CAAC;CACzD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"intent.js","sourceRoot":"","sources":["../../../../../src/root/commands/uninstall/intent.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import * as FileSystem from "effect/FileSystem";
|
|
2
|
+
import * as Path from "effect/Path";
|
|
3
|
+
import * as Option from "effect/Option";
|
|
4
|
+
import { Command } from "effect/unstable/cli";
|
|
5
|
+
import * as Effect from "effect/Effect";
|
|
6
|
+
import { CodingAgentRepository } from "@agentxm/client-core/unstable/agents";
|
|
7
|
+
import { CliRenderer } from "@agentxm/client-core/unstable/cli-renderer";
|
|
8
|
+
import { Workspace } from "@agentxm/client-core/unstable/workspace";
|
|
9
|
+
import { SourceHostProviders } from "@agentxm/client-core/unstable/source-resolution";
|
|
10
|
+
export interface UpdateCommandHandlerArgs {
|
|
11
|
+
readonly name: Option.Option<string>;
|
|
12
|
+
readonly yes: boolean;
|
|
13
|
+
readonly force: boolean;
|
|
14
|
+
readonly preview: boolean;
|
|
15
|
+
}
|
|
16
|
+
export declare const handleUpdateCommand: (args: UpdateCommandHandlerArgs) => Effect.Effect<undefined, import("@agentxm/client-core/unstable/app-error").AppError | import("packages/core/src/unstable/cli-prompt/prompt-cancelled.ts").PromptCancelled, CliRenderer | import("effect/Scope").Scope | import("@agentxm/client-core/unstable/cli-flags").Verbosity | FileSystem.FileSystem | Path.Path | "effect/unstable/cli/GlobalFlag/axm-non-interactive" | Workspace | CodingAgentRepository | SourceHostProviders>;
|
|
17
|
+
export declare const updateCommand: Command.Command<"update", 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">;
|
|
18
|
+
//# sourceMappingURL=update.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update.d.ts","sourceRoot":"","sources":["../../../../src/root/commands/update.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,UAAU,MAAM,mBAAmB,CAAC;AAChD,OAAO,KAAK,IAAI,MAAM,aAAa,CAAC;AACpC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAExC,OAAO,EAAY,OAAO,EAAQ,MAAM,qBAAqB,CAAC;AAC9D,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAExC,OAAO,EAAE,qBAAqB,EAAE,MAAM,sCAAsC,CAAC;AAC7E,OAAO,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AACzE,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,OAAO,EAEL,mBAAmB,EACpB,MAAM,iDAAiD,CAAC;AAYzD,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;IACrC,QAAQ,CAAC,GAAG,EAAE,OAAO,CAAC;IACtB,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;IACxB,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;CAC3B;AAED,eAAO,MAAM,mBAAmB,+cAwK9B,CAAC;AAiBH,eAAO,MAAM,aAAa,0SAyBzB,CAAC"}
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
import * as FileSystem from "effect/FileSystem";
|
|
2
|
+
import * as Path from "effect/Path";
|
|
3
|
+
import * as Option from "effect/Option";
|
|
4
|
+
import * as Array from "effect/Array";
|
|
5
|
+
import { Argument, Command, Flag } from "effect/unstable/cli";
|
|
6
|
+
import * as Effect from "effect/Effect";
|
|
7
|
+
import { makeAppError } from "@agentxm/client-core/unstable/app-error";
|
|
8
|
+
import { CodingAgentRepository } from "@agentxm/client-core/unstable/agents";
|
|
9
|
+
import { CliRenderer } from "@agentxm/client-core/unstable/cli-renderer";
|
|
10
|
+
import { Workspace } from "@agentxm/client-core/unstable/workspace";
|
|
11
|
+
import { installCommand as installCommandOp } from "@agentxm/client-core/unstable/commands";
|
|
12
|
+
import { resolveSource, SourceHostProviders, } from "@agentxm/client-core/unstable/source-resolution";
|
|
13
|
+
import { forceFlag, previewFlag, yesFlag } from "@agentxm/client-core/unstable/cli-flags";
|
|
14
|
+
import { withArgvTracking } from "@agentxm/client-core/unstable/cli-runtime";
|
|
15
|
+
import { previewOrApplyPlan } from "@agentxm/client-core/unstable/workspace";
|
|
16
|
+
import { emitNoOpResult, emitPlanResolutionResult } from "../../json-output.js";
|
|
17
|
+
import { withRuntime, withWorkspace } from "../../runtime.js";
|
|
18
|
+
import { scopeFlag } from "../../cli-flags.js";
|
|
19
|
+
import { toJobStepResult } from "./job-step-result.js";
|
|
20
|
+
import { combinePlanSections, makeItemSection } from "./preview-sections.js";
|
|
21
|
+
export const handleUpdateCommand = Effect.fn("UpdateCommand.handle")(function* (args) {
|
|
22
|
+
const ws = yield* Workspace;
|
|
23
|
+
const renderer = yield* CliRenderer;
|
|
24
|
+
yield* renderer.info(`axm commands update (${ws.scope})`);
|
|
25
|
+
// Step 1: Load configured commands and filter to enabled
|
|
26
|
+
const allCommands = yield* ws.getConfiguredCommands();
|
|
27
|
+
const commandEntries = yield* Effect.forEach(Object.entries(allCommands), ([name, entry]) => Effect.gen(function* () {
|
|
28
|
+
if (!entry.enabled) {
|
|
29
|
+
yield* renderer.info(`Skipping ${name} (disabled)`);
|
|
30
|
+
return Option.none();
|
|
31
|
+
}
|
|
32
|
+
return Option.some([name, entry.source]);
|
|
33
|
+
})).pipe(Effect.map(Array.getSomes));
|
|
34
|
+
if (commandEntries.length === 0) {
|
|
35
|
+
if (yield* emitNoOpResult("commands.update", {
|
|
36
|
+
planName: "Update command(s)",
|
|
37
|
+
planDescription: "Update installed commands",
|
|
38
|
+
message: "No commands installed. Nothing to update.",
|
|
39
|
+
})) {
|
|
40
|
+
return;
|
|
41
|
+
}
|
|
42
|
+
yield* renderer.info("No commands installed. Nothing to update.");
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
// Step 2: Filter by name if provided
|
|
46
|
+
const nameValue = Option.getOrUndefined(args.name);
|
|
47
|
+
const filteredEntries = nameValue !== undefined
|
|
48
|
+
? commandEntries.filter(([name]) => name === nameValue)
|
|
49
|
+
: commandEntries;
|
|
50
|
+
if (nameValue !== undefined && filteredEntries.length === 0) {
|
|
51
|
+
if (yield* emitNoOpResult("commands.update", {
|
|
52
|
+
planName: "Update command(s)",
|
|
53
|
+
planDescription: "Update installed commands",
|
|
54
|
+
message: `Command "${nameValue}" is not installed or is disabled. Nothing to update.`,
|
|
55
|
+
})) {
|
|
56
|
+
return;
|
|
57
|
+
}
|
|
58
|
+
yield* renderer.warn(`Command "${nameValue}" is not installed or is disabled. Nothing to update.`);
|
|
59
|
+
return;
|
|
60
|
+
}
|
|
61
|
+
// Step 3: Re-resolve each source and discover commands
|
|
62
|
+
const sources = yield* SourceHostProviders;
|
|
63
|
+
const agentRepo = yield* CodingAgentRepository;
|
|
64
|
+
const resolved = yield* renderer.withSpinner("Resolving sources...", () => Effect.forEach(filteredEntries, ([name, sourceStr]) => Effect.gen(function* () {
|
|
65
|
+
const source = yield* resolveSource(sourceStr);
|
|
66
|
+
const refs = yield* sources
|
|
67
|
+
.find(source, {
|
|
68
|
+
names: [name],
|
|
69
|
+
type: "command",
|
|
70
|
+
owner: Option.none(),
|
|
71
|
+
versionConstraint: Option.none(),
|
|
72
|
+
})
|
|
73
|
+
.pipe(Effect.map((refs) => refs.filter((ref) => ref.type === "command")));
|
|
74
|
+
const commandRef = refs.find((r) => r.command.name === name);
|
|
75
|
+
if (commandRef) {
|
|
76
|
+
return Option.some({ name, ref: commandRef });
|
|
77
|
+
}
|
|
78
|
+
yield* renderer.warn(`Command "${name}" not found in source ${sources.origin(source)}`);
|
|
79
|
+
return Option.none();
|
|
80
|
+
}).pipe(Effect.catchTag("AppError", (error) => renderer.warn(`Failed to resolve "${name}": ${String(error)}`).pipe(Effect.map(() => Option.none())))), { concurrency: "unbounded" }), { successMessage: "Sources resolved" });
|
|
81
|
+
const resolvedEntries = Array.getSomes(resolved);
|
|
82
|
+
if (resolvedEntries.length === 0) {
|
|
83
|
+
return yield* makeAppError({
|
|
84
|
+
code: "UPDATE_FAILED",
|
|
85
|
+
what: "All source re-resolutions failed. Nothing to update.",
|
|
86
|
+
howToFix: "Verify the original source paths are still accessible.",
|
|
87
|
+
});
|
|
88
|
+
}
|
|
89
|
+
// Step 4: Build operations
|
|
90
|
+
const fs = yield* FileSystem.FileSystem;
|
|
91
|
+
const path = yield* Path.Path;
|
|
92
|
+
const steps = resolvedEntries.map((entry) => ({
|
|
93
|
+
readiness: "ready",
|
|
94
|
+
label: entry.name,
|
|
95
|
+
run: installCommandOp({
|
|
96
|
+
name: "install-command",
|
|
97
|
+
args: {
|
|
98
|
+
ref: entry.ref,
|
|
99
|
+
force: args.force,
|
|
100
|
+
versionConstraint: Option.none(),
|
|
101
|
+
skipSettings: Option.none(),
|
|
102
|
+
},
|
|
103
|
+
}).pipe(Effect.map(toJobStepResult), Effect.provideService(Workspace, ws), Effect.provideService(FileSystem.FileSystem, fs), Effect.provideService(Path.Path, path), Effect.provideService(CliRenderer, renderer), Effect.provideService(SourceHostProviders, sources), Effect.provideService(CodingAgentRepository, agentRepo)),
|
|
104
|
+
}));
|
|
105
|
+
const planSections = combinePlanSections(makeItemSection(`Would update ${resolvedEntries.length} command(s)`, resolvedEntries.map((entry) => entry.name)));
|
|
106
|
+
const plan = {
|
|
107
|
+
_tag: "Plan",
|
|
108
|
+
name: "Update command(s)",
|
|
109
|
+
description: Option.some("Update installed commands"),
|
|
110
|
+
jobs: [{ concurrency: 1, steps: [...steps] }],
|
|
111
|
+
...(planSections === undefined ? {} : { sections: planSections }),
|
|
112
|
+
};
|
|
113
|
+
// Step 5: Resolve plan
|
|
114
|
+
const resolution = yield* previewOrApplyPlan(plan, {
|
|
115
|
+
yes: args.yes,
|
|
116
|
+
force: args.force,
|
|
117
|
+
preview: args.preview,
|
|
118
|
+
});
|
|
119
|
+
yield* emitPlanResolutionResult("commands.update", resolution);
|
|
120
|
+
if (resolution._tag === "ExecutedPlan") {
|
|
121
|
+
yield* renderer.success("Done");
|
|
122
|
+
}
|
|
123
|
+
});
|
|
124
|
+
const updateConfig = {
|
|
125
|
+
name: Argument.string("name").pipe(Argument.withDescription("Name of the command to update (updates all if omitted)"), Argument.optional),
|
|
126
|
+
scope: scopeFlag.pipe(Flag.withDescription("Update commands in project (default) or user-level configuration")),
|
|
127
|
+
yes: yesFlag.pipe(Flag.withDescription("Apply all updates without confirmation")),
|
|
128
|
+
force: forceFlag.pipe(Flag.withDescription("Update even if version constraints would prevent it")),
|
|
129
|
+
preview: previewFlag.pipe(Flag.withDescription("Show available updates without applying them")),
|
|
130
|
+
};
|
|
131
|
+
export const updateCommand = Command.make("update", updateConfig, ({ name, scope, yes, force, preview }) => handleUpdateCommand({ name, yes, force, preview }).pipe(withWorkspace(scope), withRuntime("commands update"))).pipe(withArgvTracking(updateConfig), Command.withDescription("Update installed commands to latest versions"), Command.withExamples([
|
|
132
|
+
{
|
|
133
|
+
command: "axm commands update",
|
|
134
|
+
description: "Update all commands to their latest versions",
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
command: "axm commands update my-cmd",
|
|
138
|
+
description: "Update a specific command",
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
command: "axm commands update --preview",
|
|
142
|
+
description: "Preview available updates",
|
|
143
|
+
},
|
|
144
|
+
]));
|
|
145
|
+
//# sourceMappingURL=update.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update.js","sourceRoot":"","sources":["../../../../src/root/commands/update.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,UAAU,MAAM,mBAAmB,CAAC;AAChD,OAAO,KAAK,IAAI,MAAM,aAAa,CAAC;AACpC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,yCAAyC,CAAC;AACvE,OAAO,EAAE,qBAAqB,EAAE,MAAM,sCAAsC,CAAC;AAC7E,OAAO,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AACzE,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,cAAc,IAAI,gBAAgB,EAAE,MAAM,wCAAwC,CAAC;AAC5F,OAAO,EACL,aAAa,EACb,mBAAmB,GACpB,MAAM,iDAAiD,CAAC;AACzD,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,OAAO,EAAE,MAAM,yCAAyC,CAAC;AAC1F,OAAO,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAC;AAE7E,OAAO,EAAE,kBAAkB,EAAE,MAAM,yCAAyC,CAAC;AAC7E,OAAO,EAAE,cAAc,EAAE,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AAChF,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAE/C,OAAO,EAAE,eAAe,E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ACnB,IAAI,CAAC,eAAe,CAAC,kEAAkE,CAAC,CACzF;IACD,GAAG,EAAE,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,eAAe,CAAC,wCAAwC,CAAC,CAAC;IACjF,KAAK,EAAE,SAAS,CAAC,IAAI,CACnB,IAAI,CAAC,eAAe,CAAC,qDAAqD,CAAC,CAC5E;IACD,OAAO,EAAE,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,eAAe,CAAC,8CAA8C,CAAC,CAAC;CACvF,CAAC;AAEX,MAAM,CAAC,MAAM,aAAa,GAAG,OAAO,CAAC,IAAI,CACvC,QAAQ,EACR,YAAY,EACZ,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,EAAE,CACvC,mBAAmB,CAAC,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,CAAC,IAAI,CACrD,aAAa,CAAC,KAAK,CAAC,EACpB,WAAW,CAAC,iBAAiB,CAAC,CAC/B,CACJ,CAAC,IAAI,CACJ,gBAAgB,CAAC,YAAY,CAAC,EAC9B,OAAO,CAAC,eAAe,CAAC,8CAA8C,CAAC,EACvE,OAAO,CAAC,YAAY,CAAC;IACnB;QACE,OAAO,EAAE,qBAAqB;QAC9B,WAAW,EAAE,8CAA8C;KAC5D;IACD;QACE,OAAO,EAAE,4BAA4B;QACrC,WAAW,EAAE,2BAA2B;KACzC;IACD;QACE,OAAO,EAAE,+BAA+B;QACxC,WAAW,EAAE,2BAA2B;KACzC;CACF,CAAC,CACH,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CLI command definition for `axm discover`.
|
|
3
|
+
*/
|
|
4
|
+
import { Command } from "effect/unstable/cli";
|
|
5
|
+
export declare const discoverCommand: Command.Command<"discover", 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">;
|
|
6
|
+
//# sourceMappingURL=command.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"command.d.ts","sourceRoot":"","sources":["../../../../src/root/discover/command.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,OAAO,EAAQ,MAAM,qBAAqB,CAAC;AAapD,eAAO,MAAM,eAAe,4SAgB3B,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CLI command definition for `axm discover`.
|
|
3
|
+
*/
|
|
4
|
+
import { Command, Flag } from "effect/unstable/cli";
|
|
5
|
+
import { withArgvTracking } from "@agentxm/client-core/unstable/cli-runtime";
|
|
6
|
+
import { withRuntime } from "../../runtime.js";
|
|
7
|
+
import { handleDiscover } from "./handler.js";
|
|
8
|
+
const discoverConfig = {
|
|
9
|
+
path: Flag.string("path").pipe(Flag.optional, Flag.withDescription("Scan a different directory instead of the current working directory")),
|
|
10
|
+
};
|
|
11
|
+
export const discoverCommand = Command.make("discover", discoverConfig, ({ path }) => handleDiscover({ path }).pipe(withRuntime("discover"))).pipe(withArgvTracking(discoverConfig), Command.withDescription("Discover compatible extensions for your project's dependencies"), Command.withExamples([
|
|
12
|
+
{ command: "axm discover", description: "Discover extensions for the current project" },
|
|
13
|
+
{
|
|
14
|
+
command: "axm discover --path ./my-project",
|
|
15
|
+
description: "Discover extensions for a specific directory",
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
command: "axm discover --json",
|
|
19
|
+
description: "Emit { _version, command, items, count, totalDetected, registryAvailable }",
|
|
20
|
+
},
|
|
21
|
+
]));
|
|
22
|
+
//# sourceMappingURL=command.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"command.js","sourceRoot":"","sources":["../../../../src/root/discover/command.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAC;AAC7E,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/C,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAE9C,MAAM,cAAc,GAAG;IACrB,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,IAAI,CAC5B,IAAI,CAAC,QAAQ,EACb,IAAI,CAAC,eAAe,CAAC,qEAAqE,CAAC,CAC5F;CACO,CAAC;AAEX,MAAM,CAAC,MAAM,eAAe,GAAG,OAAO,CAAC,IAAI,CAAC,UAAU,EAAE,cAAc,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,CACnF,cAAc,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC,CACvD,CAAC,IAAI,CACJ,gBAAgB,CAAC,cAAc,CAAC,EAChC,OAAO,CAAC,eAAe,CAAC,gEAAgE,CAAC,EACzF,OAAO,CAAC,YAAY,CAAC;IACnB,EAAE,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,6CAA6C,EAAE;IACvF;QACE,OAAO,EAAE,kCAAkC;QAC3C,WAAW,EAAE,8CAA8C;KAC5D;IACD;QACE,OAAO,EAAE,qBAAqB;QAC9B,WAAW,EAAE,4EAA4E;KAC1F;CACF,CAAC,CACH,CAAC"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import * as Effect from "effect/Effect";
|
|
2
|
+
import * as Option from "effect/Option";
|
|
3
|
+
import * as Schema from "effect/Schema";
|
|
4
|
+
import { RegistryUrl } from "@agentxm/client-core/unstable/auth";
|
|
5
|
+
import { CliRenderer } from "@agentxm/client-core/unstable/cli-renderer";
|
|
6
|
+
import { type DiscoverPackageResult, type DiscoverResult } from "@agentxm/client-core/unstable/discover";
|
|
7
|
+
export interface DiscoverHandlerArgs {
|
|
8
|
+
readonly path: Option.Option<string>;
|
|
9
|
+
}
|
|
10
|
+
declare const DiscoverOutputFields: {
|
|
11
|
+
items: Schema.$Array<Schema.Struct<{
|
|
12
|
+
readonly package: Schema.String;
|
|
13
|
+
readonly extensions: Schema.$Array<Schema.Struct<{
|
|
14
|
+
readonly owner: Schema.String;
|
|
15
|
+
readonly type: Schema.String;
|
|
16
|
+
readonly name: Schema.String;
|
|
17
|
+
readonly description: Schema.String;
|
|
18
|
+
readonly latestVersion: Schema.String;
|
|
19
|
+
readonly signal: Schema.String;
|
|
20
|
+
}>>;
|
|
21
|
+
}>>;
|
|
22
|
+
count: Schema.Number;
|
|
23
|
+
totalDetected: Schema.Number;
|
|
24
|
+
registryAvailable: Schema.Boolean;
|
|
25
|
+
};
|
|
26
|
+
export declare const DiscoverOutputSchema: Schema.Struct<{
|
|
27
|
+
readonly _version: Schema.Literal<1>;
|
|
28
|
+
readonly command: Schema.Literal<"discover">;
|
|
29
|
+
} & {
|
|
30
|
+
items: Schema.$Array<Schema.Struct<{
|
|
31
|
+
readonly package: Schema.String;
|
|
32
|
+
readonly extensions: Schema.$Array<Schema.Struct<{
|
|
33
|
+
readonly owner: Schema.String;
|
|
34
|
+
readonly type: Schema.String;
|
|
35
|
+
readonly name: Schema.String;
|
|
36
|
+
readonly description: Schema.String;
|
|
37
|
+
readonly latestVersion: Schema.String;
|
|
38
|
+
readonly signal: Schema.String;
|
|
39
|
+
}>>;
|
|
40
|
+
}>>;
|
|
41
|
+
count: Schema.Number;
|
|
42
|
+
totalDetected: Schema.Number;
|
|
43
|
+
registryAvailable: Schema.Boolean;
|
|
44
|
+
}>;
|
|
45
|
+
export type DiscoverOutput = typeof DiscoverOutputSchema.Type;
|
|
46
|
+
export declare const resolveDiscoverProjectDir: (path: Option.Option<string>) => string;
|
|
47
|
+
export declare const formatPackageName: (pkg: DiscoverPackageResult) => string;
|
|
48
|
+
export declare const toDiscoverOutput: (result: DiscoverResult) => Schema.Struct.Type<typeof DiscoverOutputFields>;
|
|
49
|
+
export declare const handleDiscoverWith: <E, R>(args: DiscoverHandlerArgs, runDiscover: (projectDir: string) => Effect.Effect<DiscoverResult, E, R>) => Effect.Effect<void, E, CliRenderer | R>;
|
|
50
|
+
export declare const handleDiscover: (args: DiscoverHandlerArgs) => Effect.Effect<void, never, CliRenderer | import("effect/FileSystem").FileSystem | import("effect/Path").Path | RegistryUrl>;
|
|
51
|
+
export {};
|
|
52
|
+
//# sourceMappingURL=handler.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../../../src/root/discover/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAExC,OAAO,EAAE,WAAW,EAAE,MAAM,oCAAoC,CAAC;AACjE,OAAO,EAAE,WAAW,EAAkB,MAAM,4CAA4C,CAAC;AAEzF,OAAO,EAEL,KAAK,qBAAqB,EAC1B,KAAK,cAAc,EACpB,MAAM,wCAAwC,CAAC;AAMhD,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;CACtC;AAgBD,QAAA,MAAM,oBAAoB;;;;;;;;;;;;;;;CAKM,CAAC;AAEjC,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;EAA8D,CAAC;AAChG,MAAM,MAAM,cAAc,GAAG,OAAO,oBAAoB,CAAC,IAAI,CAAC;AA2B9D,eAAO,MAAM,yBAAyB,GAAI,MAAM,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,KAAG,MAC3B,CAAC;AAE9C,eAAO,MAAM,iBAAiB,GAAI,KAAK,qBAAqB,KAAG,MAQ9D,CAAC;AAEF,eAAO,MAAM,gBAAgB,GAC3B,QAAQ,cAAc,KACrB,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,oBAAoB,CAe/C,CAAC;AAsBH,eAAO,MAAM,kBAAkB,GAAI,CAAC,EAAE,CAAC,EACrC,MAAM,mBAAmB,EACzB,aAAa,CAAC,UAAU,EAAE,MAAM,KAAK,MAAM,CAAC,MAAM,CAAC,cAAc,EAAE,CAAC,EAAE,CAAC,CAAC,4CAwBtE,CAAC;AAEL,eAAO,MAAM,cAAc,GAAI,MAAM,mBAAmB,gIACV,CAAC"}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import * as Effect from "effect/Effect";
|
|
2
|
+
import * as Option from "effect/Option";
|
|
3
|
+
import * as Schema from "effect/Schema";
|
|
4
|
+
import { RegistryUrl } from "@agentxm/client-core/unstable/auth";
|
|
5
|
+
import { CliRenderer } from "@agentxm/client-core/unstable/cli-renderer";
|
|
6
|
+
import { makeCommandDocumentSchema } from "@agentxm/client-core/unstable/cli-runtime";
|
|
7
|
+
import { discover, } from "@agentxm/client-core/unstable/discover";
|
|
8
|
+
import { PackageUrlSchema } from "@agentxm/client-core/unstable/packaging";
|
|
9
|
+
import { createRegistryClient } from "@agentxm/client-core/unstable/registry";
|
|
10
|
+
const encodePurl = Schema.encodeSync(PackageUrlSchema);
|
|
11
|
+
const DiscoverExtensionSchema = Schema.Struct({
|
|
12
|
+
owner: Schema.String,
|
|
13
|
+
type: Schema.String,
|
|
14
|
+
name: Schema.String,
|
|
15
|
+
description: Schema.String,
|
|
16
|
+
latestVersion: Schema.String,
|
|
17
|
+
signal: Schema.String,
|
|
18
|
+
});
|
|
19
|
+
const DiscoverPackageItemSchema = Schema.Struct({
|
|
20
|
+
package: Schema.String,
|
|
21
|
+
extensions: Schema.Array(DiscoverExtensionSchema),
|
|
22
|
+
});
|
|
23
|
+
const DiscoverOutputFields = {
|
|
24
|
+
items: Schema.Array(DiscoverPackageItemSchema),
|
|
25
|
+
count: Schema.Number,
|
|
26
|
+
totalDetected: Schema.Number,
|
|
27
|
+
registryAvailable: Schema.Boolean,
|
|
28
|
+
};
|
|
29
|
+
export const DiscoverOutputSchema = makeCommandDocumentSchema("discover", DiscoverOutputFields);
|
|
30
|
+
const DiscoverTable = {
|
|
31
|
+
columns: {
|
|
32
|
+
package: { header: "Package" },
|
|
33
|
+
extension: { header: "Extension" },
|
|
34
|
+
signal: { header: "Signal" },
|
|
35
|
+
latestVersion: { header: "Latest" },
|
|
36
|
+
description: { header: "Description" },
|
|
37
|
+
},
|
|
38
|
+
};
|
|
39
|
+
const defaultRunDiscover = (projectDir) => Effect.gen(function* () {
|
|
40
|
+
const registryUrl = yield* RegistryUrl;
|
|
41
|
+
const registryClient = yield* createRegistryClient(registryUrl);
|
|
42
|
+
return yield* discover(projectDir, registryClient);
|
|
43
|
+
});
|
|
44
|
+
export const resolveDiscoverProjectDir = (path) => Option.getOrElse(path, () => process.cwd());
|
|
45
|
+
export const formatPackageName = (pkg) => {
|
|
46
|
+
const parts = pkg.detectedPackage;
|
|
47
|
+
if (parts.namespace !== undefined) {
|
|
48
|
+
return parts.version !== undefined
|
|
49
|
+
? `${parts.namespace}/${parts.name}@${parts.version}`
|
|
50
|
+
: `${parts.namespace}/${parts.name}`;
|
|
51
|
+
}
|
|
52
|
+
return parts.version !== undefined ? `${parts.name}@${parts.version}` : parts.name;
|
|
53
|
+
};
|
|
54
|
+
export const toDiscoverOutput = (result) => ({
|
|
55
|
+
items: result.packages.map((pkg) => ({
|
|
56
|
+
package: encodePurl(pkg.detectedPackage),
|
|
57
|
+
extensions: pkg.extensions.map((entry) => ({
|
|
58
|
+
owner: entry.extension.owner,
|
|
59
|
+
type: entry.extension.type,
|
|
60
|
+
name: entry.extension.name,
|
|
61
|
+
description: entry.extension.description,
|
|
62
|
+
latestVersion: entry.extension.latestVersion,
|
|
63
|
+
signal: entry.signal,
|
|
64
|
+
})),
|
|
65
|
+
})),
|
|
66
|
+
count: result.packages.length,
|
|
67
|
+
totalDetected: result.totalDetected,
|
|
68
|
+
registryAvailable: result.registryAvailable,
|
|
69
|
+
});
|
|
70
|
+
const toDiscoverTableRows = (result) => result.packages.flatMap((pkg) => pkg.extensions.map((entry) => ({
|
|
71
|
+
package: formatPackageName(pkg),
|
|
72
|
+
extension: `${entry.extension.owner}/${entry.extension.type}/${entry.extension.name}`,
|
|
73
|
+
signal: entry.signal,
|
|
74
|
+
latestVersion: entry.extension.latestVersion,
|
|
75
|
+
description: entry.extension.description,
|
|
76
|
+
})));
|
|
77
|
+
const formatSummary = (args, extensionCount) => {
|
|
78
|
+
const extensionLabel = extensionCount === 1 ? "extension" : "extensions";
|
|
79
|
+
const packageLabel = args.totalDetected === 1 ? "package" : "packages";
|
|
80
|
+
return `Found ${extensionCount} compatible ${extensionLabel} for ${args.count} of ${args.totalDetected} detected ${packageLabel}.`;
|
|
81
|
+
};
|
|
82
|
+
export const handleDiscoverWith = (args, runDiscover) => Effect.gen(function* () {
|
|
83
|
+
const renderer = yield* CliRenderer;
|
|
84
|
+
const projectDir = resolveDiscoverProjectDir(args.path);
|
|
85
|
+
const result = yield* runDiscover(projectDir);
|
|
86
|
+
const output = toDiscoverOutput(result);
|
|
87
|
+
if (yield* renderer.document("discover", output, DiscoverOutputFields)) {
|
|
88
|
+
return;
|
|
89
|
+
}
|
|
90
|
+
if (!result.registryAvailable) {
|
|
91
|
+
yield* renderer.warn("Registry unavailable. Showing local recommendations only.");
|
|
92
|
+
}
|
|
93
|
+
if (output.items.length === 0) {
|
|
94
|
+
yield* renderer.info("No compatible extensions found.");
|
|
95
|
+
return;
|
|
96
|
+
}
|
|
97
|
+
const rows = toDiscoverTableRows(result);
|
|
98
|
+
yield* renderer.table(rows, DiscoverTable, "Compatible extensions");
|
|
99
|
+
yield* renderer.success(formatSummary(output, rows.length));
|
|
100
|
+
});
|
|
101
|
+
export const handleDiscover = (args) => handleDiscoverWith(args, defaultRunDiscover);
|
|
102
|
+
//# sourceMappingURL=handler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AO;IACT,CAAC;IAED,IAAI,CAAC,MAAM,CAAC,iBAAiB,EAAE,CAAC;QAC9B,KAAK,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,2DAA2D,CAAC,CAAC;IACpF,CAAC;IAED,IAAI,MAAM,CAAC,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QAC9B,KAAK,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,iCAAiC,CAAC,CAAC;QACxD,OAAO;IACT,CAAC;IAED,MAAM,IAAI,GAAG,mBAAmB,CAAC,MAAM,CAAC,CAAC;IACzC,KAAK,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,IAAI,EAAE,aAAa,EAAE,uBAAuB,CAAC,CAAC;IACpE,KAAK,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,aAAa,CAAC,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;AAC9D,CAAC,CAAC,CAAC;AAEL,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,IAAyB,EAAE,EAAE,CAC1D,kBAAkB,CAAC,IAAI,EAAE,kBAAkB,CAAC,CAAC"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { Command } from "effect/unstable/cli";
|
|
2
|
+
export declare const doctorCommand: Command.Command<"doctor", 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=command.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"command.d.ts","sourceRoot":"","sources":["../../../../src/root/doctor/command.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAY9C,eAAO,MAAM,aAAa,0SAczB,CAAC"}
|