chatroom-cli 1.30.1 → 1.32.1
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/dist/api.d.ts +61 -0
- package/dist/api.d.ts.map +1 -0
- package/dist/api.js +10 -0
- package/dist/api.js.map +1 -0
- package/dist/commands/artifact/deps.d.ts +6 -0
- package/dist/commands/artifact/deps.d.ts.map +1 -0
- package/dist/commands/artifact/deps.js +2 -0
- package/dist/commands/artifact/deps.js.map +1 -0
- package/dist/commands/artifact/index.d.ts +43 -0
- package/dist/commands/artifact/index.d.ts.map +1 -0
- package/dist/commands/artifact/index.js +205 -0
- package/dist/commands/artifact/index.js.map +1 -0
- package/dist/commands/artifact/index.test.d.ts +8 -0
- package/dist/commands/artifact/index.test.d.ts.map +1 -0
- package/dist/commands/artifact/index.test.js +188 -0
- package/dist/commands/artifact/index.test.js.map +1 -0
- package/dist/commands/auth-login/deps.d.ts +50 -0
- package/dist/commands/auth-login/deps.d.ts.map +1 -0
- package/dist/commands/auth-login/deps.js +9 -0
- package/dist/commands/auth-login/deps.js.map +1 -0
- package/dist/commands/auth-login/index.d.ts +22 -0
- package/dist/commands/auth-login/index.d.ts.map +1 -0
- package/dist/commands/auth-login/index.js +246 -0
- package/dist/commands/auth-login/index.js.map +1 -0
- package/dist/commands/auth-login/index.test.d.ts +9 -0
- package/dist/commands/auth-login/index.test.d.ts.map +1 -0
- package/dist/commands/auth-login/index.test.js +297 -0
- package/dist/commands/auth-login/index.test.js.map +1 -0
- package/dist/commands/auth-logout/deps.d.ts +20 -0
- package/dist/commands/auth-logout/deps.d.ts.map +1 -0
- package/dist/commands/auth-logout/deps.js +7 -0
- package/dist/commands/auth-logout/deps.js.map +1 -0
- package/dist/commands/auth-logout/index.d.ts +8 -0
- package/dist/commands/auth-logout/index.d.ts.map +1 -0
- package/dist/commands/auth-logout/index.js +34 -0
- package/dist/commands/auth-logout/index.js.map +1 -0
- package/dist/commands/auth-logout/index.test.d.ts +8 -0
- package/dist/commands/auth-logout/index.test.d.ts.map +1 -0
- package/dist/commands/auth-logout/index.test.js +85 -0
- package/dist/commands/auth-logout/index.test.js.map +1 -0
- package/dist/commands/auth-status/deps.d.ts +35 -0
- package/dist/commands/auth-status/deps.d.ts.map +1 -0
- package/dist/commands/auth-status/deps.js +7 -0
- package/dist/commands/auth-status/deps.js.map +1 -0
- package/dist/commands/auth-status/index.d.ts +8 -0
- package/dist/commands/auth-status/index.d.ts.map +1 -0
- package/dist/commands/auth-status/index.js +80 -0
- package/dist/commands/auth-status/index.js.map +1 -0
- package/dist/commands/auth-status/index.test.d.ts +8 -0
- package/dist/commands/auth-status/index.test.d.ts.map +1 -0
- package/dist/commands/auth-status/index.test.js +116 -0
- package/dist/commands/auth-status/index.test.js.map +1 -0
- package/dist/commands/backlog/deps.d.ts +21 -0
- package/dist/commands/backlog/deps.d.ts.map +1 -0
- package/dist/commands/backlog/deps.js +5 -0
- package/dist/commands/backlog/deps.js.map +1 -0
- package/dist/commands/backlog/index.d.ts +129 -0
- package/dist/commands/backlog/index.d.ts.map +1 -0
- package/dist/commands/backlog/index.js +694 -0
- package/dist/commands/backlog/index.js.map +1 -0
- package/dist/commands/backlog/index.test.d.ts +7 -0
- package/dist/commands/backlog/index.test.d.ts.map +1 -0
- package/dist/commands/backlog/index.test.js +395 -0
- package/dist/commands/backlog/index.test.js.map +1 -0
- package/dist/commands/classify/deps.d.ts +18 -0
- package/dist/commands/classify/deps.d.ts.map +1 -0
- package/dist/commands/classify/deps.js +8 -0
- package/dist/commands/classify/deps.js.map +1 -0
- package/dist/commands/classify/index.d.ts +19 -0
- package/dist/commands/classify/index.d.ts.map +1 -0
- package/dist/commands/classify/index.js +162 -0
- package/dist/commands/classify/index.js.map +1 -0
- package/dist/commands/classify/index.test.d.ts +9 -0
- package/dist/commands/classify/index.test.d.ts.map +1 -0
- package/dist/commands/classify/index.test.js +263 -0
- package/dist/commands/classify/index.test.js.map +1 -0
- package/dist/commands/context/deps.d.ts +6 -0
- package/dist/commands/context/deps.d.ts.map +1 -0
- package/dist/commands/context/deps.js +2 -0
- package/dist/commands/context/deps.js.map +1 -0
- package/dist/commands/context/index.d.ts +42 -0
- package/dist/commands/context/index.d.ts.map +1 -0
- package/dist/commands/context/index.js +324 -0
- package/dist/commands/context/index.js.map +1 -0
- package/dist/commands/context/index.test.d.ts +9 -0
- package/dist/commands/context/index.test.d.ts.map +1 -0
- package/dist/commands/context/index.test.js +272 -0
- package/dist/commands/context/index.test.js.map +1 -0
- package/dist/commands/get-next-task/index.d.ts +20 -0
- package/dist/commands/get-next-task/index.d.ts.map +1 -0
- package/dist/commands/get-next-task/index.js +156 -0
- package/dist/commands/get-next-task/index.js.map +1 -0
- package/dist/commands/get-next-task/index.test.d.ts +9 -0
- package/dist/commands/get-next-task/index.test.d.ts.map +1 -0
- package/dist/commands/get-next-task/index.test.js +125 -0
- package/dist/commands/get-next-task/index.test.js.map +1 -0
- package/dist/commands/get-next-task/session.d.ts +127 -0
- package/dist/commands/get-next-task/session.d.ts.map +1 -0
- package/dist/commands/get-next-task/session.js +335 -0
- package/dist/commands/get-next-task/session.js.map +1 -0
- package/dist/commands/get-next-task/session.test.d.ts +11 -0
- package/dist/commands/get-next-task/session.test.d.ts.map +1 -0
- package/dist/commands/get-next-task/session.test.js +367 -0
- package/dist/commands/get-next-task/session.test.js.map +1 -0
- package/dist/commands/get-system-prompt/deps.d.ts +14 -0
- package/dist/commands/get-system-prompt/deps.d.ts.map +1 -0
- package/dist/commands/get-system-prompt/deps.js +7 -0
- package/dist/commands/get-system-prompt/deps.js.map +1 -0
- package/dist/commands/get-system-prompt/index.d.ts +16 -0
- package/dist/commands/get-system-prompt/index.d.ts.map +1 -0
- package/dist/commands/get-system-prompt/index.js +70 -0
- package/dist/commands/get-system-prompt/index.js.map +1 -0
- package/dist/commands/guidelines/deps.d.ts +14 -0
- package/dist/commands/guidelines/deps.d.ts.map +1 -0
- package/dist/commands/guidelines/deps.js +7 -0
- package/dist/commands/guidelines/deps.js.map +1 -0
- package/dist/commands/guidelines/index.d.ts +19 -0
- package/dist/commands/guidelines/index.d.ts.map +1 -0
- package/dist/commands/guidelines/index.js +92 -0
- package/dist/commands/guidelines/index.js.map +1 -0
- package/dist/commands/guidelines/index.test.d.ts +8 -0
- package/dist/commands/guidelines/index.test.d.ts.map +1 -0
- package/dist/commands/guidelines/index.test.js +140 -0
- package/dist/commands/guidelines/index.test.js.map +1 -0
- package/dist/commands/handoff/deps.d.ts +9 -0
- package/dist/commands/handoff/deps.d.ts.map +1 -0
- package/dist/commands/handoff/deps.js +5 -0
- package/dist/commands/handoff/deps.js.map +1 -0
- package/dist/commands/handoff/index.d.ts +23 -0
- package/dist/commands/handoff/index.d.ts.map +1 -0
- package/dist/commands/handoff/index.js +226 -0
- package/dist/commands/handoff/index.js.map +1 -0
- package/dist/commands/handoff/index.test.d.ts +9 -0
- package/dist/commands/handoff/index.test.d.ts.map +1 -0
- package/dist/commands/handoff/index.test.js +189 -0
- package/dist/commands/handoff/index.test.js.map +1 -0
- package/dist/commands/init/deps.d.ts +21 -0
- package/dist/commands/init/deps.d.ts.map +1 -0
- package/dist/commands/init/deps.js +8 -0
- package/dist/commands/init/deps.js.map +1 -0
- package/dist/commands/init/index.d.ts +22 -0
- package/dist/commands/init/index.d.ts.map +1 -0
- package/dist/commands/init/index.js +181 -0
- package/dist/commands/init/index.js.map +1 -0
- package/dist/commands/init/index.test.d.ts +8 -0
- package/dist/commands/init/index.test.d.ts.map +1 -0
- package/dist/commands/init/index.test.js +170 -0
- package/dist/commands/init/index.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/command-loop.d.ts +15 -0
- package/dist/commands/machine/daemon-start/command-loop.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/command-loop.js +295 -0
- package/dist/commands/machine/daemon-start/command-loop.js.map +1 -0
- package/dist/commands/machine/daemon-start/command-loop.test.d.ts +13 -0
- package/dist/commands/machine/daemon-start/command-loop.test.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/command-loop.test.js +156 -0
- package/dist/commands/machine/daemon-start/command-loop.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/command-sync-heartbeat.d.ts +12 -0
- package/dist/commands/machine/daemon-start/command-sync-heartbeat.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/command-sync-heartbeat.js +58 -0
- package/dist/commands/machine/daemon-start/command-sync-heartbeat.js.map +1 -0
- package/dist/commands/machine/daemon-start/deps.d.ts +85 -0
- package/dist/commands/machine/daemon-start/deps.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/deps.js +14 -0
- package/dist/commands/machine/daemon-start/deps.js.map +1 -0
- package/dist/commands/machine/daemon-start/event-bus.test.d.ts +2 -0
- package/dist/commands/machine/daemon-start/event-bus.test.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/event-bus.test.js +100 -0
- package/dist/commands/machine/daemon-start/event-bus.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/event-listeners.test.d.ts +2 -0
- package/dist/commands/machine/daemon-start/event-listeners.test.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/event-listeners.test.js +155 -0
- package/dist/commands/machine/daemon-start/event-listeners.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/file-content-fulfillment.d.ts +12 -0
- package/dist/commands/machine/daemon-start/file-content-fulfillment.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/file-content-fulfillment.js +120 -0
- package/dist/commands/machine/daemon-start/file-content-fulfillment.js.map +1 -0
- package/dist/commands/machine/daemon-start/file-content-subscription.d.ts +29 -0
- package/dist/commands/machine/daemon-start/file-content-subscription.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/file-content-subscription.js +55 -0
- package/dist/commands/machine/daemon-start/file-content-subscription.js.map +1 -0
- package/dist/commands/machine/daemon-start/file-tree-subscription.d.ts +22 -0
- package/dist/commands/machine/daemon-start/file-tree-subscription.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/file-tree-subscription.js +83 -0
- package/dist/commands/machine/daemon-start/file-tree-subscription.js.map +1 -0
- package/dist/commands/machine/daemon-start/git-heartbeat.d.ts +18 -0
- package/dist/commands/machine/daemon-start/git-heartbeat.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/git-heartbeat.js +218 -0
- package/dist/commands/machine/daemon-start/git-heartbeat.js.map +1 -0
- package/dist/commands/machine/daemon-start/git-subscription.d.ts +60 -0
- package/dist/commands/machine/daemon-start/git-subscription.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/git-subscription.js +389 -0
- package/dist/commands/machine/daemon-start/git-subscription.js.map +1 -0
- package/dist/commands/machine/daemon-start/git-subscription.test.d.ts +2 -0
- package/dist/commands/machine/daemon-start/git-subscription.test.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/git-subscription.test.js +103 -0
- package/dist/commands/machine/daemon-start/git-subscription.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/command-runner.d.ts +23 -0
- package/dist/commands/machine/daemon-start/handlers/command-runner.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/command-runner.js +236 -0
- package/dist/commands/machine/daemon-start/handlers/command-runner.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/ping.d.ts +6 -0
- package/dist/commands/machine/daemon-start/handlers/ping.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/ping.js +8 -0
- package/dist/commands/machine/daemon-start/handlers/ping.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/ping.test.d.ts +5 -0
- package/dist/commands/machine/daemon-start/handlers/ping.test.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/ping.test.js +23 -0
- package/dist/commands/machine/daemon-start/handlers/ping.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/shared.d.ts +11 -0
- package/dist/commands/machine/daemon-start/handlers/shared.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/shared.js +25 -0
- package/dist/commands/machine/daemon-start/handlers/shared.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/state-recovery.d.ts +19 -0
- package/dist/commands/machine/daemon-start/handlers/state-recovery.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/state-recovery.js +61 -0
- package/dist/commands/machine/daemon-start/handlers/state-recovery.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/state-recovery.test.d.ts +8 -0
- package/dist/commands/machine/daemon-start/handlers/state-recovery.test.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/state-recovery.test.js +98 -0
- package/dist/commands/machine/daemon-start/handlers/state-recovery.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/status.d.ts +6 -0
- package/dist/commands/machine/daemon-start/handlers/status.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/status.js +13 -0
- package/dist/commands/machine/daemon-start/handlers/status.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/status.test.d.ts +5 -0
- package/dist/commands/machine/daemon-start/handlers/status.test.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/status.test.js +51 -0
- package/dist/commands/machine/daemon-start/handlers/status.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/stop-agent.d.ts +21 -0
- package/dist/commands/machine/daemon-start/handlers/stop-agent.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/stop-agent.js +36 -0
- package/dist/commands/machine/daemon-start/handlers/stop-agent.js.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/stop-agent.test.d.ts +7 -0
- package/dist/commands/machine/daemon-start/handlers/stop-agent.test.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/handlers/stop-agent.test.js +135 -0
- package/dist/commands/machine/daemon-start/handlers/stop-agent.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/index.d.ts +16 -0
- package/dist/commands/machine/daemon-start/index.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/index.js +21 -0
- package/dist/commands/machine/daemon-start/index.js.map +1 -0
- package/dist/commands/machine/daemon-start/init.d.ts +23 -0
- package/dist/commands/machine/daemon-start/init.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/init.js +338 -0
- package/dist/commands/machine/daemon-start/init.js.map +1 -0
- package/dist/commands/machine/daemon-start/init.test.d.ts +8 -0
- package/dist/commands/machine/daemon-start/init.test.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/init.test.js +385 -0
- package/dist/commands/machine/daemon-start/init.test.js.map +1 -0
- package/dist/commands/machine/daemon-start/testing/index.d.ts +5 -0
- package/dist/commands/machine/daemon-start/testing/index.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/testing/index.js +5 -0
- package/dist/commands/machine/daemon-start/testing/index.js.map +1 -0
- package/dist/commands/machine/daemon-start/testing/mock-daemon-deps.d.ts +26 -0
- package/dist/commands/machine/daemon-start/testing/mock-daemon-deps.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/testing/mock-daemon-deps.js +68 -0
- package/dist/commands/machine/daemon-start/testing/mock-daemon-deps.js.map +1 -0
- package/dist/commands/machine/daemon-start/types.d.ts +89 -0
- package/dist/commands/machine/daemon-start/types.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/types.js +5 -0
- package/dist/commands/machine/daemon-start/types.js.map +1 -0
- package/dist/commands/machine/daemon-start/utils.d.ts +8 -0
- package/dist/commands/machine/daemon-start/utils.d.ts.map +1 -0
- package/dist/commands/machine/daemon-start/utils.js +10 -0
- package/dist/commands/machine/daemon-start/utils.js.map +1 -0
- package/dist/commands/machine/daemon-status.d.ts +10 -0
- package/dist/commands/machine/daemon-status.d.ts.map +1 -0
- package/dist/commands/machine/daemon-status.js +23 -0
- package/dist/commands/machine/daemon-status.js.map +1 -0
- package/dist/commands/machine/daemon-stop.d.ts +10 -0
- package/dist/commands/machine/daemon-stop.d.ts.map +1 -0
- package/dist/commands/machine/daemon-stop.js +44 -0
- package/dist/commands/machine/daemon-stop.js.map +1 -0
- package/dist/commands/machine/index.d.ts +9 -0
- package/dist/commands/machine/index.d.ts.map +1 -0
- package/dist/commands/machine/index.js +9 -0
- package/dist/commands/machine/index.js.map +1 -0
- package/dist/commands/machine/pid.d.ts +48 -0
- package/dist/commands/machine/pid.d.ts.map +1 -0
- package/dist/commands/machine/pid.js +141 -0
- package/dist/commands/machine/pid.js.map +1 -0
- package/dist/commands/messages/deps.d.ts +6 -0
- package/dist/commands/messages/deps.d.ts.map +1 -0
- package/dist/commands/messages/deps.js +2 -0
- package/dist/commands/messages/deps.js.map +1 -0
- package/dist/commands/messages/index.d.ts +28 -0
- package/dist/commands/messages/index.d.ts.map +1 -0
- package/dist/commands/messages/index.js +166 -0
- package/dist/commands/messages/index.js.map +1 -0
- package/dist/commands/messages/index.test.d.ts +8 -0
- package/dist/commands/messages/index.test.d.ts.map +1 -0
- package/dist/commands/messages/index.test.js +159 -0
- package/dist/commands/messages/index.test.js.map +1 -0
- package/dist/commands/opencode-install/deps.d.ts +32 -0
- package/dist/commands/opencode-install/deps.d.ts.map +1 -0
- package/dist/commands/opencode-install/deps.js +8 -0
- package/dist/commands/opencode-install/deps.js.map +1 -0
- package/dist/commands/opencode-install/index.d.ts +31 -0
- package/dist/commands/opencode-install/index.d.ts.map +1 -0
- package/dist/commands/opencode-install/index.js +440 -0
- package/dist/commands/opencode-install/index.js.map +1 -0
- package/dist/commands/opencode-install/index.test.d.ts +8 -0
- package/dist/commands/opencode-install/index.test.d.ts.map +1 -0
- package/dist/commands/opencode-install/index.test.js +123 -0
- package/dist/commands/opencode-install/index.test.js.map +1 -0
- package/dist/commands/register-agent/deps.d.ts +12 -0
- package/dist/commands/register-agent/deps.d.ts.map +1 -0
- package/dist/commands/register-agent/deps.js +8 -0
- package/dist/commands/register-agent/deps.js.map +1 -0
- package/dist/commands/register-agent/index.d.ts +15 -0
- package/dist/commands/register-agent/index.d.ts.map +1 -0
- package/dist/commands/register-agent/index.js +118 -0
- package/dist/commands/register-agent/index.js.map +1 -0
- package/dist/commands/register-agent/index.test.d.ts +9 -0
- package/dist/commands/register-agent/index.test.d.ts.map +1 -0
- package/dist/commands/register-agent/index.test.js +204 -0
- package/dist/commands/register-agent/index.test.js.map +1 -0
- package/dist/commands/report-progress/deps.d.ts +9 -0
- package/dist/commands/report-progress/deps.d.ts.map +1 -0
- package/dist/commands/report-progress/deps.js +5 -0
- package/dist/commands/report-progress/deps.js.map +1 -0
- package/dist/commands/report-progress/index.d.ts +14 -0
- package/dist/commands/report-progress/index.d.ts.map +1 -0
- package/dist/commands/report-progress/index.js +110 -0
- package/dist/commands/report-progress/index.js.map +1 -0
- package/dist/commands/report-progress/index.test.d.ts +8 -0
- package/dist/commands/report-progress/index.test.d.ts.map +1 -0
- package/dist/commands/report-progress/index.test.js +114 -0
- package/dist/commands/report-progress/index.test.js.map +1 -0
- package/dist/commands/skill/deps.d.ts +9 -0
- package/dist/commands/skill/deps.d.ts.map +1 -0
- package/dist/commands/skill/deps.js +5 -0
- package/dist/commands/skill/deps.js.map +1 -0
- package/dist/commands/skill/index.d.ts +20 -0
- package/dist/commands/skill/index.d.ts.map +1 -0
- package/dist/commands/skill/index.js +86 -0
- package/dist/commands/skill/index.js.map +1 -0
- package/dist/commands/skill/index.test.d.ts +8 -0
- package/dist/commands/skill/index.test.d.ts.map +1 -0
- package/dist/commands/skill/index.test.js +166 -0
- package/dist/commands/skill/index.test.js.map +1 -0
- package/dist/commands/task/read/deps.d.ts +18 -0
- package/dist/commands/task/read/deps.d.ts.map +1 -0
- package/dist/commands/task/read/deps.js +8 -0
- package/dist/commands/task/read/deps.js.map +1 -0
- package/dist/commands/task/read/index.d.ts +17 -0
- package/dist/commands/task/read/index.d.ts.map +1 -0
- package/dist/commands/task/read/index.js +144 -0
- package/dist/commands/task/read/index.js.map +1 -0
- package/dist/commands/telegram/deps.d.ts +13 -0
- package/dist/commands/telegram/deps.d.ts.map +1 -0
- package/dist/commands/telegram/deps.js +5 -0
- package/dist/commands/telegram/deps.js.map +1 -0
- package/dist/commands/telegram/index.d.ts +18 -0
- package/dist/commands/telegram/index.d.ts.map +1 -0
- package/dist/commands/telegram/index.js +94 -0
- package/dist/commands/telegram/index.js.map +1 -0
- package/dist/commands/update/deps.d.ts +21 -0
- package/dist/commands/update/deps.d.ts.map +1 -0
- package/dist/commands/update/deps.js +8 -0
- package/dist/commands/update/deps.js.map +1 -0
- package/dist/commands/update/index.d.ts +8 -0
- package/dist/commands/update/index.d.ts.map +1 -0
- package/dist/commands/update/index.js +70 -0
- package/dist/commands/update/index.js.map +1 -0
- package/dist/commands/update/index.test.d.ts +8 -0
- package/dist/commands/update/index.test.d.ts.map +1 -0
- package/dist/commands/update/index.test.js +108 -0
- package/dist/commands/update/index.test.js.map +1 -0
- package/dist/commands/workflow/deps.d.ts +9 -0
- package/dist/commands/workflow/deps.d.ts.map +1 -0
- package/dist/commands/workflow/deps.js +5 -0
- package/dist/commands/workflow/deps.js.map +1 -0
- package/dist/commands/workflow/index.d.ts +73 -0
- package/dist/commands/workflow/index.d.ts.map +1 -0
- package/dist/commands/workflow/index.js +545 -0
- package/dist/commands/workflow/index.js.map +1 -0
- package/dist/commands/workflow/index.test.d.ts +7 -0
- package/dist/commands/workflow/index.test.d.ts.map +1 -0
- package/dist/commands/workflow/index.test.js +315 -0
- package/dist/commands/workflow/index.test.js.map +1 -0
- package/dist/config/defaults.d.ts +10 -0
- package/dist/config/defaults.d.ts.map +1 -0
- package/dist/config/defaults.js +79 -0
- package/dist/config/defaults.js.map +1 -0
- package/dist/config/loader.d.ts +52 -0
- package/dist/config/loader.d.ts.map +1 -0
- package/dist/config/loader.js +202 -0
- package/dist/config/loader.js.map +1 -0
- package/dist/config/schema.d.ts +50 -0
- package/dist/config/schema.d.ts.map +1 -0
- package/dist/config/schema.js +99 -0
- package/dist/config/schema.js.map +1 -0
- package/dist/config.d.ts +14 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +14 -0
- package/dist/config.js.map +1 -0
- package/dist/events/daemon/agent/on-agent-exited.d.ts +26 -0
- package/dist/events/daemon/agent/on-agent-exited.d.ts.map +1 -0
- package/dist/events/daemon/agent/on-agent-exited.js +20 -0
- package/dist/events/daemon/agent/on-agent-exited.js.map +1 -0
- package/dist/events/daemon/agent/on-agent-started.d.ts +16 -0
- package/dist/events/daemon/agent/on-agent-started.d.ts.map +1 -0
- package/dist/events/daemon/agent/on-agent-started.js +11 -0
- package/dist/events/daemon/agent/on-agent-started.js.map +1 -0
- package/dist/events/daemon/agent/on-agent-stopped.d.ts +14 -0
- package/dist/events/daemon/agent/on-agent-stopped.d.ts.map +1 -0
- package/dist/events/daemon/agent/on-agent-stopped.js +11 -0
- package/dist/events/daemon/agent/on-agent-stopped.js.map +1 -0
- package/dist/events/daemon/agent/on-request-start-agent.d.ts +19 -0
- package/dist/events/daemon/agent/on-request-start-agent.d.ts.map +1 -0
- package/dist/events/daemon/agent/on-request-start-agent.js +55 -0
- package/dist/events/daemon/agent/on-request-start-agent.js.map +1 -0
- package/dist/events/daemon/agent/on-request-start-agent.test.d.ts +2 -0
- package/dist/events/daemon/agent/on-request-start-agent.test.d.ts.map +1 -0
- package/dist/events/daemon/agent/on-request-start-agent.test.js +96 -0
- package/dist/events/daemon/agent/on-request-start-agent.test.js.map +1 -0
- package/dist/events/daemon/agent/on-request-stop-agent.d.ts +16 -0
- package/dist/events/daemon/agent/on-request-stop-agent.d.ts.map +1 -0
- package/dist/events/daemon/agent/on-request-stop-agent.js +19 -0
- package/dist/events/daemon/agent/on-request-stop-agent.js.map +1 -0
- package/dist/events/daemon/event-bus.d.ts +87 -0
- package/dist/events/daemon/event-bus.d.ts.map +1 -0
- package/dist/events/daemon/event-bus.js +50 -0
- package/dist/events/daemon/event-bus.js.map +1 -0
- package/dist/events/daemon/register-listeners.d.ts +9 -0
- package/dist/events/daemon/register-listeners.d.ts.map +1 -0
- package/dist/events/daemon/register-listeners.js +21 -0
- package/dist/events/daemon/register-listeners.js.map +1 -0
- package/dist/events/lifecycle/on-daemon-shutdown.d.ts +9 -0
- package/dist/events/lifecycle/on-daemon-shutdown.d.ts.map +1 -0
- package/dist/events/lifecycle/on-daemon-shutdown.js +43 -0
- package/dist/events/lifecycle/on-daemon-shutdown.js.map +1 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +254 -30
- package/dist/index.js.map +1 -0
- package/dist/infrastructure/auth/middleware.d.ts +21 -0
- package/dist/infrastructure/auth/middleware.d.ts.map +1 -0
- package/dist/infrastructure/auth/middleware.js +106 -0
- package/dist/infrastructure/auth/middleware.js.map +1 -0
- package/dist/infrastructure/auth/storage.d.ts +59 -0
- package/dist/infrastructure/auth/storage.d.ts.map +1 -0
- package/dist/infrastructure/auth/storage.js +242 -0
- package/dist/infrastructure/auth/storage.js.map +1 -0
- package/dist/infrastructure/convex/client.d.ts +28 -0
- package/dist/infrastructure/convex/client.d.ts.map +1 -0
- package/dist/infrastructure/convex/client.js +77 -0
- package/dist/infrastructure/convex/client.js.map +1 -0
- package/dist/infrastructure/deps/backend.d.ts +13 -0
- package/dist/infrastructure/deps/backend.d.ts.map +1 -0
- package/dist/infrastructure/deps/backend.js +8 -0
- package/dist/infrastructure/deps/backend.js.map +1 -0
- package/dist/infrastructure/deps/clock.d.ts +13 -0
- package/dist/infrastructure/deps/clock.d.ts.map +1 -0
- package/dist/infrastructure/deps/clock.js +8 -0
- package/dist/infrastructure/deps/clock.js.map +1 -0
- package/dist/infrastructure/deps/fs.d.ts +12 -0
- package/dist/infrastructure/deps/fs.d.ts.map +1 -0
- package/dist/infrastructure/deps/fs.js +8 -0
- package/dist/infrastructure/deps/fs.js.map +1 -0
- package/dist/infrastructure/deps/index.d.ts +12 -0
- package/dist/infrastructure/deps/index.d.ts.map +1 -0
- package/dist/infrastructure/deps/index.js +8 -0
- package/dist/infrastructure/deps/index.js.map +1 -0
- package/dist/infrastructure/deps/process.d.ts +11 -0
- package/dist/infrastructure/deps/process.d.ts.map +1 -0
- package/dist/infrastructure/deps/process.js +8 -0
- package/dist/infrastructure/deps/process.js.map +1 -0
- package/dist/infrastructure/deps/session.d.ts +16 -0
- package/dist/infrastructure/deps/session.d.ts.map +1 -0
- package/dist/infrastructure/deps/session.js +8 -0
- package/dist/infrastructure/deps/session.js.map +1 -0
- package/dist/infrastructure/git/git-reader.d.ts +206 -0
- package/dist/infrastructure/git/git-reader.d.ts.map +1 -0
- package/dist/infrastructure/git/git-reader.js +711 -0
- package/dist/infrastructure/git/git-reader.js.map +1 -0
- package/dist/infrastructure/git/git-reader.test.d.ts +8 -0
- package/dist/infrastructure/git/git-reader.test.d.ts.map +1 -0
- package/dist/infrastructure/git/git-reader.test.js +598 -0
- package/dist/infrastructure/git/git-reader.test.js.map +1 -0
- package/dist/infrastructure/git/index.d.ts +9 -0
- package/dist/infrastructure/git/index.d.ts.map +1 -0
- package/dist/infrastructure/git/index.js +8 -0
- package/dist/infrastructure/git/index.js.map +1 -0
- package/dist/infrastructure/git/types.d.ts +102 -0
- package/dist/infrastructure/git/types.d.ts.map +1 -0
- package/dist/infrastructure/git/types.js +20 -0
- package/dist/infrastructure/git/types.js.map +1 -0
- package/dist/infrastructure/history/storage.d.ts +21 -0
- package/dist/infrastructure/history/storage.d.ts.map +1 -0
- package/dist/infrastructure/history/storage.js +56 -0
- package/dist/infrastructure/history/storage.js.map +1 -0
- package/dist/infrastructure/lifecycle-heartbeat.d.ts +18 -0
- package/dist/infrastructure/lifecycle-heartbeat.d.ts.map +1 -0
- package/dist/infrastructure/lifecycle-heartbeat.js +21 -0
- package/dist/infrastructure/lifecycle-heartbeat.js.map +1 -0
- package/dist/infrastructure/local-actions/execute-local-action.d.ts +30 -0
- package/dist/infrastructure/local-actions/execute-local-action.d.ts.map +1 -0
- package/dist/infrastructure/local-actions/execute-local-action.js +76 -0
- package/dist/infrastructure/local-actions/execute-local-action.js.map +1 -0
- package/dist/infrastructure/local-actions/index.d.ts +9 -0
- package/dist/infrastructure/local-actions/index.d.ts.map +1 -0
- package/dist/infrastructure/local-actions/index.js +8 -0
- package/dist/infrastructure/local-actions/index.js.map +1 -0
- package/dist/infrastructure/local-api/cors.d.ts +19 -0
- package/dist/infrastructure/local-api/cors.d.ts.map +1 -0
- package/dist/infrastructure/local-api/cors.js +50 -0
- package/dist/infrastructure/local-api/cors.js.map +1 -0
- package/dist/infrastructure/local-api/identity.test.d.ts +8 -0
- package/dist/infrastructure/local-api/identity.test.d.ts.map +1 -0
- package/dist/infrastructure/local-api/identity.test.js +71 -0
- package/dist/infrastructure/local-api/identity.test.js.map +1 -0
- package/dist/infrastructure/local-api/index.d.ts +10 -0
- package/dist/infrastructure/local-api/index.d.ts.map +1 -0
- package/dist/infrastructure/local-api/index.js +8 -0
- package/dist/infrastructure/local-api/index.js.map +1 -0
- package/dist/infrastructure/local-api/open-finder.test.d.ts +13 -0
- package/dist/infrastructure/local-api/open-finder.test.d.ts.map +1 -0
- package/dist/infrastructure/local-api/open-finder.test.js +112 -0
- package/dist/infrastructure/local-api/open-finder.test.js.map +1 -0
- package/dist/infrastructure/local-api/open-github-desktop.test.d.ts +12 -0
- package/dist/infrastructure/local-api/open-github-desktop.test.d.ts.map +1 -0
- package/dist/infrastructure/local-api/open-github-desktop.test.js +129 -0
- package/dist/infrastructure/local-api/open-github-desktop.test.js.map +1 -0
- package/dist/infrastructure/local-api/open-vscode.test.d.ts +12 -0
- package/dist/infrastructure/local-api/open-vscode.test.d.ts.map +1 -0
- package/dist/infrastructure/local-api/open-vscode.test.js +130 -0
- package/dist/infrastructure/local-api/open-vscode.test.js.map +1 -0
- package/dist/infrastructure/local-api/router.d.ts +28 -0
- package/dist/infrastructure/local-api/router.d.ts.map +1 -0
- package/dist/infrastructure/local-api/router.js +60 -0
- package/dist/infrastructure/local-api/router.js.map +1 -0
- package/dist/infrastructure/local-api/router.test.d.ts +8 -0
- package/dist/infrastructure/local-api/router.test.d.ts.map +1 -0
- package/dist/infrastructure/local-api/router.test.js +142 -0
- package/dist/infrastructure/local-api/router.test.js.map +1 -0
- package/dist/infrastructure/local-api/routes/identity.d.ts +28 -0
- package/dist/infrastructure/local-api/routes/identity.d.ts.map +1 -0
- package/dist/infrastructure/local-api/routes/identity.js +42 -0
- package/dist/infrastructure/local-api/routes/identity.js.map +1 -0
- package/dist/infrastructure/local-api/routes/open-finder.d.ts +25 -0
- package/dist/infrastructure/local-api/routes/open-finder.d.ts.map +1 -0
- package/dist/infrastructure/local-api/routes/open-finder.js +58 -0
- package/dist/infrastructure/local-api/routes/open-finder.js.map +1 -0
- package/dist/infrastructure/local-api/routes/open-github-desktop.d.ts +21 -0
- package/dist/infrastructure/local-api/routes/open-github-desktop.d.ts.map +1 -0
- package/dist/infrastructure/local-api/routes/open-github-desktop.js +43 -0
- package/dist/infrastructure/local-api/routes/open-github-desktop.js.map +1 -0
- package/dist/infrastructure/local-api/routes/open-vscode.d.ts +23 -0
- package/dist/infrastructure/local-api/routes/open-vscode.d.ts.map +1 -0
- package/dist/infrastructure/local-api/routes/open-vscode.js +51 -0
- package/dist/infrastructure/local-api/routes/open-vscode.js.map +1 -0
- package/dist/infrastructure/local-api/routes/shared-utils.d.ts +51 -0
- package/dist/infrastructure/local-api/routes/shared-utils.d.ts.map +1 -0
- package/dist/infrastructure/local-api/routes/shared-utils.js +96 -0
- package/dist/infrastructure/local-api/routes/shared-utils.js.map +1 -0
- package/dist/infrastructure/local-api/server.d.ts +40 -0
- package/dist/infrastructure/local-api/server.d.ts.map +1 -0
- package/dist/infrastructure/local-api/server.js +153 -0
- package/dist/infrastructure/local-api/server.js.map +1 -0
- package/dist/infrastructure/local-api/types.d.ts +48 -0
- package/dist/infrastructure/local-api/types.d.ts.map +1 -0
- package/dist/infrastructure/local-api/types.js +8 -0
- package/dist/infrastructure/local-api/types.js.map +1 -0
- package/dist/infrastructure/machine/crash-loop-tracker.d.ts +69 -0
- package/dist/infrastructure/machine/crash-loop-tracker.d.ts.map +1 -0
- package/dist/infrastructure/machine/crash-loop-tracker.js +116 -0
- package/dist/infrastructure/machine/crash-loop-tracker.js.map +1 -0
- package/dist/infrastructure/machine/crash-loop-tracker.test.d.ts +8 -0
- package/dist/infrastructure/machine/crash-loop-tracker.test.d.ts.map +1 -0
- package/dist/infrastructure/machine/crash-loop-tracker.test.js +210 -0
- package/dist/infrastructure/machine/crash-loop-tracker.test.js.map +1 -0
- package/dist/infrastructure/machine/daemon-state.d.ts +96 -0
- package/dist/infrastructure/machine/daemon-state.d.ts.map +1 -0
- package/dist/infrastructure/machine/daemon-state.js +183 -0
- package/dist/infrastructure/machine/daemon-state.js.map +1 -0
- package/dist/infrastructure/machine/daemon-state.test.d.ts +10 -0
- package/dist/infrastructure/machine/daemon-state.test.d.ts.map +1 -0
- package/dist/infrastructure/machine/daemon-state.test.js +128 -0
- package/dist/infrastructure/machine/daemon-state.test.js.map +1 -0
- package/dist/infrastructure/machine/detection.d.ts +27 -0
- package/dist/infrastructure/machine/detection.d.ts.map +1 -0
- package/dist/infrastructure/machine/detection.js +47 -0
- package/dist/infrastructure/machine/detection.js.map +1 -0
- package/dist/infrastructure/machine/index.d.ts +10 -0
- package/dist/infrastructure/machine/index.d.ts.map +1 -0
- package/dist/infrastructure/machine/index.js +11 -0
- package/dist/infrastructure/machine/index.js.map +1 -0
- package/dist/infrastructure/machine/stop-reason.d.ts +26 -0
- package/dist/infrastructure/machine/stop-reason.d.ts.map +1 -0
- package/dist/infrastructure/machine/stop-reason.js +22 -0
- package/dist/infrastructure/machine/stop-reason.js.map +1 -0
- package/dist/infrastructure/machine/stop-reason.test.d.ts +2 -0
- package/dist/infrastructure/machine/stop-reason.test.d.ts.map +1 -0
- package/dist/infrastructure/machine/stop-reason.test.js +32 -0
- package/dist/infrastructure/machine/stop-reason.test.js.map +1 -0
- package/dist/infrastructure/machine/storage.d.ts +42 -0
- package/dist/infrastructure/machine/storage.d.ts.map +1 -0
- package/dist/infrastructure/machine/storage.js +156 -0
- package/dist/infrastructure/machine/storage.js.map +1 -0
- package/dist/infrastructure/machine/types.d.ts +58 -0
- package/dist/infrastructure/machine/types.d.ts.map +1 -0
- package/dist/infrastructure/machine/types.js +11 -0
- package/dist/infrastructure/machine/types.js.map +1 -0
- package/dist/infrastructure/retry-queue.d.ts +17 -0
- package/dist/infrastructure/retry-queue.d.ts.map +1 -0
- package/dist/infrastructure/retry-queue.js +33 -0
- package/dist/infrastructure/retry-queue.js.map +1 -0
- package/dist/infrastructure/services/agent-process-manager/agent-process-manager.d.ts +142 -0
- package/dist/infrastructure/services/agent-process-manager/agent-process-manager.d.ts.map +1 -0
- package/dist/infrastructure/services/agent-process-manager/agent-process-manager.js +567 -0
- package/dist/infrastructure/services/agent-process-manager/agent-process-manager.js.map +1 -0
- package/dist/infrastructure/services/agent-process-manager/agent-process-manager.test.d.ts +2 -0
- package/dist/infrastructure/services/agent-process-manager/agent-process-manager.test.d.ts.map +1 -0
- package/dist/infrastructure/services/agent-process-manager/agent-process-manager.test.js +692 -0
- package/dist/infrastructure/services/agent-process-manager/agent-process-manager.test.js.map +1 -0
- package/dist/infrastructure/services/harness-spawning/harness-spawning-service.d.ts +47 -0
- package/dist/infrastructure/services/harness-spawning/harness-spawning-service.d.ts.map +1 -0
- package/dist/infrastructure/services/harness-spawning/harness-spawning-service.js +68 -0
- package/dist/infrastructure/services/harness-spawning/harness-spawning-service.js.map +1 -0
- package/dist/infrastructure/services/harness-spawning/harness-spawning-service.test.d.ts +2 -0
- package/dist/infrastructure/services/harness-spawning/harness-spawning-service.test.d.ts.map +1 -0
- package/dist/infrastructure/services/harness-spawning/harness-spawning-service.test.js +149 -0
- package/dist/infrastructure/services/harness-spawning/harness-spawning-service.test.js.map +1 -0
- package/dist/infrastructure/services/harness-spawning/index.d.ts +5 -0
- package/dist/infrastructure/services/harness-spawning/index.d.ts.map +1 -0
- package/dist/infrastructure/services/harness-spawning/index.js +3 -0
- package/dist/infrastructure/services/harness-spawning/index.js.map +1 -0
- package/dist/infrastructure/services/harness-spawning/rate-limiter.d.ts +45 -0
- package/dist/infrastructure/services/harness-spawning/rate-limiter.d.ts.map +1 -0
- package/dist/infrastructure/services/harness-spawning/rate-limiter.js +84 -0
- package/dist/infrastructure/services/harness-spawning/rate-limiter.js.map +1 -0
- package/dist/infrastructure/services/harness-spawning/rate-limiter.test.d.ts +2 -0
- package/dist/infrastructure/services/harness-spawning/rate-limiter.test.d.ts.map +1 -0
- package/dist/infrastructure/services/harness-spawning/rate-limiter.test.js +179 -0
- package/dist/infrastructure/services/harness-spawning/rate-limiter.test.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/base-cli-agent-service.d.ts +77 -0
- package/dist/infrastructure/services/remote-agents/base-cli-agent-service.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/base-cli-agent-service.js +149 -0
- package/dist/infrastructure/services/remote-agents/base-cli-agent-service.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/base-cli-agent-service.test.d.ts +2 -0
- package/dist/infrastructure/services/remote-agents/base-cli-agent-service.test.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/base-cli-agent-service.test.js +273 -0
- package/dist/infrastructure/services/remote-agents/base-cli-agent-service.test.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/claude/claude-code-agent-service.d.ts +30 -0
- package/dist/infrastructure/services/remote-agents/claude/claude-code-agent-service.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/claude/claude-code-agent-service.js +186 -0
- package/dist/infrastructure/services/remote-agents/claude/claude-code-agent-service.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/claude/claude-stream-reader.d.ts +42 -0
- package/dist/infrastructure/services/remote-agents/claude/claude-stream-reader.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/claude/claude-stream-reader.js +92 -0
- package/dist/infrastructure/services/remote-agents/claude/claude-stream-reader.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/claude/index.d.ts +2 -0
- package/dist/infrastructure/services/remote-agents/claude/index.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/claude/index.js +2 -0
- package/dist/infrastructure/services/remote-agents/claude/index.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-agent-service.d.ts +44 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-agent-service.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-agent-service.js +160 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-agent-service.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-stream-reader.d.ts +59 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-stream-reader.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-stream-reader.js +100 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-stream-reader.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-stream-reader.test.d.ts +2 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-stream-reader.test.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-stream-reader.test.js +105 -0
- package/dist/infrastructure/services/remote-agents/copilot/copilot-stream-reader.test.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/copilot/index.d.ts +3 -0
- package/dist/infrastructure/services/remote-agents/copilot/index.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/copilot/index.js +3 -0
- package/dist/infrastructure/services/remote-agents/copilot/index.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-agent-service.d.ts +29 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-agent-service.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-agent-service.js +219 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-agent-service.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-agent-service.test.d.ts +2 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-agent-service.test.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-agent-service.test.js +223 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-agent-service.test.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-stream-reader.d.ts +41 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-stream-reader.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-stream-reader.js +95 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-stream-reader.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-stream-reader.test.d.ts +2 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-stream-reader.test.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-stream-reader.test.js +334 -0
- package/dist/infrastructure/services/remote-agents/cursor/cursor-stream-reader.test.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/index.d.ts +3 -0
- package/dist/infrastructure/services/remote-agents/cursor/index.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/cursor/index.js +2 -0
- package/dist/infrastructure/services/remote-agents/cursor/index.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/index.d.ts +8 -0
- package/dist/infrastructure/services/remote-agents/index.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/index.js +7 -0
- package/dist/infrastructure/services/remote-agents/index.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/init-registry.d.ts +3 -0
- package/dist/infrastructure/services/remote-agents/init-registry.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/init-registry.js +19 -0
- package/dist/infrastructure/services/remote-agents/init-registry.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/index.d.ts +4 -0
- package/dist/infrastructure/services/remote-agents/opencode/index.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/index.js +3 -0
- package/dist/infrastructure/services/remote-agents/opencode/index.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-agent-service.d.ts +32 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-agent-service.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-agent-service.js +225 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-agent-service.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-agent-service.test.d.ts +2 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-agent-service.test.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-agent-service.test.js +226 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-agent-service.test.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-json-reader.d.ts +46 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-json-reader.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-json-reader.js +104 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-json-reader.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-json-reader.test.d.ts +2 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-json-reader.test.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-json-reader.test.js +268 -0
- package/dist/infrastructure/services/remote-agents/opencode/opencode-json-reader.test.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/index.d.ts +3 -0
- package/dist/infrastructure/services/remote-agents/pi/index.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/index.js +2 -0
- package/dist/infrastructure/services/remote-agents/pi/index.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-agent-service.d.ts +35 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-agent-service.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-agent-service.js +253 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-agent-service.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-agent-service.test.d.ts +2 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-agent-service.test.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-agent-service.test.js +348 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-agent-service.test.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-rpc-reader.d.ts +50 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-rpc-reader.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-rpc-reader.js +120 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-rpc-reader.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-rpc-reader.test.d.ts +2 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-rpc-reader.test.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-rpc-reader.test.js +288 -0
- package/dist/infrastructure/services/remote-agents/pi/pi-rpc-reader.test.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/registry.d.ts +8 -0
- package/dist/infrastructure/services/remote-agents/registry.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/registry.js +14 -0
- package/dist/infrastructure/services/remote-agents/registry.js.map +1 -0
- package/dist/infrastructure/services/remote-agents/remote-agent-service.d.ts +79 -0
- package/dist/infrastructure/services/remote-agents/remote-agent-service.d.ts.map +1 -0
- package/dist/infrastructure/services/remote-agents/remote-agent-service.js +9 -0
- package/dist/infrastructure/services/remote-agents/remote-agent-service.js.map +1 -0
- package/dist/infrastructure/services/workspace/command-discovery.d.ts +65 -0
- package/dist/infrastructure/services/workspace/command-discovery.d.ts.map +1 -0
- package/dist/infrastructure/services/workspace/command-discovery.js +193 -0
- package/dist/infrastructure/services/workspace/command-discovery.js.map +1 -0
- package/dist/infrastructure/services/workspace/command-discovery.test.d.ts +7 -0
- package/dist/infrastructure/services/workspace/command-discovery.test.d.ts.map +1 -0
- package/dist/infrastructure/services/workspace/command-discovery.test.js +182 -0
- package/dist/infrastructure/services/workspace/command-discovery.test.js.map +1 -0
- package/dist/infrastructure/services/workspace/file-tree-scanner.d.ts +47 -0
- package/dist/infrastructure/services/workspace/file-tree-scanner.d.ts.map +1 -0
- package/dist/infrastructure/services/workspace/file-tree-scanner.js +159 -0
- package/dist/infrastructure/services/workspace/file-tree-scanner.js.map +1 -0
- package/dist/infrastructure/services/workspace/file-tree-scanner.test.d.ts +2 -0
- package/dist/infrastructure/services/workspace/file-tree-scanner.test.d.ts.map +1 -0
- package/dist/infrastructure/services/workspace/file-tree-scanner.test.js +132 -0
- package/dist/infrastructure/services/workspace/file-tree-scanner.test.js.map +1 -0
- package/dist/infrastructure/services/workspace/workspace-resolver.d.ts +34 -0
- package/dist/infrastructure/services/workspace/workspace-resolver.d.ts.map +1 -0
- package/dist/infrastructure/services/workspace/workspace-resolver.js +187 -0
- package/dist/infrastructure/services/workspace/workspace-resolver.js.map +1 -0
- package/dist/infrastructure/services/workspace/workspace-resolver.test.d.ts +5 -0
- package/dist/infrastructure/services/workspace/workspace-resolver.test.d.ts.map +1 -0
- package/dist/infrastructure/services/workspace/workspace-resolver.test.js +152 -0
- package/dist/infrastructure/services/workspace/workspace-resolver.test.js.map +1 -0
- package/dist/tools/index.d.ts +7 -0
- package/dist/tools/index.d.ts.map +1 -0
- package/dist/tools/index.js +5 -0
- package/dist/tools/index.js.map +1 -0
- package/dist/tools/output.d.ts +50 -0
- package/dist/tools/output.d.ts.map +1 -0
- package/dist/tools/output.js +78 -0
- package/dist/tools/output.js.map +1 -0
- package/dist/tools/output.test.d.ts +8 -0
- package/dist/tools/output.test.d.ts.map +1 -0
- package/dist/tools/output.test.js +120 -0
- package/dist/tools/output.test.js.map +1 -0
- package/dist/tools/parse-pdf/deps.d.ts +42 -0
- package/dist/tools/parse-pdf/deps.d.ts.map +1 -0
- package/dist/tools/parse-pdf/deps.js +8 -0
- package/dist/tools/parse-pdf/deps.js.map +1 -0
- package/dist/tools/parse-pdf/index.d.ts +18 -0
- package/dist/tools/parse-pdf/index.d.ts.map +1 -0
- package/dist/tools/parse-pdf/index.js +160 -0
- package/dist/tools/parse-pdf/index.js.map +1 -0
- package/dist/tools/parse-pdf/index.test.d.ts +8 -0
- package/dist/tools/parse-pdf/index.test.d.ts.map +1 -0
- package/dist/tools/parse-pdf/index.test.js +183 -0
- package/dist/tools/parse-pdf/index.test.js.map +1 -0
- package/dist/tools/types.d.ts +12 -0
- package/dist/tools/types.d.ts.map +1 -0
- package/dist/tools/types.js +5 -0
- package/dist/tools/types.js.map +1 -0
- package/dist/utils/convex-error.d.ts +19 -0
- package/dist/utils/convex-error.d.ts.map +1 -0
- package/dist/utils/convex-error.js +38 -0
- package/dist/utils/convex-error.js.map +1 -0
- package/dist/utils/convex-error.test.d.ts +7 -0
- package/dist/utils/convex-error.test.d.ts.map +1 -0
- package/dist/utils/convex-error.test.js +71 -0
- package/dist/utils/convex-error.test.js.map +1 -0
- package/dist/utils/error-formatting.d.ts +33 -0
- package/dist/utils/error-formatting.d.ts.map +1 -0
- package/dist/utils/error-formatting.js +96 -0
- package/dist/utils/error-formatting.js.map +1 -0
- package/dist/utils/file-content.d.ts +24 -0
- package/dist/utils/file-content.d.ts.map +1 -0
- package/dist/utils/file-content.js +35 -0
- package/dist/utils/file-content.js.map +1 -0
- package/dist/utils/serialization/decode/index.d.ts +71 -0
- package/dist/utils/serialization/decode/index.d.ts.map +1 -0
- package/dist/utils/serialization/decode/index.js +167 -0
- package/dist/utils/serialization/decode/index.js.map +1 -0
- package/dist/utils/serialization/decode/index.test.d.ts +5 -0
- package/dist/utils/serialization/decode/index.test.d.ts.map +1 -0
- package/dist/utils/serialization/decode/index.test.js +226 -0
- package/dist/utils/serialization/decode/index.test.js.map +1 -0
- package/dist/utils/stdin.d.ts +6 -0
- package/dist/utils/stdin.d.ts.map +1 -0
- package/dist/utils/stdin.js +19 -0
- package/dist/utils/stdin.js.map +1 -0
- package/dist/utils/terminal-safety.d.ts +7 -0
- package/dist/utils/terminal-safety.d.ts.map +1 -0
- package/dist/utils/terminal-safety.js +17 -0
- package/dist/utils/terminal-safety.js.map +1 -0
- package/dist/version.d.ts +14 -0
- package/dist/version.d.ts.map +1 -0
- package/dist/version.js +43 -0
- package/dist/version.js.map +1 -0
- package/package.json +2 -2
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Telegram CLI Commands — send messages to Telegram via chatroom integrations.
|
|
3
|
+
*
|
|
4
|
+
* Allows agents to push messages to connected Telegram chats.
|
|
5
|
+
*/
|
|
6
|
+
import { ConvexError } from 'convex/values';
|
|
7
|
+
import { api } from '../../api.js';
|
|
8
|
+
import { getSessionId, getOtherSessionUrls } from '../../infrastructure/auth/storage.js';
|
|
9
|
+
import { getConvexClient, getConvexUrl } from '../../infrastructure/convex/client.js';
|
|
10
|
+
import { formatError, formatAuthError, formatChatroomIdError, } from '../../utils/error-formatting.js';
|
|
11
|
+
// ─── Default Deps Factory ──────────────────────────────────────────────────
|
|
12
|
+
async function createDefaultDeps() {
|
|
13
|
+
const client = await getConvexClient();
|
|
14
|
+
return {
|
|
15
|
+
backend: {
|
|
16
|
+
action: (endpoint, args) => client.action(endpoint, args),
|
|
17
|
+
},
|
|
18
|
+
session: {
|
|
19
|
+
getSessionId,
|
|
20
|
+
getConvexUrl,
|
|
21
|
+
getOtherSessionUrls,
|
|
22
|
+
},
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
// ─── Commands ──────────────────────────────────────────────────────────────
|
|
26
|
+
/**
|
|
27
|
+
* Send a message to a connected Telegram integration for a chatroom.
|
|
28
|
+
*/
|
|
29
|
+
export async function sendMessage(options, deps) {
|
|
30
|
+
const d = deps ?? (await createDefaultDeps());
|
|
31
|
+
// Get session ID for authentication
|
|
32
|
+
const sessionId = d.session.getSessionId();
|
|
33
|
+
if (!sessionId) {
|
|
34
|
+
const otherUrls = d.session.getOtherSessionUrls();
|
|
35
|
+
const currentUrl = d.session.getConvexUrl();
|
|
36
|
+
formatAuthError(currentUrl, otherUrls);
|
|
37
|
+
process.exit(1);
|
|
38
|
+
return;
|
|
39
|
+
}
|
|
40
|
+
// Validate chatroom ID format
|
|
41
|
+
const { chatroomId } = options;
|
|
42
|
+
if (!chatroomId ||
|
|
43
|
+
typeof chatroomId !== 'string' ||
|
|
44
|
+
chatroomId.length < 20 ||
|
|
45
|
+
chatroomId.length > 40) {
|
|
46
|
+
formatChatroomIdError(chatroomId);
|
|
47
|
+
process.exit(1);
|
|
48
|
+
return;
|
|
49
|
+
}
|
|
50
|
+
// Validate message is not empty
|
|
51
|
+
if (!options.message || options.message.trim().length === 0) {
|
|
52
|
+
formatError('Message cannot be empty', [
|
|
53
|
+
'Provide a message via --message flag',
|
|
54
|
+
'Example: chatroom telegram send-message --chatroom-id=<id> --integration-id=<id> --message="Hello"',
|
|
55
|
+
]);
|
|
56
|
+
process.exit(1);
|
|
57
|
+
return;
|
|
58
|
+
}
|
|
59
|
+
const senderRole = options.role || 'user';
|
|
60
|
+
try {
|
|
61
|
+
const result = await d.backend.action(api.integrations.telegram.actions.sendMessage, {
|
|
62
|
+
sessionId,
|
|
63
|
+
chatroomId: chatroomId,
|
|
64
|
+
message: options.message,
|
|
65
|
+
senderRole,
|
|
66
|
+
});
|
|
67
|
+
if (result?.success) {
|
|
68
|
+
console.log('✅ Message sent to Telegram');
|
|
69
|
+
console.log(`📨 "${options.message}"`);
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
catch (error) {
|
|
73
|
+
console.error('\n❌ ERROR: Failed to send message to Telegram');
|
|
74
|
+
if (error instanceof ConvexError) {
|
|
75
|
+
const errorData = error.data;
|
|
76
|
+
console.error(`\n${errorData.message || 'An unexpected error occurred'}`);
|
|
77
|
+
if (process.env.CHATROOM_DEBUG === 'true') {
|
|
78
|
+
console.error('\n🔍 Debug Info:');
|
|
79
|
+
console.error(JSON.stringify(errorData, null, 2));
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
else {
|
|
83
|
+
console.error(`\n${error instanceof Error ? error.message : String(error)}`);
|
|
84
|
+
if (process.env.CHATROOM_DEBUG === 'true') {
|
|
85
|
+
console.error('\n🔍 Debug Info:');
|
|
86
|
+
console.error(error);
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
console.error('\n📚 Need help? Run:');
|
|
90
|
+
console.error(' chatroom telegram send-message --help');
|
|
91
|
+
process.exit(1);
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/commands/telegram/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAG5C,OAAO,EAAE,GAAG,EAAE,MAAM,cAAc,CAAC;AAEnC,OAAO,EAAE,YAAY,EAAE,mBAAmB,EAAE,MAAM,sCAAsC,CAAC;AACzF,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,uCAAuC,CAAC;AACtF,OAAO,EACL,WAAW,EACX,eAAe,EACf,qBAAqB,GACtB,MAAM,iCAAiC,CAAC;AAezC,8EAA8E;AAE9E,KAAK,UAAU,iBAAiB;IAC9B,MAAM,MAAM,GAAG,MAAM,eAAe,EAAE,CAAC;IACvC,OAAO;QACL,OAAO,EAAE;YACP,MAAM,EAAE,CAAC,QAAQ,EAAE,IAAI,EAAE,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAE,IAAI,CAAC;SAC1D;QACD,OAAO,EAAE;YACP,YAAY;YACZ,YAAY;YACZ,mBAAmB;SACpB;KACF,CAAC;AACJ,CAAC;AAED,8EAA8E;AAE9E;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,WAAW,CAC/B,OAAmC,EACnC,IAAmB;IAEnB,MAAM,CAAC,GAAG,IAAI,IAAI,CAAC,MAAM,iBAAiB,EAAE,CAAC,CAAC;IAE9C,oCAAoC;IACpC,MAAM,SAAS,GAAG,CAAC,CAAC,OAAO,CAAC,YAAY,EAAE,CAAC;IAC3C,IAAI,CAAC,SAAS,EAAE,CAAC;QACf,MAAM,SAAS,GAAG,CAAC,CAAC,OAAO,CAAC,mBAAmB,EAAE,CAAC;QAClD,MAAM,UAAU,GAAG,CAAC,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H,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,CAAC,KAAK,CAAC,+CAA+C,CAAC,CAAC;QAE/D,IAAI,KAAK,YAAY,WAAW,EAAE,CAAC;YACjC,MAAM,SAAS,GAAG,KAAK,CAAC,IAA2C,CAAC;YACpE,OAAO,CAAC,KAAK,CAAC,KAAK,SAAS,CAAC,OAAO,IAAI,8BAA8B,EAAE,CAAC,CAAC;YAE1E,IAAI,OAAO,CAAC,GAAG,CAAC,cAAc,KAAK,MAAM,EAAE,CAAC;gBAC1C,OAAO,CAAC,KAAK,CAAC,kBAAkB,CAAC,CAAC;gBAClC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;YACpD,CAAC;QACH,CAAC;aAAM,CAAC;YACN,OAAO,CAAC,KAAK,CAAC,KAAK,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;YAE7E,IAAI,OAAO,CAAC,GAAG,CAAC,cAAc,KAAK,MAAM,EAAE,CAAC;gBAC1C,OAAO,CAAC,KAAK,CAAC,kBAAkB,CAAC,CAAC;gBAClC,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;YACvB,CAAC;QACH,CAAC;QAED,OAAO,CAAC,KAAK,CAAC,sBAAsB,CAAC,CAAC;QACtC,OAAO,CAAC,KAAK,CAAC,0CAA0C,CAAC,CAAC;QAC1D,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Update Deps — dependency interfaces for the update command.
|
|
3
|
+
*
|
|
4
|
+
* The update command checks npm and runs install - it does not use
|
|
5
|
+
* BackendOps or SessionOps. Uses getVersion and exec for testability.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Exec result from running a shell command
|
|
9
|
+
*/
|
|
10
|
+
export interface ExecResult {
|
|
11
|
+
stdout: string;
|
|
12
|
+
stderr?: string;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* All external dependencies for the update command.
|
|
16
|
+
*/
|
|
17
|
+
export interface UpdateDeps {
|
|
18
|
+
getVersion: () => string;
|
|
19
|
+
exec: (cmd: string) => Promise<ExecResult>;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=deps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deps.d.ts","sourceRoot":"","sources":["../../../src/commands/update/deps.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,UAAU,EAAE,MAAM,MAAM,CAAC;IACzB,IAAI,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,OAAO,CAAC,UAAU,CAAC,CAAC;CAC5C"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deps.js","sourceRoot":"","sources":["../../../src/commands/update/deps.ts"],"names":[],"mappings":"AAAA;;;;;GAKG"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Update command
|
|
3
|
+
* Updates the chatroom CLI to the latest version
|
|
4
|
+
*/
|
|
5
|
+
import type { UpdateDeps } from './deps.js';
|
|
6
|
+
export type { UpdateDeps } from './deps.js';
|
|
7
|
+
export declare function update(deps?: UpdateDeps): Promise<void>;
|
|
8
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/commands/update/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAKH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAO5C,YAAY,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAc5C,wBAAsB,MAAM,CAAC,IAAI,CAAC,EAAE,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC,CA4D7D"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Update command
|
|
3
|
+
* Updates the chatroom CLI to the latest version
|
|
4
|
+
*/
|
|
5
|
+
import { exec } from 'node:child_process';
|
|
6
|
+
import { promisify } from 'node:util';
|
|
7
|
+
import { getVersion } from '../../version.js';
|
|
8
|
+
const execAsync = promisify(exec);
|
|
9
|
+
// ─── Default Deps Factory ──────────────────────────────────────────────────
|
|
10
|
+
function createDefaultDeps() {
|
|
11
|
+
return {
|
|
12
|
+
getVersion,
|
|
13
|
+
exec: (cmd) => execAsync(cmd).then((r) => ({ stdout: r.stdout ?? '', stderr: r.stderr })),
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
// ─── Entry Point ───────────────────────────────────────────────────────────
|
|
17
|
+
export async function update(deps) {
|
|
18
|
+
const d = deps ?? createDefaultDeps();
|
|
19
|
+
const log = console.log.bind(console);
|
|
20
|
+
log('\n🔄 Checking for updates...\n');
|
|
21
|
+
// Check if npm is available
|
|
22
|
+
try {
|
|
23
|
+
await d.exec('npm --version');
|
|
24
|
+
}
|
|
25
|
+
catch {
|
|
26
|
+
console.error('❌ npm is not available. Please install npm to update.');
|
|
27
|
+
process.exit(1);
|
|
28
|
+
return;
|
|
29
|
+
}
|
|
30
|
+
const currentVersion = d.getVersion();
|
|
31
|
+
log(` Current version: ${currentVersion}`);
|
|
32
|
+
// Check latest version
|
|
33
|
+
let latestVersion = null;
|
|
34
|
+
try {
|
|
35
|
+
const { stdout } = await d.exec('npm view chatroom-cli version');
|
|
36
|
+
latestVersion = stdout.trim() || null;
|
|
37
|
+
}
|
|
38
|
+
catch {
|
|
39
|
+
latestVersion = null;
|
|
40
|
+
}
|
|
41
|
+
if (!latestVersion) {
|
|
42
|
+
console.error('❌ Could not check for latest version.');
|
|
43
|
+
console.error(' You can manually update with: npm install -g chatroom-cli@latest');
|
|
44
|
+
process.exit(1);
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
log(` Latest version: ${latestVersion}`);
|
|
48
|
+
if (currentVersion === latestVersion) {
|
|
49
|
+
log('\n✅ You already have the latest version!');
|
|
50
|
+
return;
|
|
51
|
+
}
|
|
52
|
+
log('\n📦 Updating to latest version...\n');
|
|
53
|
+
try {
|
|
54
|
+
const { stdout } = await d.exec('npm install -g chatroom-cli@latest');
|
|
55
|
+
if (stdout) {
|
|
56
|
+
log(stdout);
|
|
57
|
+
}
|
|
58
|
+
log('\n✅ Successfully updated chatroom-cli!');
|
|
59
|
+
log(` ${currentVersion} → ${latestVersion}`);
|
|
60
|
+
}
|
|
61
|
+
catch (error) {
|
|
62
|
+
const err = error;
|
|
63
|
+
console.error(`\n❌ Update failed: ${err.message}`);
|
|
64
|
+
console.error('\n Try running manually with sudo:');
|
|
65
|
+
console.error(' sudo npm install -g chatroom-cli@latest');
|
|
66
|
+
process.exit(1);
|
|
67
|
+
return;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/commands/update/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAC1C,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAGtC,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAE9C,MAAM,SAAS,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC;AAMlC,8EAA8E;AAE9E,SAAS,iBAAiB;IACxB,OAAO;QACL,UAAU;QACV,IAAI,EAAE,CAAC,GAAW,EAAE,EAAE,C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,IAAI,CAAC,CAAC,CAAC,CAAC;QAChB,OAAO;IACT,CAAC;IAED,GAAG,CAAC,uBAAuB,aAAa,EAAE,CAAC,CAAC;IAE5C,IAAI,cAAc,KAAK,aAAa,EAAE,CAAC;QACrC,GAAG,CAAC,0CAA0C,CAAC,CAAC;QAChD,OAAO;IACT,CAAC;IAED,GAAG,CAAC,sCAAsC,CAAC,CAAC;IAE5C,IAAI,CAAC;QACH,MAAM,EAAE,MAAM,EAAE,GAAG,MAAM,CAAC,CAAC,IAAI,CAAC,oCAAoC,CAAC,CAAC;QAEtE,IAAI,MAAM,EAAE,CAAC;YACX,GAAG,CAAC,MAAM,CAAC,CAAC;QACd,CAAC;QAED,GAAG,CAAC,wCAAwC,CAAC,CAAC;QAC9C,GAAG,CAAC,MAAM,cAAc,MAAM,aAAa,EAAE,CAAC,CAAC;IACjD,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,GAAG,GAAG,KAAc,CAAC;QAC3B,OAAO,CAAC,KAAK,CAAC,sBAAsB,GAAG,CAAC,OAAO,EAAE,CAAC,CAAC;QACnD,OAAO,CAAC,KAAK,CAAC,sCAAsC,CAAC,CAAC;QACtD,OAAO,CAAC,KAAK,CAAC,4CAA4C,CAAC,CAAC;QAC5D,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAChB,OAAO;IACT,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.test.d.ts","sourceRoot":"","sources":["../../../src/commands/update/index.test.ts"],"names":[],"mappings":"AAAA;;;;;GAKG"}
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* update Unit Tests
|
|
3
|
+
*
|
|
4
|
+
* Tests the update command using injected dependencies.
|
|
5
|
+
* Covers: auth test (exits 1 - npm not available), success test, error test.
|
|
6
|
+
*/
|
|
7
|
+
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
|
|
8
|
+
import { update } from './index.js';
|
|
9
|
+
// ---------------------------------------------------------------------------
|
|
10
|
+
// Helpers
|
|
11
|
+
// ---------------------------------------------------------------------------
|
|
12
|
+
function createMockDeps(overrides) {
|
|
13
|
+
return {
|
|
14
|
+
getVersion: vi.fn().mockReturnValue('1.0.0'),
|
|
15
|
+
exec: vi.fn().mockResolvedValue({ stdout: '2.0.0', stderr: '' }),
|
|
16
|
+
...overrides,
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
// ---------------------------------------------------------------------------
|
|
20
|
+
// Setup / Teardown
|
|
21
|
+
// ---------------------------------------------------------------------------
|
|
22
|
+
let exitSpy;
|
|
23
|
+
let logSpy;
|
|
24
|
+
let errorSpy;
|
|
25
|
+
beforeEach(() => {
|
|
26
|
+
exitSpy = vi.spyOn(process, 'exit').mockImplementation((() => { }));
|
|
27
|
+
logSpy = vi.spyOn(console, 'log').mockImplementation(() => { });
|
|
28
|
+
errorSpy = vi.spyOn(console, 'error').mockImplementation(() => { });
|
|
29
|
+
});
|
|
30
|
+
afterEach(() => {
|
|
31
|
+
vi.restoreAllMocks();
|
|
32
|
+
});
|
|
33
|
+
function getAllLogOutput() {
|
|
34
|
+
return logSpy.mock.calls.map((c) => c.join(' ')).join('\n');
|
|
35
|
+
}
|
|
36
|
+
function getAllErrorOutput() {
|
|
37
|
+
return errorSpy.mock.calls.map((c) => c.join(' ')).join('\n');
|
|
38
|
+
}
|
|
39
|
+
// ---------------------------------------------------------------------------
|
|
40
|
+
// Tests
|
|
41
|
+
// ---------------------------------------------------------------------------
|
|
42
|
+
describe('update', () => {
|
|
43
|
+
describe('authentication / preconditions', () => {
|
|
44
|
+
it('exits with code 1 when npm is not available', async () => {
|
|
45
|
+
const deps = createMockDeps({
|
|
46
|
+
exec: vi.fn().mockRejectedValue(new Error('npm not found')),
|
|
47
|
+
});
|
|
48
|
+
await update(deps);
|
|
49
|
+
expect(exitSpy).toHaveBeenCalledWith(1);
|
|
50
|
+
expect(getAllErrorOutput()).toContain('npm is not available');
|
|
51
|
+
});
|
|
52
|
+
it('exits with code 1 when cannot check latest version', async () => {
|
|
53
|
+
const deps = createMockDeps({
|
|
54
|
+
exec: vi
|
|
55
|
+
.fn()
|
|
56
|
+
.mockResolvedValueOnce({ stdout: '9.0.0', stderr: '' }) // npm --version
|
|
57
|
+
.mockRejectedValueOnce(new Error('Network error')), // npm view
|
|
58
|
+
});
|
|
59
|
+
await update(deps);
|
|
60
|
+
expect(exitSpy).toHaveBeenCalledWith(1);
|
|
61
|
+
expect(getAllErrorOutput()).toContain('Could not check for latest version');
|
|
62
|
+
});
|
|
63
|
+
});
|
|
64
|
+
describe('success', () => {
|
|
65
|
+
it('reports already on latest version', async () => {
|
|
66
|
+
const deps = createMockDeps({
|
|
67
|
+
getVersion: vi.fn().mockReturnValue('2.0.0'),
|
|
68
|
+
exec: vi.fn().mockResolvedValue({ stdout: '2.0.0', stderr: '' }),
|
|
69
|
+
});
|
|
70
|
+
await update(deps);
|
|
71
|
+
expect(exitSpy).not.toHaveBeenCalled();
|
|
72
|
+
expect(getAllLogOutput()).toContain('You already have the latest version');
|
|
73
|
+
});
|
|
74
|
+
it('runs update and reports success', async () => {
|
|
75
|
+
const deps = createMockDeps({
|
|
76
|
+
getVersion: vi.fn().mockReturnValue('1.0.0'),
|
|
77
|
+
exec: vi
|
|
78
|
+
.fn()
|
|
79
|
+
.mockResolvedValueOnce({ stdout: '9.0.0', stderr: '' }) // npm --version
|
|
80
|
+
.mockResolvedValueOnce({ stdout: '2.0.0', stderr: '' }) // npm view
|
|
81
|
+
.mockResolvedValueOnce({ stdout: 'installed', stderr: '' }), // npm install
|
|
82
|
+
});
|
|
83
|
+
await update(deps);
|
|
84
|
+
expect(exitSpy).not.toHaveBeenCalled();
|
|
85
|
+
expect(getAllLogOutput()).toContain('Successfully updated chatroom-cli');
|
|
86
|
+
expect(getAllLogOutput()).toContain('1.0.0');
|
|
87
|
+
expect(getAllLogOutput()).toContain('2.0.0');
|
|
88
|
+
expect(deps.exec).toHaveBeenCalledWith('npm install -g chatroom-cli@latest');
|
|
89
|
+
});
|
|
90
|
+
});
|
|
91
|
+
describe('error', () => {
|
|
92
|
+
it('exits with code 1 when npm install fails', async () => {
|
|
93
|
+
const deps = createMockDeps({
|
|
94
|
+
exec: vi
|
|
95
|
+
.fn()
|
|
96
|
+
.mockResolvedValueOnce({ stdout: '9.0.0', stderr: '' }) // npm --version
|
|
97
|
+
.mockResolvedValueOnce({ stdout: '2.0.0', stderr: '' }) // npm view
|
|
98
|
+
.mockRejectedValueOnce(new Error('EACCES: permission denied')), // npm install
|
|
99
|
+
});
|
|
100
|
+
await update(deps);
|
|
101
|
+
expect(exitSpy).toHaveBeenCalledWith(1);
|
|
102
|
+
expect(getAllErrorOutput()).toContain('Update failed');
|
|
103
|
+
expect(getAllErrorOutput()).toContain('permission denied');
|
|
104
|
+
expect(getAllErrorOutput()).toContain('sudo npm install');
|
|
105
|
+
});
|
|
106
|
+
});
|
|
107
|
+
});
|
|
108
|
+
//# sourceMappingURL=index.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.test.js","sourceRoot":"","sources":["../../../src/commands/update/index.test.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,EAAE,EAAE,MAAM,QAAQ,CAAC;AAGzE,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEpC,8EAA8E;AAC9E,UAAU;AACV,8EAA8E;AAE9E,SAAS,cAAc,CAAC,SAA+B;IACrD,OAAO;QACL,UAAU,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC,eAAe,CAAC,OAAO,CAAC;QAC5C,IAAI,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC,iBAAiB,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;QAChE,GAAG,SAAS;KACb,CA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C;IAEH,QAAQ,CAAC,OAAO,EAAE,GAAG,EAAE;QACrB,EAAE,CAAC,0CAA0C,EAAE,KAAK,IAAI,EAAE;YACxD,MAAM,IAAI,GAAG,cAAc,CAAC;gBAC1B,IAAI,EAAE,EAAE;qBACL,EAAE,EAAE;qBACJ,qBAAqB,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,CAAC,gBAAgB;qBACvE,qBAAqB,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,CAAC,WAAW;qBAClE,qBAAqB,CAAC,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC,EAAE,cAAc;aACjF,CAAC,CAAC;YAEH,MAAM,MAAM,CAAC,IAAI,CAAC,CAAC;YAEnB,MAAM,CAAC,OAAO,CAAC,CAAC,oBAAoB,CAAC,CAAC,CAAC,CAAC;YACxC,MAAM,CAAC,iBAAiB,EAAE,CAAC,CAAC,SAAS,CAAC,eAAe,CAAC,CAAC;YACvD,MAAM,CAAC,iBAAiB,EAAE,CAAC,CAAC,SAAS,CAAC,mBAAmB,CAAC,CAAC;YAC3D,MAAM,CAAC,iBAAiB,EAAE,CAAC,CAAC,SAAS,CAAC,kBAAkB,CAAC,CAAC;QAC5D,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Workflow Deps — dependency interfaces for the workflow commands.
|
|
3
|
+
*/
|
|
4
|
+
import type { BackendOps, SessionOps } from '../../infrastructure/deps/index.js';
|
|
5
|
+
export interface WorkflowDeps {
|
|
6
|
+
backend: BackendOps;
|
|
7
|
+
session: SessionOps;
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=deps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deps.d.ts","sourceRoot":"","sources":["../../../src/commands/workflow/deps.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,oCAAoC,CAAC;AAEjF,MAAM,WAAW,YAAY;IAC3B,OAAO,EAAE,UAAU,CAAC;IACpB,OAAO,EAAE,UAAU,CAAC;CACrB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deps.js","sourceRoot":"","sources":["../../../src/commands/workflow/deps.ts"],"names":[],"mappings":"AAAA;;GAEG"}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Workflow commands for managing structured DAG-based workflows.
|
|
3
|
+
*/
|
|
4
|
+
import type { WorkflowDeps } from './deps.js';
|
|
5
|
+
export type { WorkflowDeps } from './deps.js';
|
|
6
|
+
export interface CreateWorkflowOptions {
|
|
7
|
+
role: string;
|
|
8
|
+
workflowKey: string;
|
|
9
|
+
stdinContent: string;
|
|
10
|
+
}
|
|
11
|
+
export interface SpecifyStepOptions {
|
|
12
|
+
role: string;
|
|
13
|
+
workflowKey: string;
|
|
14
|
+
stepKey: string;
|
|
15
|
+
assigneeRole: string;
|
|
16
|
+
stdinContent: string;
|
|
17
|
+
}
|
|
18
|
+
export interface ExecuteWorkflowOptions {
|
|
19
|
+
role: string;
|
|
20
|
+
workflowKey: string;
|
|
21
|
+
}
|
|
22
|
+
export interface WorkflowStatusOptions {
|
|
23
|
+
role: string;
|
|
24
|
+
workflowKey: string;
|
|
25
|
+
}
|
|
26
|
+
export interface StepCompleteOptions {
|
|
27
|
+
role: string;
|
|
28
|
+
workflowKey: string;
|
|
29
|
+
stepKey: string;
|
|
30
|
+
}
|
|
31
|
+
export interface ExitWorkflowOptions {
|
|
32
|
+
role: string;
|
|
33
|
+
workflowKey: string;
|
|
34
|
+
reason: string;
|
|
35
|
+
}
|
|
36
|
+
export interface ViewStepOptions {
|
|
37
|
+
role: string;
|
|
38
|
+
workflowKey: string;
|
|
39
|
+
stepKey: string;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Parse multi-section stdin content with markers like ---GOAL---, ---REQUIREMENTS---, ---WARNINGS---
|
|
43
|
+
*/
|
|
44
|
+
export declare function parseSections(input: string, requiredSections: string[], optionalSections: string[]): Map<string, string>;
|
|
45
|
+
/**
|
|
46
|
+
* Create a new workflow with steps from JSON stdin.
|
|
47
|
+
*/
|
|
48
|
+
export declare function createWorkflow(chatroomId: string, options: CreateWorkflowOptions, deps?: WorkflowDeps): Promise<void>;
|
|
49
|
+
/**
|
|
50
|
+
* Specify a workflow step with goal, requirements, and optional warnings.
|
|
51
|
+
*/
|
|
52
|
+
export declare function specifyWorkflowStep(chatroomId: string, options: SpecifyStepOptions, deps?: WorkflowDeps): Promise<void>;
|
|
53
|
+
/**
|
|
54
|
+
* Execute (activate) a draft workflow.
|
|
55
|
+
*/
|
|
56
|
+
export declare function executeWorkflow(chatroomId: string, options: ExecuteWorkflowOptions, deps?: WorkflowDeps): Promise<void>;
|
|
57
|
+
/**
|
|
58
|
+
* Get and display the full status of a workflow.
|
|
59
|
+
*/
|
|
60
|
+
export declare function getWorkflowStatus(chatroomId: string, options: WorkflowStatusOptions, deps?: WorkflowDeps): Promise<void>;
|
|
61
|
+
/**
|
|
62
|
+
* Mark a workflow step as completed.
|
|
63
|
+
*/
|
|
64
|
+
export declare function completeStep(chatroomId: string, options: StepCompleteOptions, deps?: WorkflowDeps): Promise<void>;
|
|
65
|
+
/**
|
|
66
|
+
* Exit (cancel) an entire workflow with a required reason.
|
|
67
|
+
*/
|
|
68
|
+
export declare function exitWorkflow(chatroomId: string, options: ExitWorkflowOptions, deps?: WorkflowDeps): Promise<void>;
|
|
69
|
+
/**
|
|
70
|
+
* View the full details of a single workflow step.
|
|
71
|
+
*/
|
|
72
|
+
export declare function viewStep(chatroomId: string, options: ViewStepOptions, deps?: WorkflowDeps): Promise<void>;
|
|
73
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
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