@cluesmith/codev 2.0.0-rc.7 → 2.0.0-rc.70
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/bin/af.js +2 -2
- package/bin/consult.js +1 -1
- package/bin/porch.js +6 -35
- package/dashboard/dist/assets/index-C7FtNK6Y.css +32 -0
- package/dashboard/dist/assets/index-CDAINZKT.js +131 -0
- package/dashboard/dist/assets/index-CDAINZKT.js.map +1 -0
- package/dashboard/dist/index.html +14 -0
- package/dist/agent-farm/cli.d.ts.map +1 -1
- package/dist/agent-farm/cli.js +173 -118
- package/dist/agent-farm/cli.js.map +1 -1
- package/dist/agent-farm/commands/architect.d.ts +3 -3
- package/dist/agent-farm/commands/architect.d.ts.map +1 -1
- package/dist/agent-farm/commands/architect.js +20 -147
- package/dist/agent-farm/commands/architect.js.map +1 -1
- package/dist/agent-farm/commands/attach.d.ts +13 -0
- package/dist/agent-farm/commands/attach.d.ts.map +1 -0
- package/dist/agent-farm/commands/attach.js +144 -0
- package/dist/agent-farm/commands/attach.js.map +1 -0
- package/dist/agent-farm/commands/cleanup.d.ts.map +1 -1
- package/dist/agent-farm/commands/cleanup.js +35 -19
- package/dist/agent-farm/commands/cleanup.js.map +1 -1
- package/dist/agent-farm/commands/consult.d.ts +3 -4
- package/dist/agent-farm/commands/consult.d.ts.map +1 -1
- package/dist/agent-farm/commands/consult.js +27 -37
- package/dist/agent-farm/commands/consult.js.map +1 -1
- package/dist/agent-farm/commands/index.d.ts +2 -2
- package/dist/agent-farm/commands/index.d.ts.map +1 -1
- package/dist/agent-farm/commands/index.js +2 -2
- package/dist/agent-farm/commands/index.js.map +1 -1
- package/dist/agent-farm/commands/open.d.ts +4 -2
- package/dist/agent-farm/commands/open.d.ts.map +1 -1
- package/dist/agent-farm/commands/open.js +33 -83
- package/dist/agent-farm/commands/open.js.map +1 -1
- package/dist/agent-farm/commands/send.d.ts +1 -1
- package/dist/agent-farm/commands/send.d.ts.map +1 -1
- package/dist/agent-farm/commands/send.js +60 -79
- package/dist/agent-farm/commands/send.js.map +1 -1
- package/dist/agent-farm/commands/shell.d.ts +15 -0
- package/dist/agent-farm/commands/shell.d.ts.map +1 -0
- package/dist/agent-farm/commands/shell.js +50 -0
- package/dist/agent-farm/commands/shell.js.map +1 -0
- package/dist/agent-farm/commands/spawn.d.ts.map +1 -1
- package/dist/agent-farm/commands/spawn.js +597 -281
- package/dist/agent-farm/commands/spawn.js.map +1 -1
- package/dist/agent-farm/commands/start.d.ts +10 -20
- package/dist/agent-farm/commands/start.d.ts.map +1 -1
- package/dist/agent-farm/commands/start.js +45 -491
- package/dist/agent-farm/commands/start.js.map +1 -1
- package/dist/agent-farm/commands/status.d.ts +2 -0
- package/dist/agent-farm/commands/status.d.ts.map +1 -1
- package/dist/agent-farm/commands/status.js +75 -24
- package/dist/agent-farm/commands/status.js.map +1 -1
- package/dist/agent-farm/commands/stop.d.ts +6 -0
- package/dist/agent-farm/commands/stop.d.ts.map +1 -1
- package/dist/agent-farm/commands/stop.js +49 -109
- package/dist/agent-farm/commands/stop.js.map +1 -1
- package/dist/agent-farm/commands/tower-cloud.d.ts +48 -0
- package/dist/agent-farm/commands/tower-cloud.d.ts.map +1 -0
- package/dist/agent-farm/commands/tower-cloud.js +334 -0
- package/dist/agent-farm/commands/tower-cloud.js.map +1 -0
- package/dist/agent-farm/commands/tower.d.ts +9 -0
- package/dist/agent-farm/commands/tower.d.ts.map +1 -1
- package/dist/agent-farm/commands/tower.js +59 -19
- package/dist/agent-farm/commands/tower.js.map +1 -1
- package/dist/agent-farm/db/index.d.ts +6 -2
- package/dist/agent-farm/db/index.d.ts.map +1 -1
- package/dist/agent-farm/db/index.js +246 -18
- package/dist/agent-farm/db/index.js.map +1 -1
- package/dist/agent-farm/db/migrate.d.ts +0 -4
- package/dist/agent-farm/db/migrate.d.ts.map +1 -1
- package/dist/agent-farm/db/migrate.js +6 -55
- package/dist/agent-farm/db/migrate.js.map +1 -1
- package/dist/agent-farm/db/schema.d.ts +3 -3
- package/dist/agent-farm/db/schema.d.ts.map +1 -1
- package/dist/agent-farm/db/schema.js +25 -19
- package/dist/agent-farm/db/schema.js.map +1 -1
- package/dist/agent-farm/db/types.d.ts +3 -13
- package/dist/agent-farm/db/types.d.ts.map +1 -1
- package/dist/agent-farm/db/types.js +3 -11
- package/dist/agent-farm/db/types.js.map +1 -1
- package/dist/agent-farm/hq-connector.d.ts +2 -6
- package/dist/agent-farm/hq-connector.d.ts.map +1 -1
- package/dist/agent-farm/hq-connector.js +2 -17
- package/dist/agent-farm/hq-connector.js.map +1 -1
- package/dist/agent-farm/lib/cloud-config.d.ts +59 -0
- package/dist/agent-farm/lib/cloud-config.d.ts.map +1 -0
- package/dist/agent-farm/lib/cloud-config.js +143 -0
- package/dist/agent-farm/lib/cloud-config.js.map +1 -0
- package/dist/agent-farm/lib/tower-client.d.ts +163 -0
- package/dist/agent-farm/lib/tower-client.d.ts.map +1 -0
- package/dist/agent-farm/lib/tower-client.js +233 -0
- package/dist/agent-farm/lib/tower-client.js.map +1 -0
- package/dist/agent-farm/lib/tunnel-client.d.ts +117 -0
- package/dist/agent-farm/lib/tunnel-client.d.ts.map +1 -0
- package/dist/agent-farm/lib/tunnel-client.js +504 -0
- package/dist/agent-farm/lib/tunnel-client.js.map +1 -0
- package/dist/agent-farm/servers/tower-server.js +2650 -185
- package/dist/agent-farm/servers/tower-server.js.map +1 -1
- package/dist/agent-farm/state.d.ts +6 -12
- package/dist/agent-farm/state.d.ts.map +1 -1
- package/dist/agent-farm/state.js +34 -49
- package/dist/agent-farm/state.js.map +1 -1
- package/dist/agent-farm/types.d.ts +49 -26
- package/dist/agent-farm/types.d.ts.map +1 -1
- package/dist/agent-farm/utils/config.d.ts +0 -5
- package/dist/agent-farm/utils/config.d.ts.map +1 -1
- package/dist/agent-farm/utils/config.js +12 -44
- package/dist/agent-farm/utils/config.js.map +1 -1
- package/dist/agent-farm/utils/deps.d.ts.map +1 -1
- package/dist/agent-farm/utils/deps.js +0 -32
- package/dist/agent-farm/utils/deps.js.map +1 -1
- package/dist/agent-farm/utils/file-tabs.d.ts +27 -0
- package/dist/agent-farm/utils/file-tabs.d.ts.map +1 -0
- package/dist/agent-farm/utils/file-tabs.js +46 -0
- package/dist/agent-farm/utils/file-tabs.js.map +1 -0
- package/dist/agent-farm/utils/gate-status.d.ts +16 -0
- package/dist/agent-farm/utils/gate-status.d.ts.map +1 -0
- package/dist/agent-farm/utils/gate-status.js +79 -0
- package/dist/agent-farm/utils/gate-status.js.map +1 -0
- package/dist/agent-farm/utils/gate-watcher.d.ts +38 -0
- package/dist/agent-farm/utils/gate-watcher.d.ts.map +1 -0
- package/dist/agent-farm/utils/gate-watcher.js +122 -0
- package/dist/agent-farm/utils/gate-watcher.js.map +1 -0
- package/dist/agent-farm/utils/index.d.ts +0 -1
- package/dist/agent-farm/utils/index.d.ts.map +1 -1
- package/dist/agent-farm/utils/index.js +0 -1
- package/dist/agent-farm/utils/index.js.map +1 -1
- package/dist/agent-farm/utils/notifications.d.ts +30 -0
- package/dist/agent-farm/utils/notifications.d.ts.map +1 -0
- package/dist/agent-farm/utils/notifications.js +121 -0
- package/dist/agent-farm/utils/notifications.js.map +1 -0
- package/dist/agent-farm/utils/server-utils.d.ts +5 -5
- package/dist/agent-farm/utils/server-utils.d.ts.map +1 -1
- package/dist/agent-farm/utils/server-utils.js +5 -16
- package/dist/agent-farm/utils/server-utils.js.map +1 -1
- package/dist/agent-farm/utils/session.d.ts +32 -0
- package/dist/agent-farm/utils/session.d.ts.map +1 -0
- package/dist/agent-farm/utils/session.js +57 -0
- package/dist/agent-farm/utils/session.js.map +1 -0
- package/dist/agent-farm/utils/shell.d.ts +9 -22
- package/dist/agent-farm/utils/shell.d.ts.map +1 -1
- package/dist/agent-farm/utils/shell.js +34 -34
- package/dist/agent-farm/utils/shell.js.map +1 -1
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +11 -54
- package/dist/cli.js.map +1 -1
- package/dist/commands/adopt.d.ts.map +1 -1
- package/dist/commands/adopt.js +49 -4
- package/dist/commands/adopt.js.map +1 -1
- package/dist/commands/consult/index.d.ts +13 -2
- package/dist/commands/consult/index.d.ts.map +1 -1
- package/dist/commands/consult/index.js +245 -29
- package/dist/commands/consult/index.js.map +1 -1
- package/dist/commands/doctor.d.ts.map +1 -1
- package/dist/commands/doctor.js +96 -79
- package/dist/commands/doctor.js.map +1 -1
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +41 -2
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/porch/build-counter.d.ts +5 -0
- package/dist/commands/porch/build-counter.d.ts.map +1 -0
- package/dist/commands/porch/build-counter.js +5 -0
- package/dist/commands/porch/build-counter.js.map +1 -0
- package/dist/commands/porch/checks.d.ts +17 -29
- package/dist/commands/porch/checks.d.ts.map +1 -1
- package/dist/commands/porch/checks.js +96 -144
- package/dist/commands/porch/checks.js.map +1 -1
- package/dist/commands/porch/index.d.ts +25 -43
- package/dist/commands/porch/index.d.ts.map +1 -1
- package/dist/commands/porch/index.js +463 -1116
- package/dist/commands/porch/index.js.map +1 -1
- package/dist/commands/porch/next.d.ts +22 -0
- package/dist/commands/porch/next.d.ts.map +1 -0
- package/dist/commands/porch/next.js +571 -0
- package/dist/commands/porch/next.js.map +1 -0
- package/dist/commands/porch/plan.d.ts +70 -0
- package/dist/commands/porch/plan.d.ts.map +1 -0
- package/dist/commands/porch/plan.js +190 -0
- package/dist/commands/porch/plan.js.map +1 -0
- package/dist/commands/porch/prompts.d.ts +19 -0
- package/dist/commands/porch/prompts.d.ts.map +1 -0
- package/dist/commands/porch/prompts.js +277 -0
- package/dist/commands/porch/prompts.js.map +1 -0
- package/dist/commands/porch/protocol.d.ts +59 -0
- package/dist/commands/porch/protocol.d.ts.map +1 -0
- package/dist/commands/porch/protocol.js +294 -0
- package/dist/commands/porch/protocol.js.map +1 -0
- package/dist/commands/porch/state.d.ts +36 -107
- package/dist/commands/porch/state.d.ts.map +1 -1
- package/dist/commands/porch/state.js +120 -699
- package/dist/commands/porch/state.js.map +1 -1
- package/dist/commands/porch/types.d.ts +99 -164
- package/dist/commands/porch/types.d.ts.map +1 -1
- package/dist/commands/porch/types.js +2 -1
- package/dist/commands/porch/types.js.map +1 -1
- package/dist/commands/porch/verdict.d.ts +31 -0
- package/dist/commands/porch/verdict.d.ts.map +1 -0
- package/dist/commands/porch/verdict.js +59 -0
- package/dist/commands/porch/verdict.js.map +1 -0
- package/dist/commands/update.d.ts.map +1 -1
- package/dist/commands/update.js +31 -0
- package/dist/commands/update.js.map +1 -1
- package/dist/lib/scaffold.d.ts +37 -0
- package/dist/lib/scaffold.d.ts.map +1 -1
- package/dist/lib/scaffold.js +114 -0
- package/dist/lib/scaffold.js.map +1 -1
- package/dist/terminal/index.d.ts +8 -0
- package/dist/terminal/index.d.ts.map +1 -0
- package/dist/terminal/index.js +5 -0
- package/dist/terminal/index.js.map +1 -0
- package/dist/terminal/pty-manager.d.ts +69 -0
- package/dist/terminal/pty-manager.d.ts.map +1 -0
- package/dist/terminal/pty-manager.js +377 -0
- package/dist/terminal/pty-manager.js.map +1 -0
- package/dist/terminal/pty-session.d.ts +104 -0
- package/dist/terminal/pty-session.d.ts.map +1 -0
- package/dist/terminal/pty-session.js +327 -0
- package/dist/terminal/pty-session.js.map +1 -0
- package/dist/terminal/ring-buffer.d.ts +34 -0
- package/dist/terminal/ring-buffer.d.ts.map +1 -0
- package/dist/terminal/ring-buffer.js +94 -0
- package/dist/terminal/ring-buffer.js.map +1 -0
- package/dist/terminal/session-manager.d.ts +115 -0
- package/dist/terminal/session-manager.d.ts.map +1 -0
- package/dist/terminal/session-manager.js +582 -0
- package/dist/terminal/session-manager.js.map +1 -0
- package/dist/terminal/shepherd-client.d.ts +58 -0
- package/dist/terminal/shepherd-client.d.ts.map +1 -0
- package/dist/terminal/shepherd-client.js +212 -0
- package/dist/terminal/shepherd-client.js.map +1 -0
- package/dist/terminal/shepherd-main.d.ts +19 -0
- package/dist/terminal/shepherd-main.d.ts.map +1 -0
- package/dist/terminal/shepherd-main.js +153 -0
- package/dist/terminal/shepherd-main.js.map +1 -0
- package/dist/terminal/shepherd-process.d.ts +75 -0
- package/dist/terminal/shepherd-process.d.ts.map +1 -0
- package/dist/terminal/shepherd-process.js +279 -0
- package/dist/terminal/shepherd-process.js.map +1 -0
- package/dist/terminal/shepherd-protocol.d.ts +115 -0
- package/dist/terminal/shepherd-protocol.d.ts.map +1 -0
- package/dist/terminal/shepherd-protocol.js +214 -0
- package/dist/terminal/shepherd-protocol.js.map +1 -0
- package/dist/terminal/shepherd-replay-buffer.d.ts +38 -0
- package/dist/terminal/shepherd-replay-buffer.d.ts.map +1 -0
- package/dist/terminal/shepherd-replay-buffer.js +94 -0
- package/dist/terminal/shepherd-replay-buffer.js.map +1 -0
- package/dist/terminal/ws-protocol.d.ts +27 -0
- package/dist/terminal/ws-protocol.d.ts.map +1 -0
- package/dist/terminal/ws-protocol.js +44 -0
- package/dist/terminal/ws-protocol.js.map +1 -0
- package/package.json +19 -5
- package/skeleton/.claude/skills/af/SKILL.md +89 -0
- package/skeleton/.claude/skills/codev/SKILL.md +41 -0
- package/skeleton/.claude/skills/consult/SKILL.md +81 -0
- package/skeleton/.claude/skills/generate-image/SKILL.md +56 -0
- package/skeleton/DEPENDENCIES.md +4 -62
- package/skeleton/builders.md +1 -1
- package/skeleton/consult-types/impl-review.md +18 -9
- package/skeleton/consult-types/integration-review.md +1 -1
- package/skeleton/consult-types/plan-review.md +1 -1
- package/skeleton/consult-types/pr-ready.md +1 -1
- package/skeleton/consult-types/spec-review.md +1 -1
- package/skeleton/porch/prompts/defend.md +1 -1
- package/skeleton/porch/prompts/evaluate.md +2 -2
- package/skeleton/porch/prompts/implement.md +1 -1
- package/skeleton/porch/prompts/plan.md +1 -1
- package/skeleton/porch/prompts/review.md +4 -4
- package/skeleton/porch/prompts/specify.md +1 -1
- package/skeleton/porch/prompts/understand.md +2 -2
- package/skeleton/protocol-schema.json +282 -0
- package/skeleton/protocols/bugfix/builder-prompt.md +54 -0
- package/skeleton/protocols/bugfix/prompts/fix.md +77 -0
- package/skeleton/protocols/bugfix/prompts/investigate.md +77 -0
- package/skeleton/protocols/bugfix/prompts/pr.md +84 -0
- package/skeleton/protocols/bugfix/protocol.json +20 -33
- package/skeleton/protocols/experiment/builder-prompt.md +52 -0
- package/skeleton/protocols/experiment/protocol.json +101 -0
- package/skeleton/protocols/experiment/protocol.md +3 -3
- package/skeleton/protocols/experiment/templates/notes.md +1 -1
- package/skeleton/protocols/maintain/builder-prompt.md +46 -0
- package/skeleton/protocols/maintain/prompts/audit.md +111 -0
- package/skeleton/protocols/maintain/prompts/clean.md +91 -0
- package/skeleton/protocols/maintain/prompts/sync.md +113 -0
- package/skeleton/protocols/maintain/prompts/verify.md +110 -0
- package/skeleton/protocols/maintain/protocol.json +141 -0
- package/skeleton/protocols/maintain/protocol.md +17 -11
- package/skeleton/protocols/protocol-schema.json +54 -1
- package/skeleton/protocols/spir/builder-prompt.md +59 -0
- package/skeleton/protocols/spir/prompts/implement.md +208 -0
- package/skeleton/protocols/{spider → spir}/prompts/plan.md +6 -70
- package/skeleton/protocols/{spider → spir}/prompts/review.md +20 -39
- package/skeleton/protocols/{spider → spir}/prompts/specify.md +33 -61
- package/skeleton/protocols/spir/protocol.json +156 -0
- package/skeleton/protocols/{spider → spir}/protocol.md +35 -21
- package/skeleton/protocols/{spider → spir}/templates/plan.md +14 -0
- package/skeleton/protocols/spir/templates/review.md +89 -0
- package/skeleton/protocols/tick/builder-prompt.md +56 -0
- package/skeleton/protocols/tick/protocol.json +7 -2
- package/skeleton/protocols/tick/protocol.md +18 -18
- package/skeleton/protocols/tick/templates/review.md +1 -1
- package/skeleton/resources/commands/agent-farm.md +63 -46
- package/skeleton/resources/commands/codev.md +0 -2
- package/skeleton/resources/commands/overview.md +7 -17
- package/skeleton/resources/workflow-reference.md +4 -4
- package/skeleton/roles/architect.md +152 -315
- package/skeleton/roles/builder.md +110 -218
- package/skeleton/roles/consultant.md +6 -6
- package/skeleton/templates/AGENTS.md +2 -2
- package/skeleton/templates/CLAUDE.md +2 -2
- package/skeleton/templates/cheatsheet.md +7 -5
- package/skeleton/templates/projectlist.md +1 -1
- package/templates/dashboard/index.html +17 -43
- package/templates/dashboard/js/dialogs.js +7 -7
- package/templates/dashboard/js/files.js +2 -2
- package/templates/dashboard/js/main.js +4 -4
- package/templates/dashboard/js/projects.js +3 -3
- package/templates/dashboard/js/tabs.js +1 -1
- package/templates/dashboard/js/utils.js +22 -87
- package/templates/open.html +26 -0
- package/templates/tower.html +642 -36
- package/dist/agent-farm/commands/kickoff.d.ts +0 -20
- package/dist/agent-farm/commands/kickoff.d.ts.map +0 -1
- package/dist/agent-farm/commands/kickoff.js +0 -337
- package/dist/agent-farm/commands/kickoff.js.map +0 -1
- package/dist/agent-farm/commands/rename.d.ts +0 -13
- package/dist/agent-farm/commands/rename.d.ts.map +0 -1
- package/dist/agent-farm/commands/rename.js +0 -33
- package/dist/agent-farm/commands/rename.js.map +0 -1
- package/dist/agent-farm/commands/tutorial.d.ts +0 -10
- package/dist/agent-farm/commands/tutorial.d.ts.map +0 -1
- package/dist/agent-farm/commands/tutorial.js +0 -49
- package/dist/agent-farm/commands/tutorial.js.map +0 -1
- package/dist/agent-farm/commands/util.d.ts +0 -15
- package/dist/agent-farm/commands/util.d.ts.map +0 -1
- package/dist/agent-farm/commands/util.js +0 -108
- package/dist/agent-farm/commands/util.js.map +0 -1
- package/dist/agent-farm/servers/dashboard-server.d.ts +0 -7
- package/dist/agent-farm/servers/dashboard-server.d.ts.map +0 -1
- package/dist/agent-farm/servers/dashboard-server.js +0 -1872
- package/dist/agent-farm/servers/dashboard-server.js.map +0 -1
- package/dist/agent-farm/servers/open-server.d.ts +0 -7
- package/dist/agent-farm/servers/open-server.d.ts.map +0 -1
- package/dist/agent-farm/servers/open-server.js +0 -315
- package/dist/agent-farm/servers/open-server.js.map +0 -1
- package/dist/agent-farm/tutorial/index.d.ts +0 -8
- package/dist/agent-farm/tutorial/index.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/index.js +0 -8
- package/dist/agent-farm/tutorial/index.js.map +0 -1
- package/dist/agent-farm/tutorial/prompts.d.ts +0 -57
- package/dist/agent-farm/tutorial/prompts.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/prompts.js +0 -147
- package/dist/agent-farm/tutorial/prompts.js.map +0 -1
- package/dist/agent-farm/tutorial/runner.d.ts +0 -52
- package/dist/agent-farm/tutorial/runner.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/runner.js +0 -204
- package/dist/agent-farm/tutorial/runner.js.map +0 -1
- package/dist/agent-farm/tutorial/state.d.ts +0 -26
- package/dist/agent-farm/tutorial/state.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/state.js +0 -89
- package/dist/agent-farm/tutorial/state.js.map +0 -1
- package/dist/agent-farm/tutorial/steps/first-spec.d.ts +0 -7
- package/dist/agent-farm/tutorial/steps/first-spec.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/steps/first-spec.js +0 -136
- package/dist/agent-farm/tutorial/steps/first-spec.js.map +0 -1
- package/dist/agent-farm/tutorial/steps/implementation.d.ts +0 -7
- package/dist/agent-farm/tutorial/steps/implementation.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/steps/implementation.js +0 -76
- package/dist/agent-farm/tutorial/steps/implementation.js.map +0 -1
- package/dist/agent-farm/tutorial/steps/index.d.ts +0 -10
- package/dist/agent-farm/tutorial/steps/index.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/steps/index.js +0 -10
- package/dist/agent-farm/tutorial/steps/index.js.map +0 -1
- package/dist/agent-farm/tutorial/steps/planning.d.ts +0 -7
- package/dist/agent-farm/tutorial/steps/planning.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/steps/planning.js +0 -143
- package/dist/agent-farm/tutorial/steps/planning.js.map +0 -1
- package/dist/agent-farm/tutorial/steps/review.d.ts +0 -7
- package/dist/agent-farm/tutorial/steps/review.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/steps/review.js +0 -78
- package/dist/agent-farm/tutorial/steps/review.js.map +0 -1
- package/dist/agent-farm/tutorial/steps/setup.d.ts +0 -7
- package/dist/agent-farm/tutorial/steps/setup.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/steps/setup.js +0 -126
- package/dist/agent-farm/tutorial/steps/setup.js.map +0 -1
- package/dist/agent-farm/tutorial/steps/welcome.d.ts +0 -7
- package/dist/agent-farm/tutorial/steps/welcome.d.ts.map +0 -1
- package/dist/agent-farm/tutorial/steps/welcome.js +0 -50
- package/dist/agent-farm/tutorial/steps/welcome.js.map +0 -1
- package/dist/agent-farm/utils/orphan-handler.d.ts +0 -27
- package/dist/agent-farm/utils/orphan-handler.d.ts.map +0 -1
- package/dist/agent-farm/utils/orphan-handler.js +0 -149
- package/dist/agent-farm/utils/orphan-handler.js.map +0 -1
- package/dist/agent-farm/utils/port-registry.d.ts +0 -58
- package/dist/agent-farm/utils/port-registry.d.ts.map +0 -1
- package/dist/agent-farm/utils/port-registry.js +0 -166
- package/dist/agent-farm/utils/port-registry.js.map +0 -1
- package/dist/agent-farm/utils/terminal-ports.d.ts +0 -18
- package/dist/agent-farm/utils/terminal-ports.d.ts.map +0 -1
- package/dist/agent-farm/utils/terminal-ports.js +0 -35
- package/dist/agent-farm/utils/terminal-ports.js.map +0 -1
- package/dist/commands/pcheck/cache.d.ts +0 -48
- package/dist/commands/pcheck/cache.d.ts.map +0 -1
- package/dist/commands/pcheck/cache.js +0 -170
- package/dist/commands/pcheck/cache.js.map +0 -1
- package/dist/commands/pcheck/evaluator.d.ts +0 -15
- package/dist/commands/pcheck/evaluator.d.ts.map +0 -1
- package/dist/commands/pcheck/evaluator.js +0 -246
- package/dist/commands/pcheck/evaluator.js.map +0 -1
- package/dist/commands/pcheck/index.d.ts +0 -12
- package/dist/commands/pcheck/index.d.ts.map +0 -1
- package/dist/commands/pcheck/index.js +0 -249
- package/dist/commands/pcheck/index.js.map +0 -1
- package/dist/commands/pcheck/parser.d.ts +0 -39
- package/dist/commands/pcheck/parser.d.ts.map +0 -1
- package/dist/commands/pcheck/parser.js +0 -155
- package/dist/commands/pcheck/parser.js.map +0 -1
- package/dist/commands/pcheck/types.d.ts +0 -82
- package/dist/commands/pcheck/types.d.ts.map +0 -1
- package/dist/commands/pcheck/types.js +0 -5
- package/dist/commands/pcheck/types.js.map +0 -1
- package/dist/commands/porch/consultation.d.ts +0 -56
- package/dist/commands/porch/consultation.d.ts.map +0 -1
- package/dist/commands/porch/consultation.js +0 -330
- package/dist/commands/porch/consultation.js.map +0 -1
- package/dist/commands/porch/notifications.d.ts +0 -99
- package/dist/commands/porch/notifications.d.ts.map +0 -1
- package/dist/commands/porch/notifications.js +0 -223
- package/dist/commands/porch/notifications.js.map +0 -1
- package/dist/commands/porch/plan-parser.d.ts +0 -38
- package/dist/commands/porch/plan-parser.d.ts.map +0 -1
- package/dist/commands/porch/plan-parser.js +0 -166
- package/dist/commands/porch/plan-parser.js.map +0 -1
- package/dist/commands/porch/protocol-loader.d.ts +0 -46
- package/dist/commands/porch/protocol-loader.d.ts.map +0 -1
- package/dist/commands/porch/protocol-loader.js +0 -253
- package/dist/commands/porch/protocol-loader.js.map +0 -1
- package/dist/commands/porch/signal-parser.d.ts +0 -88
- package/dist/commands/porch/signal-parser.d.ts.map +0 -1
- package/dist/commands/porch/signal-parser.js +0 -148
- package/dist/commands/porch/signal-parser.js.map +0 -1
- package/dist/commands/tower.d.ts +0 -16
- package/dist/commands/tower.d.ts.map +0 -1
- package/dist/commands/tower.js +0 -21
- package/dist/commands/tower.js.map +0 -1
- package/skeleton/config.json +0 -7
- package/skeleton/porch/protocols/bugfix.json +0 -85
- package/skeleton/porch/protocols/spider.json +0 -135
- package/skeleton/porch/protocols/tick.json +0 -76
- package/skeleton/protocols/spider/prompts/defend.md +0 -215
- package/skeleton/protocols/spider/prompts/evaluate.md +0 -241
- package/skeleton/protocols/spider/prompts/implement.md +0 -149
- package/skeleton/protocols/spider/protocol.json +0 -210
- package/skeleton/protocols/spider/templates/review.md +0 -207
- package/templates/dashboard/css/activity.css +0 -151
- package/templates/dashboard/js/activity.js +0 -112
- /package/skeleton/protocols/{spider → spir}/templates/spec.md +0 -0
|
@@ -1,126 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Tutorial Step 2: Setup Phase
|
|
3
|
-
* Creates codev directory structure and explains it
|
|
4
|
-
*/
|
|
5
|
-
import { existsSync, mkdirSync } from 'node:fs';
|
|
6
|
-
import { writeFile } from 'node:fs/promises';
|
|
7
|
-
import { resolve } from 'node:path';
|
|
8
|
-
import * as prompts from '../prompts.js';
|
|
9
|
-
const AGENTS_MD_TEMPLATE = `# AI Agent Instructions
|
|
10
|
-
|
|
11
|
-
This file provides instructions to AI coding assistants working on this project.
|
|
12
|
-
|
|
13
|
-
## Project Overview
|
|
14
|
-
|
|
15
|
-
[Describe your project here]
|
|
16
|
-
|
|
17
|
-
## Development Workflow
|
|
18
|
-
|
|
19
|
-
This project uses Codev for structured AI-assisted development:
|
|
20
|
-
|
|
21
|
-
- **Specifications** (codev/specs/): What to build
|
|
22
|
-
- **Plans** (codev/plans/): How to build it
|
|
23
|
-
- **Reviews** (codev/reviews/): Lessons learned
|
|
24
|
-
|
|
25
|
-
## Available Protocols
|
|
26
|
-
|
|
27
|
-
- **TICK**: Fast protocol for small, well-defined tasks
|
|
28
|
-
- **SPIDER**: Full protocol with consultation for complex features
|
|
29
|
-
|
|
30
|
-
## Getting Started
|
|
31
|
-
|
|
32
|
-
1. Check \`codev/projectlist.md\` for current project status
|
|
33
|
-
2. Run \`af tutorial\` if you're new to the project
|
|
34
|
-
3. See \`codev/protocols/\` for detailed protocol documentation
|
|
35
|
-
`;
|
|
36
|
-
const PROJECTLIST_TEMPLATE = `# Project List
|
|
37
|
-
|
|
38
|
-
Track all projects and their status here.
|
|
39
|
-
|
|
40
|
-
## Active Projects
|
|
41
|
-
|
|
42
|
-
\`\`\`yaml
|
|
43
|
-
projects: []
|
|
44
|
-
\`\`\`
|
|
45
|
-
|
|
46
|
-
## Next Available Number
|
|
47
|
-
|
|
48
|
-
**0001** - Reserve this number for your next project
|
|
49
|
-
`;
|
|
50
|
-
export const setupStep = {
|
|
51
|
-
id: 'setup',
|
|
52
|
-
title: 'Project Setup',
|
|
53
|
-
async run(ctx) {
|
|
54
|
-
if (ctx.hasCodev) {
|
|
55
|
-
prompts.success('Codev is already set up in this project!');
|
|
56
|
-
console.log();
|
|
57
|
-
prompts.content('Your codev directory structure:');
|
|
58
|
-
prompts.bullet('codev/specs/ - Feature specifications');
|
|
59
|
-
prompts.bullet('codev/plans/ - Implementation plans');
|
|
60
|
-
prompts.bullet('codev/reviews/ - Post-implementation reviews');
|
|
61
|
-
prompts.bullet('codev/protocols/ - Development protocols');
|
|
62
|
-
prompts.bullet('codev/projectlist.md - Project tracking');
|
|
63
|
-
console.log();
|
|
64
|
-
await prompts.pressEnter();
|
|
65
|
-
return { status: 'completed' };
|
|
66
|
-
}
|
|
67
|
-
prompts.content('Let\'s set up the Codev directory structure.\n');
|
|
68
|
-
prompts.content('This will create:');
|
|
69
|
-
prompts.bullet('codev/specs/ - Where you\'ll write feature specifications');
|
|
70
|
-
prompts.bullet('codev/plans/ - Where implementation plans go');
|
|
71
|
-
prompts.bullet('codev/reviews/ - Where you\'ll document lessons learned');
|
|
72
|
-
prompts.bullet('codev/projectlist.md - Master project tracking file');
|
|
73
|
-
console.log();
|
|
74
|
-
const shouldCreate = await prompts.confirm('Create these directories?');
|
|
75
|
-
if (!shouldCreate) {
|
|
76
|
-
prompts.info('You can manually create the codev/ directory later.');
|
|
77
|
-
return { status: 'skipped' };
|
|
78
|
-
}
|
|
79
|
-
// Create directories
|
|
80
|
-
const codevDir = resolve(ctx.projectPath, 'codev');
|
|
81
|
-
const dirs = ['specs', 'plans', 'reviews', 'protocols', 'resources'];
|
|
82
|
-
try {
|
|
83
|
-
if (!existsSync(codevDir)) {
|
|
84
|
-
mkdirSync(codevDir, { recursive: true });
|
|
85
|
-
}
|
|
86
|
-
for (const dir of dirs) {
|
|
87
|
-
const dirPath = resolve(codevDir, dir);
|
|
88
|
-
if (!existsSync(dirPath)) {
|
|
89
|
-
mkdirSync(dirPath, { recursive: true });
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
// Create projectlist.md
|
|
93
|
-
const projectlistPath = resolve(codevDir, 'projectlist.md');
|
|
94
|
-
if (!existsSync(projectlistPath)) {
|
|
95
|
-
await writeFile(projectlistPath, PROJECTLIST_TEMPLATE);
|
|
96
|
-
}
|
|
97
|
-
// Create CLAUDE.md / AGENTS.md if they don't exist
|
|
98
|
-
const claudeMdPath = resolve(ctx.projectPath, 'CLAUDE.md');
|
|
99
|
-
const agentsMdPath = resolve(ctx.projectPath, 'AGENTS.md');
|
|
100
|
-
if (!existsSync(claudeMdPath) && !existsSync(agentsMdPath)) {
|
|
101
|
-
await writeFile(agentsMdPath, AGENTS_MD_TEMPLATE);
|
|
102
|
-
prompts.success('Created AGENTS.md with project instructions');
|
|
103
|
-
}
|
|
104
|
-
prompts.success('Created codev/ directory structure');
|
|
105
|
-
console.log();
|
|
106
|
-
prompts.content('Directory structure:');
|
|
107
|
-
prompts.code(`codev/
|
|
108
|
-
├── specs/ # Feature specifications
|
|
109
|
-
├── plans/ # Implementation plans
|
|
110
|
-
├── reviews/ # Post-implementation reviews
|
|
111
|
-
├── protocols/ # Development protocols
|
|
112
|
-
├── resources/ # Reference materials
|
|
113
|
-
└── projectlist.md`);
|
|
114
|
-
}
|
|
115
|
-
catch (error) {
|
|
116
|
-
prompts.warn(`Failed to create directories: ${error instanceof Error ? error.message : String(error)}`);
|
|
117
|
-
return { status: 'aborted' };
|
|
118
|
-
}
|
|
119
|
-
console.log();
|
|
120
|
-
prompts.info('Tip: Add AGENTS.md to version control so AI assistants can read it.');
|
|
121
|
-
console.log();
|
|
122
|
-
await prompts.pressEnter();
|
|
123
|
-
return { status: 'completed' };
|
|
124
|
-
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
|
1
|
-
{"version":3,"file":"welcome.d.ts","sourceRoot":"","sources":["../../../../src/agent-farm/tutorial/steps/welcome.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,IAAI,EAA2B,MAAM,cAAc,CAAC;AAGlE,eAAO,MAAM,WAAW,EAAE,IAkDzB,CAAC"}
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Tutorial Step 1: Welcome & Project Detection
|
|
3
|
-
* Introduces Codev/Agent Farm and detects the project environment
|
|
4
|
-
*/
|
|
5
|
-
import * as prompts from '../prompts.js';
|
|
6
|
-
export const welcomeStep = {
|
|
7
|
-
id: 'welcome',
|
|
8
|
-
title: 'Welcome & Project Detection',
|
|
9
|
-
async run(ctx) {
|
|
10
|
-
prompts.content('Welcome to Agent Farm! This tutorial will help you get started');
|
|
11
|
-
prompts.content('with structured AI-assisted development.\n');
|
|
12
|
-
// Show what we detected
|
|
13
|
-
prompts.content('About your project:');
|
|
14
|
-
prompts.bullet(`Project: ${ctx.projectName}`);
|
|
15
|
-
prompts.bullet(`Type: ${ctx.projectType === 'other' ? 'Unknown' : ctx.projectType}`);
|
|
16
|
-
prompts.bullet(`Git repository: ${ctx.hasGit ? 'Yes' : 'No'}`);
|
|
17
|
-
prompts.bullet(`Codev initialized: ${ctx.hasCodev ? 'Yes' : 'No'}`);
|
|
18
|
-
console.log();
|
|
19
|
-
// Warn if not in a git repo
|
|
20
|
-
if (!ctx.hasGit) {
|
|
21
|
-
prompts.warn('This directory is not a git repository.');
|
|
22
|
-
prompts.content('Codev works best with git for version control and worktrees.');
|
|
23
|
-
console.log();
|
|
24
|
-
const shouldContinue = await prompts.confirm('Continue anyway?');
|
|
25
|
-
if (!shouldContinue) {
|
|
26
|
-
prompts.info('Run `git init` to initialize a repository, then run `af tutorial` again.');
|
|
27
|
-
return { status: 'aborted' };
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
// Explain what Codev/Agent Farm is
|
|
31
|
-
prompts.content('\nWhat is Agent Farm?\n');
|
|
32
|
-
prompts.content('Agent Farm helps you work with AI coding assistants more effectively by:');
|
|
33
|
-
prompts.bullet('Organizing work into specs, plans, and reviews');
|
|
34
|
-
prompts.bullet('Using structured protocols (SPIDER, TICK) for development');
|
|
35
|
-
prompts.bullet('Enabling the Architect/Builder pattern for parallel work');
|
|
36
|
-
prompts.bullet('Maintaining project context and documentation');
|
|
37
|
-
console.log();
|
|
38
|
-
prompts.content('Key concepts:');
|
|
39
|
-
prompts.bullet('Spec: What you want to build (the goal)');
|
|
40
|
-
prompts.bullet('Plan: How you\'ll build it (the approach)');
|
|
41
|
-
prompts.bullet('Review: What you learned (lessons and improvements)');
|
|
42
|
-
console.log();
|
|
43
|
-
const ready = await prompts.confirm('Ready to set up Codev in your project?');
|
|
44
|
-
if (!ready) {
|
|
45
|
-
return { status: 'aborted' };
|
|
46
|
-
}
|
|
47
|
-
return { status: 'completed' };
|
|
48
|
-
},
|
|
49
|
-
};
|
|
50
|
-
//# sourceMappingURL=welcome.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"welcome.js","sourceRoot":"","sources":["../../../../src/agent-farm/tutorial/steps/welcome.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,KAAK,OAAO,MAAM,eAAe,CAAC;AAEzC,MAAM,CAAC,MAAM,WAAW,GAAS;IAC/B,EAAE,EAAE,SAAS;IACb,KAAK,EAAE,6BAA6B;IAEpC,KAAK,CAAC,GAAG,CAAC,GAAgB;QACxB,OAAO,CAAC,OAAO,CAAC,gEAAgE,CAAC,CAAC;QAClF,OAAO,CAAC,OAAO,CAAC,4CAA4C,CAAC,CAAC;QAE9D,wBAAwB;QACxB,OAAO,CAAC,OAAO,CAAC,qBAAqB,CAAC,CAAC;QACvC,OAAO,CAAC,MAAM,CAAC,YAAY,GAAG,CAAC,WAAW,EAAE,CAAC,CAAC;QAC9C,OAAO,CAAC,MAAM,CAAC,SAA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AC;QACjC,OAAO,CAAC,MAAM,CAAC,yCAAyC,CAAC,CAAC;QAC1D,OAAO,CAAC,MAAM,CAAC,2CAA2C,CAAC,CAAC;QAC5D,OAAO,CAAC,MAAM,CAAC,qDAAqD,CAAC,CAAC;QACtE,OAAO,CAAC,GAAG,EAAE,CAAC;QAEd,MAAM,KAAK,GAAG,MAAM,OAAO,CAAC,OAAO,CAAC,wCAAwC,CAAC,CAAC;QAC9E,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,CAAC;QAC/B,CAAC;QAED,OAAO,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC;IACjC,CAAC;CACF,CAAC"}
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Orphan Handler
|
|
3
|
-
*
|
|
4
|
-
* Detects and handles orphaned tmux sessions from previous agent-farm runs.
|
|
5
|
-
* This prevents resource leaks and ensures clean startup.
|
|
6
|
-
*
|
|
7
|
-
* IMPORTANT: Only cleans up sessions for THIS project (based on port).
|
|
8
|
-
* Sessions from other projects are left alone.
|
|
9
|
-
*/
|
|
10
|
-
/**
|
|
11
|
-
* Check for and handle orphaned sessions on startup
|
|
12
|
-
*
|
|
13
|
-
* Returns the number of sessions that were cleaned up.
|
|
14
|
-
*/
|
|
15
|
-
export declare function handleOrphanedSessions(options?: {
|
|
16
|
-
kill?: boolean;
|
|
17
|
-
silent?: boolean;
|
|
18
|
-
}): Promise<number>;
|
|
19
|
-
/**
|
|
20
|
-
* Check for stale artifacts from bash script era
|
|
21
|
-
*/
|
|
22
|
-
export declare function checkStaleArtifacts(codevDir: string): string[];
|
|
23
|
-
/**
|
|
24
|
-
* Warn about stale artifacts if found
|
|
25
|
-
*/
|
|
26
|
-
export declare function warnAboutStaleArtifacts(codevDir: string): void;
|
|
27
|
-
//# sourceMappingURL=orphan-handler.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"orphan-handler.d.ts","sourceRoot":"","sources":["../../../src/agent-farm/utils/orphan-handler.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAkFH;;;;GAIG;AACH,wBAAsB,sBAAsB,CAAC,OAAO,GAAE;IACpD,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,MAAM,CAAC,EAAE,OAAO,CAAC;CACb,GAAG,OAAO,CAAC,MAAM,CAAC,CAqCvB;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,EAAE,CAgB9D;AAED;;GAEG;AACH,wBAAgB,uBAAuB,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI,CAU9D"}
|
|
@@ -1,149 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Orphan Handler
|
|
3
|
-
*
|
|
4
|
-
* Detects and handles orphaned tmux sessions from previous agent-farm runs.
|
|
5
|
-
* This prevents resource leaks and ensures clean startup.
|
|
6
|
-
*
|
|
7
|
-
* IMPORTANT: Only cleans up sessions for THIS project (based on port).
|
|
8
|
-
* Sessions from other projects are left alone.
|
|
9
|
-
*/
|
|
10
|
-
import { existsSync } from 'node:fs';
|
|
11
|
-
import { resolve } from 'node:path';
|
|
12
|
-
import { logger } from './logger.js';
|
|
13
|
-
import { run } from './shell.js';
|
|
14
|
-
import { getConfig } from './config.js';
|
|
15
|
-
import { loadState, setArchitect } from '../state.js';
|
|
16
|
-
/**
|
|
17
|
-
* Check if a process is still running
|
|
18
|
-
*/
|
|
19
|
-
function isProcessAlive(pid) {
|
|
20
|
-
try {
|
|
21
|
-
process.kill(pid, 0);
|
|
22
|
-
return true;
|
|
23
|
-
}
|
|
24
|
-
catch {
|
|
25
|
-
return false;
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Find tmux sessions that match THIS project's agent-farm patterns
|
|
30
|
-
* Only matches sessions with this project's port to avoid killing other projects
|
|
31
|
-
*/
|
|
32
|
-
async function findOrphanedSessions() {
|
|
33
|
-
const config = getConfig();
|
|
34
|
-
const architectPort = config.architectPort;
|
|
35
|
-
const state = loadState();
|
|
36
|
-
// Project-specific patterns - only match THIS project's architect session
|
|
37
|
-
const architectPattern = new RegExp(`^af-architect-${architectPort}$`);
|
|
38
|
-
const legacyArchitectPattern = /^af-architect$/;
|
|
39
|
-
try {
|
|
40
|
-
const result = await run('tmux list-sessions -F "#{session_name}" 2>/dev/null');
|
|
41
|
-
const sessions = result.stdout.trim().split('\n').filter(Boolean);
|
|
42
|
-
const orphans = [];
|
|
43
|
-
for (const name of sessions) {
|
|
44
|
-
// Check architect sessions - only orphaned if PID is dead
|
|
45
|
-
if (architectPattern.test(name) || legacyArchitectPattern.test(name)) {
|
|
46
|
-
// If we have state for this architect, check if PID is still alive
|
|
47
|
-
if (state.architect) {
|
|
48
|
-
if (!isProcessAlive(state.architect.pid)) {
|
|
49
|
-
// PID is dead but session exists - this is orphaned
|
|
50
|
-
orphans.push({ name, type: 'architect' });
|
|
51
|
-
}
|
|
52
|
-
// If PID is alive, session is NOT orphaned - skip it
|
|
53
|
-
}
|
|
54
|
-
else {
|
|
55
|
-
// No state entry but session exists - orphaned
|
|
56
|
-
orphans.push({ name, type: 'architect' });
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
// Note: builder and util sessions use different naming now (af-shell-UXXXXXX)
|
|
60
|
-
// Those are managed by their own state entries and don't need orphan detection
|
|
61
|
-
}
|
|
62
|
-
return orphans;
|
|
63
|
-
}
|
|
64
|
-
catch {
|
|
65
|
-
// tmux not available or no sessions
|
|
66
|
-
return [];
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
/**
|
|
70
|
-
* Kill an orphaned tmux session
|
|
71
|
-
*/
|
|
72
|
-
async function killSession(name) {
|
|
73
|
-
try {
|
|
74
|
-
await run(`tmux kill-session -t "${name}" 2>/dev/null`);
|
|
75
|
-
return true;
|
|
76
|
-
}
|
|
77
|
-
catch {
|
|
78
|
-
return false;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
/**
|
|
82
|
-
* Check for and handle orphaned sessions on startup
|
|
83
|
-
*
|
|
84
|
-
* Returns the number of sessions that were cleaned up.
|
|
85
|
-
*/
|
|
86
|
-
export async function handleOrphanedSessions(options = {}) {
|
|
87
|
-
const orphans = await findOrphanedSessions();
|
|
88
|
-
if (orphans.length === 0) {
|
|
89
|
-
return 0;
|
|
90
|
-
}
|
|
91
|
-
if (!options.silent) {
|
|
92
|
-
logger.warn(`Found ${orphans.length} orphaned tmux session(s) from previous run:`);
|
|
93
|
-
for (const orphan of orphans) {
|
|
94
|
-
logger.info(` - ${orphan.name} (${orphan.type})`);
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
if (options.kill) {
|
|
98
|
-
let killed = 0;
|
|
99
|
-
for (const orphan of orphans) {
|
|
100
|
-
if (await killSession(orphan.name)) {
|
|
101
|
-
killed++;
|
|
102
|
-
// Clear state entry for killed architects
|
|
103
|
-
if (orphan.type === 'architect') {
|
|
104
|
-
setArchitect(null);
|
|
105
|
-
}
|
|
106
|
-
if (!options.silent) {
|
|
107
|
-
logger.debug(` Killed: ${orphan.name}`);
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
if (!options.silent) {
|
|
112
|
-
logger.info(`Cleaned up ${killed} orphaned session(s)`);
|
|
113
|
-
}
|
|
114
|
-
return killed;
|
|
115
|
-
}
|
|
116
|
-
return 0;
|
|
117
|
-
}
|
|
118
|
-
/**
|
|
119
|
-
* Check for stale artifacts from bash script era
|
|
120
|
-
*/
|
|
121
|
-
export function checkStaleArtifacts(codevDir) {
|
|
122
|
-
const staleFiles = [
|
|
123
|
-
'builders.md', // Old bash state file
|
|
124
|
-
'.architect.pid',
|
|
125
|
-
'.architect.log',
|
|
126
|
-
];
|
|
127
|
-
const found = [];
|
|
128
|
-
for (const file of staleFiles) {
|
|
129
|
-
const path = resolve(codevDir, file);
|
|
130
|
-
if (existsSync(path)) {
|
|
131
|
-
found.push(file);
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
return found;
|
|
135
|
-
}
|
|
136
|
-
/**
|
|
137
|
-
* Warn about stale artifacts if found
|
|
138
|
-
*/
|
|
139
|
-
export function warnAboutStaleArtifacts(codevDir) {
|
|
140
|
-
const stale = checkStaleArtifacts(codevDir);
|
|
141
|
-
if (stale.length > 0) {
|
|
142
|
-
logger.warn('Found stale artifacts from previous bash-based architect:');
|
|
143
|
-
for (const file of stale) {
|
|
144
|
-
logger.info(` - ${file}`);
|
|
145
|
-
}
|
|
146
|
-
logger.info('These can be safely deleted. The new TypeScript implementation uses .agent-farm/');
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
//# sourceMappingURL=orphan-handler.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"orphan-handler.js","sourceRoot":"","sources":["../../../src/agent-farm/utils/orphan-handler.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAEtD;;GAEG;AACH,SAAS,cAAc,CAAC,GAAW;IACjC,IAAI,CAAC;QACH,OAAO,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC;QACrB,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC;AAOD;;;GAGG;AACH,KAAK,UAAU,oBAAoB;IACjC,MAAM,MAAM,GAAG,SAAS,EAAE,CAAC;IAC3B,MAAM,aA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AAC;YACpB,MAAM,CAAC,IAAI,CAAC,cAAc,MAAM,sBAAsB,CAAC,CAAC;QAC1D,CAAC;QAED,OAAO,MAAM,CAAC;IAChB,CAAC;IAED,OAAO,CAAC,CAAC;AACX,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,mBAAmB,CAAC,QAAgB;IAClD,MAAM,UAAU,GAAG;QACjB,aAAa,EAAG,sBAAsB;QACtC,gBAAgB;QAChB,gBAAgB;KACjB,CAAC;IAEF,MAAM,KAAK,GAAa,EAAE,CAAC;IAC3B,KAAK,MAAM,IAAI,IAAI,UAAU,EAAE,CAAC;QAC9B,MAAM,IAAI,GAAG,OAAO,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC;QACrC,IAAI,UAAU,CAAC,IAAI,CAAC,EAAE,CAAC;YACrB,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACnB,CAAC;IACH,CAAC;IAED,OAAO,KAAK,CAAC;AACf,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,uBAAuB,CAAC,QAAgB;IACtD,MAAM,KAAK,GAAG,mBAAmB,CAAC,QAAQ,CAAC,CAAC;IAE5C,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACrB,MAAM,CAAC,IAAI,CAAC,2DAA2D,CAAC,CAAC;QACzE,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;YACzB,MAAM,CAAC,IAAI,CAAC,OAAO,IAAI,EAAE,CAAC,CAAC;QAC7B,CAAC;QACD,MAAM,CAAC,IAAI,CAAC,kFAAkF,CAAC,CAAC;IAClG,CAAC;AACH,CAAC"}
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Global Port Registry
|
|
3
|
-
*
|
|
4
|
-
* Manages port block allocation across multiple repositories to prevent
|
|
5
|
-
* port conflicts when running multiple architect sessions simultaneously.
|
|
6
|
-
*
|
|
7
|
-
* Registry location: ~/.agent-farm/global.db
|
|
8
|
-
* Each repository gets a 100-port block (e.g., 4200-4299, 4300-4399, etc.)
|
|
9
|
-
*
|
|
10
|
-
* Uses SQLite with ACID transactions for proper concurrency handling.
|
|
11
|
-
*/
|
|
12
|
-
import { closeGlobalDb } from '../db/index.js';
|
|
13
|
-
/**
|
|
14
|
-
* Clean up stale registry entries (projects that no longer exist or have dead PIDs)
|
|
15
|
-
* Note: This function is now synchronous
|
|
16
|
-
*/
|
|
17
|
-
export declare function cleanupStaleEntries(): {
|
|
18
|
-
removed: string[];
|
|
19
|
-
remaining: number;
|
|
20
|
-
};
|
|
21
|
-
/**
|
|
22
|
-
* Get or allocate a port block for a project
|
|
23
|
-
* Returns the base port for the project's block
|
|
24
|
-
* Note: This function is now synchronous and uses BEGIN IMMEDIATE for atomicity
|
|
25
|
-
*/
|
|
26
|
-
export declare function getPortBlock(projectRoot: string): number;
|
|
27
|
-
/**
|
|
28
|
-
* Get port configuration for a project
|
|
29
|
-
* Returns all port assignments based on the project's base port
|
|
30
|
-
*/
|
|
31
|
-
export interface ProjectPorts {
|
|
32
|
-
basePort: number;
|
|
33
|
-
dashboardPort: number;
|
|
34
|
-
architectPort: number;
|
|
35
|
-
builderPortRange: [number, number];
|
|
36
|
-
utilPortRange: [number, number];
|
|
37
|
-
openPortRange: [number, number];
|
|
38
|
-
}
|
|
39
|
-
export declare function getProjectPorts(projectRoot: string): ProjectPorts;
|
|
40
|
-
/**
|
|
41
|
-
* List all registered projects and their port blocks
|
|
42
|
-
*/
|
|
43
|
-
export declare function listAllocations(): Array<{
|
|
44
|
-
path: string;
|
|
45
|
-
basePort: number;
|
|
46
|
-
registered: string;
|
|
47
|
-
lastUsed?: string;
|
|
48
|
-
exists: boolean;
|
|
49
|
-
pid?: number;
|
|
50
|
-
pidAlive?: boolean;
|
|
51
|
-
}>;
|
|
52
|
-
/**
|
|
53
|
-
* Remove a project's port allocation
|
|
54
|
-
* Note: This function is now synchronous
|
|
55
|
-
*/
|
|
56
|
-
export declare function removeAllocation(projectRoot: string): boolean;
|
|
57
|
-
export { closeGlobalDb };
|
|
58
|
-
//# sourceMappingURL=port-registry.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"port-registry.d.ts","sourceRoot":"","sources":["../../../src/agent-farm/utils/port-registry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAIH,OAAO,EAAe,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAiC5D;;;GAGG;AACH,wBAAgB,mBAAmB,IAAI;IAAE,OAAO,EAAE,MAAM,EAAE,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE,CAgC9E;AAED;;;;GAIG;AACH,wBAAgB,YAAY,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CA2DxD;AAED;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B,QAAQ,EAAE,MAAM,CAAC;IACjB,aAAa,EAAE,MAAM,CAAC;IACtB,aAAa,EAAE,MAAM,CAAC;IACtB,gBAAgB,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACnC,aAAa,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,aAAa,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACjC;AAED,wBAAgB,eAAe,CAAC,WAAW,EAAE,MAAM,GAAG,YAAY,CAWjE;AAED;;GAEG;AACH,wBAAgB,eAAe,IAAI,KAAK,CAAC;IACvC,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC,CAcD;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAQ7D;AAGD,OAAO,EAAE,aAAa,EAAE,CAAC"}
|
|
@@ -1,166 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Global Port Registry
|
|
3
|
-
*
|
|
4
|
-
* Manages port block allocation across multiple repositories to prevent
|
|
5
|
-
* port conflicts when running multiple architect sessions simultaneously.
|
|
6
|
-
*
|
|
7
|
-
* Registry location: ~/.agent-farm/global.db
|
|
8
|
-
* Each repository gets a 100-port block (e.g., 4200-4299, 4300-4399, etc.)
|
|
9
|
-
*
|
|
10
|
-
* Uses SQLite with ACID transactions for proper concurrency handling.
|
|
11
|
-
*/
|
|
12
|
-
import { existsSync } from 'node:fs';
|
|
13
|
-
import { resolve } from 'node:path';
|
|
14
|
-
import { getGlobalDb, closeGlobalDb } from '../db/index.js';
|
|
15
|
-
// Base port for first allocation (configurable via AF_BASE_PORT env var)
|
|
16
|
-
const BASE_PORT = parseInt(process.env.AF_BASE_PORT || '4200', 10);
|
|
17
|
-
// Ports per project
|
|
18
|
-
const PORT_BLOCK_SIZE = 100;
|
|
19
|
-
// Maximum allocations (4200-9999 = ~58 projects)
|
|
20
|
-
const MAX_ALLOCATIONS = 58;
|
|
21
|
-
// Port blocks to skip (base ports that conflict with system services)
|
|
22
|
-
// 5000: macOS AirPlay Receiver (ControlCenter)
|
|
23
|
-
const BLOCKED_PORT_BLOCKS = [5000];
|
|
24
|
-
/**
|
|
25
|
-
* Check if a process is still running
|
|
26
|
-
*/
|
|
27
|
-
function isProcessAlive(pid) {
|
|
28
|
-
try {
|
|
29
|
-
process.kill(pid, 0);
|
|
30
|
-
return true;
|
|
31
|
-
}
|
|
32
|
-
catch {
|
|
33
|
-
return false;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
/**
|
|
37
|
-
* Check if a project path still exists on disk
|
|
38
|
-
*/
|
|
39
|
-
function projectExists(projectPath) {
|
|
40
|
-
return existsSync(projectPath);
|
|
41
|
-
}
|
|
42
|
-
/**
|
|
43
|
-
* Clean up stale registry entries (projects that no longer exist or have dead PIDs)
|
|
44
|
-
* Note: This function is now synchronous
|
|
45
|
-
*/
|
|
46
|
-
export function cleanupStaleEntries() {
|
|
47
|
-
const db = getGlobalDb();
|
|
48
|
-
const removed = [];
|
|
49
|
-
// Get all allocations
|
|
50
|
-
const allocations = db.prepare('SELECT * FROM port_allocations').all();
|
|
51
|
-
const cleanup = db.transaction(() => {
|
|
52
|
-
for (const alloc of allocations) {
|
|
53
|
-
// Remove if project doesn't exist (skip synthetic keys like "remote:...")
|
|
54
|
-
if (!alloc.project_path.startsWith('remote:') && !projectExists(alloc.project_path)) {
|
|
55
|
-
removed.push(alloc.project_path);
|
|
56
|
-
db.prepare('DELETE FROM port_allocations WHERE project_path = ?').run(alloc.project_path);
|
|
57
|
-
continue;
|
|
58
|
-
}
|
|
59
|
-
// Clear PID if process is stale (process no longer running)
|
|
60
|
-
// Don't remove the entry, just clear the PID - project still exists
|
|
61
|
-
if (alloc.pid && !isProcessAlive(alloc.pid)) {
|
|
62
|
-
db.prepare('UPDATE port_allocations SET pid = NULL WHERE project_path = ?').run(alloc.project_path);
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
});
|
|
66
|
-
cleanup();
|
|
67
|
-
const remaining = db.prepare('SELECT COUNT(*) as count FROM port_allocations').get();
|
|
68
|
-
return {
|
|
69
|
-
removed,
|
|
70
|
-
remaining: remaining.count,
|
|
71
|
-
};
|
|
72
|
-
}
|
|
73
|
-
/**
|
|
74
|
-
* Get or allocate a port block for a project
|
|
75
|
-
* Returns the base port for the project's block
|
|
76
|
-
* Note: This function is now synchronous and uses BEGIN IMMEDIATE for atomicity
|
|
77
|
-
*/
|
|
78
|
-
export function getPortBlock(projectRoot) {
|
|
79
|
-
// Normalize path for consistent keys
|
|
80
|
-
// Don't resolve synthetic keys like "remote:..." - they're not real paths
|
|
81
|
-
const normalizedPath = projectRoot.startsWith('remote:') ? projectRoot : resolve(projectRoot);
|
|
82
|
-
const db = getGlobalDb();
|
|
83
|
-
// Use immediate transaction to prevent race conditions
|
|
84
|
-
const allocate = db.transaction(() => {
|
|
85
|
-
// Check if project already has an allocation
|
|
86
|
-
const existing = db.prepare('SELECT * FROM port_allocations WHERE project_path = ?')
|
|
87
|
-
.get(normalizedPath);
|
|
88
|
-
if (existing) {
|
|
89
|
-
// Update last used timestamp and PID
|
|
90
|
-
db.prepare(`
|
|
91
|
-
UPDATE port_allocations
|
|
92
|
-
SET last_used_at = datetime('now'), pid = ?
|
|
93
|
-
WHERE project_path = ?
|
|
94
|
-
`).run(process.pid, normalizedPath);
|
|
95
|
-
return existing.base_port;
|
|
96
|
-
}
|
|
97
|
-
// Find next available port block (with gap recycling)
|
|
98
|
-
// Get all allocated ports as a Set for O(1) lookup
|
|
99
|
-
const allocated = new Set(db.prepare('SELECT base_port FROM port_allocations').all()
|
|
100
|
-
.map(row => row.base_port));
|
|
101
|
-
// Find the first available port starting from BASE_PORT
|
|
102
|
-
let nextPort = BASE_PORT;
|
|
103
|
-
const maxPossiblePort = BASE_PORT + (MAX_ALLOCATIONS * PORT_BLOCK_SIZE);
|
|
104
|
-
while (nextPort < maxPossiblePort) {
|
|
105
|
-
// Skip if already allocated or blocked
|
|
106
|
-
if (!allocated.has(nextPort) && !BLOCKED_PORT_BLOCKS.includes(nextPort)) {
|
|
107
|
-
break;
|
|
108
|
-
}
|
|
109
|
-
nextPort += PORT_BLOCK_SIZE;
|
|
110
|
-
}
|
|
111
|
-
// Ensure we found an available port
|
|
112
|
-
if (nextPort >= maxPossiblePort) {
|
|
113
|
-
throw new Error('No available port blocks. Maximum allocations reached.');
|
|
114
|
-
}
|
|
115
|
-
// Insert new allocation
|
|
116
|
-
db.prepare(`
|
|
117
|
-
INSERT INTO port_allocations (project_path, base_port, pid)
|
|
118
|
-
VALUES (?, ?, ?)
|
|
119
|
-
`).run(normalizedPath, nextPort, process.pid);
|
|
120
|
-
return nextPort;
|
|
121
|
-
});
|
|
122
|
-
// Use immediate() to serialize with other writers
|
|
123
|
-
return allocate.immediate();
|
|
124
|
-
}
|
|
125
|
-
export function getProjectPorts(projectRoot) {
|
|
126
|
-
const basePort = getPortBlock(projectRoot);
|
|
127
|
-
return {
|
|
128
|
-
basePort,
|
|
129
|
-
dashboardPort: basePort, // 4200
|
|
130
|
-
architectPort: basePort + 1, // 4201
|
|
131
|
-
builderPortRange: [basePort + 10, basePort + 29], // 4210-4229
|
|
132
|
-
utilPortRange: [basePort + 30, basePort + 49], // 4230-4249
|
|
133
|
-
openPortRange: [basePort + 50, basePort + 69], // 4250-4269
|
|
134
|
-
};
|
|
135
|
-
}
|
|
136
|
-
/**
|
|
137
|
-
* List all registered projects and their port blocks
|
|
138
|
-
*/
|
|
139
|
-
export function listAllocations() {
|
|
140
|
-
const db = getGlobalDb();
|
|
141
|
-
const allocations = db.prepare('SELECT * FROM port_allocations ORDER BY base_port').all();
|
|
142
|
-
return allocations.map((alloc) => ({
|
|
143
|
-
path: alloc.project_path,
|
|
144
|
-
basePort: alloc.base_port,
|
|
145
|
-
registered: alloc.registered_at,
|
|
146
|
-
lastUsed: alloc.last_used_at,
|
|
147
|
-
// Remote keys are synthetic - can't check if they exist, assume true
|
|
148
|
-
exists: alloc.project_path.startsWith('remote:') || projectExists(alloc.project_path),
|
|
149
|
-
pid: alloc.pid ?? undefined,
|
|
150
|
-
pidAlive: alloc.pid ? isProcessAlive(alloc.pid) : undefined,
|
|
151
|
-
}));
|
|
152
|
-
}
|
|
153
|
-
/**
|
|
154
|
-
* Remove a project's port allocation
|
|
155
|
-
* Note: This function is now synchronous
|
|
156
|
-
*/
|
|
157
|
-
export function removeAllocation(projectRoot) {
|
|
158
|
-
// Don't resolve synthetic keys like "remote:..."
|
|
159
|
-
const normalizedPath = projectRoot.startsWith('remote:') ? projectRoot : resolve(projectRoot);
|
|
160
|
-
const db = getGlobalDb();
|
|
161
|
-
const result = db.prepare('DELETE FROM port_allocations WHERE project_path = ?').run(normalizedPath);
|
|
162
|
-
return result.changes > 0;
|
|
163
|
-
}
|
|
164
|
-
// Re-export closeGlobalDb for cleanup
|
|
165
|
-
export { closeGlobalDb };
|
|
166
|
-
//# sourceMappingURL=port-registry.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"port-registry.js","sourceRoot":"","sources":["../../../src/agent-farm/utils/port-registry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAG5D,yEAAyE;AACzE,MAAM,SAAS,GAAG,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,IAAI,MAAM,EAAE,EAAE,CAAC,CAAC;AACnE,oBAAoB;AACpB,MAAM,eAAe,GAAG,GAAG,CAAC;AAC5B,iDAAiD;AACjD,MAAM,eAAe,GAAG,EAAE,CAAC;AAE3B,sEAAsE;AACtE,+CAA+C;AAC/C,MAAM,mBAAmB,GAAG,CAAC,IAAI,CAAC,CAAC;AAEnC;;GAEG;AACH,SAAS,cAAc,CAAC,GAAW;IACjC,IAAI,CAAC;QACH,OAAO,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC;QACrB,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC;AAED;;GAEG;AACH,SAAS,aAAa,CAAC,WAAmB;IACxC,OAAO,UAAU,CAAC,WAAW,CAAC,CAAC;AACjC,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,mBAAmB;IACjC,MAAM,EAAE,GAAG,WAAW,EAAE,CAAC;IACzB,MAAM,OAAO,GAAa,EAAE,CAAC;IAE7B,sBAAsB;IACtB,MAAM,WAAW,GAAG,EAAE,CAAC,OAAO,CAAC,gCAAgC,CAAC,CAAC,GAAG,EAAwB,CAAC;IAE7F,MAAM,OAAO,GAAG,EAAE,CAAC,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AgB,CAAC,WAAmB;IAClD,iDAAiD;IACjD,MAAM,cAAc,GAAG,WAAW,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC;IAC9F,MAAM,EAAE,GAAG,WAAW,EAAE,CAAC;IAEzB,MAAM,MAAM,GAAG,EAAE,CAAC,OAAO,CAAC,qDAAqD,CAAC,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;IAErG,OAAO,MAAM,CAAC,OAAO,GAAG,CAAC,CAAC;AAC5B,CAAC;AAED,sCAAsC;AACtC,OAAO,EAAE,aAAa,EAAE,CAAC"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Terminal port lookup utility (Spec 0062 - Secure Remote Access)
|
|
3
|
-
*
|
|
4
|
-
* Provides the port lookup function used by the dashboard reverse proxy.
|
|
5
|
-
* Extracted to a separate module for testability.
|
|
6
|
-
*/
|
|
7
|
-
import type { DashboardState } from '../types.js';
|
|
8
|
-
/**
|
|
9
|
-
* Get the ttyd port for a given terminal ID
|
|
10
|
-
* Returns null if the terminal is not found
|
|
11
|
-
*
|
|
12
|
-
* Terminal ID formats:
|
|
13
|
-
* - 'architect' -> architect terminal
|
|
14
|
-
* - 'builder-{id}' -> builder terminal
|
|
15
|
-
* - 'util-{id}' -> utility terminal
|
|
16
|
-
*/
|
|
17
|
-
export declare function getPortForTerminal(terminalId: string, state: DashboardState): number | null;
|
|
18
|
-
//# sourceMappingURL=terminal-ports.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"terminal-ports.d.ts","sourceRoot":"","sources":["../../../src/agent-farm/utils/terminal-ports.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAElD;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAAC,UAAU,EAAE,MAAM,EAAE,KAAK,EAAE,cAAc,GAAG,MAAM,GAAG,IAAI,CAqB3F"}
|