@surething/cockpit 1.0.278 → 1.0.280
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/.next-prod/BUILD_ID +1 -1
- package/.next-prod/app-path-routes-manifest.json +6 -5
- package/.next-prod/build-manifest.json +2 -2
- package/.next-prod/cockpit-build.json +1 -1
- package/.next-prod/prerender-manifest.json +3 -3
- package/.next-prod/routes-manifest.json +12 -6
- package/.next-prod/server/app/_global-error/page.js +2 -2
- package/.next-prod/server/app/_global-error/page.js.nft.json +1 -1
- package/.next-prod/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/_global-error.html +1 -1
- package/.next-prod/server/app/_global-error.rsc +1 -1
- package/.next-prod/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next-prod/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/.next-prod/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next-prod/server/app/_not-found/page.js +1 -1
- package/.next-prod/server/app/_not-found/page.js.nft.json +1 -1
- package/.next-prod/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/_not-found.html +2 -2
- package/.next-prod/server/app/_not-found.rsc +3 -3
- package/.next-prod/server/app/_not-found.segments/_full.segment.rsc +3 -3
- package/.next-prod/server/app/_not-found.segments/_index.segment.rsc +3 -3
- package/.next-prod/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/.next-prod/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/.next-prod/server/app/api/agent/test/route.js +1 -1
- package/.next-prod/server/app/api/agent/test/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/bash/route.js +1 -1
- package/.next-prod/server/app/api/bash/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/bots/[id]/route.js +1 -1
- package/.next-prod/server/app/api/bots/[id]/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/bots/route.js +1 -1
- package/.next-prod/server/app/api/bots/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/codex/route.js +1 -1
- package/.next-prod/server/app/api/chat/codex/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/deepseek/route.js +1 -1
- package/.next-prod/server/app/api/chat/deepseek/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/glm/route.js +1 -1
- package/.next-prod/server/app/api/chat/glm/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/kimi/route.js +1 -1
- package/.next-prod/server/app/api/chat/kimi/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/ollama/route.js +1 -1
- package/.next-prod/server/app/api/chat/ollama/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/route.js +1 -1
- package/.next-prod/server/app/api/chat/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/chat/stop/route.js +1 -1
- package/.next-prod/server/app/api/chat/stop/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/claude-stats/route.js +1 -1
- package/.next-prod/server/app/api/claude-stats/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/commands/route.js +1 -1
- package/.next-prod/server/app/api/commands/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/comments/route.js +1 -1
- package/.next-prod/server/app/api/comments/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/columns/route.js +2 -2
- package/.next-prod/server/app/api/db/columns/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/connect/route.js +1 -1
- package/.next-prod/server/app/api/db/connect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/disconnect/route.js +1 -1
- package/.next-prod/server/app/api/db/disconnect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/export/route.js +1 -1
- package/.next-prod/server/app/api/db/export/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/query/route.js +1 -1
- package/.next-prod/server/app/api/db/query/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/db/schemas/route.js +2 -2
- package/.next-prod/server/app/api/db/schemas/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/deepseek/balance/route.js +1 -1
- package/.next-prod/server/app/api/deepseek/balance/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/deepseek/credentials/route.js +1 -1
- package/.next-prod/server/app/api/deepseek/credentials/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/deepseek/models/route.js +1 -1
- package/.next-prod/server/app/api/deepseek/models/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/dev/spans/route.js +1 -1
- package/.next-prod/server/app/api/dev/spans/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/extension/version/route.js +1 -1
- package/.next-prod/server/app/api/extension/version/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/file/route.js +1 -1
- package/.next-prod/server/app/api/file/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/blame/route.js +1 -1
- package/.next-prod/server/app/api/files/blame/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/clipboard/route.js +1 -1
- package/.next-prod/server/app/api/files/clipboard/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/copy/route.js +1 -1
- package/.next-prod/server/app/api/files/copy/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/delete/route.js +1 -1
- package/.next-prod/server/app/api/files/delete/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/expanded/route.js +1 -1
- package/.next-prod/server/app/api/files/expanded/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/index/route.js +1 -1
- package/.next-prod/server/app/api/files/index/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/init/route.js +1 -1
- package/.next-prod/server/app/api/files/init/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/paste/route.js +1 -1
- package/.next-prod/server/app/api/files/paste/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/read/route.js +1 -1
- package/.next-prod/server/app/api/files/read/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/readdir/route.js +1 -1
- package/.next-prod/server/app/api/files/readdir/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/recent/route.js +1 -1
- package/.next-prod/server/app/api/files/recent/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/save/route.js +1 -1
- package/.next-prod/server/app/api/files/save/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/search/route.js +1 -1
- package/.next-prod/server/app/api/files/search/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/stat/route.js +1 -1
- package/.next-prod/server/app/api/files/stat/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/files/text/route.js +1 -1
- package/.next-prod/server/app/api/files/text/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/fs/dirs/route.js +1 -0
- package/.next-prod/server/app/api/fs/dirs/route.js.nft.json +1 -0
- package/.next-prod/server/app/api/fs/dirs/route_client-reference-manifest.js +1 -0
- package/.next-prod/server/app/api/git/blob/route.js +1 -1
- package/.next-prod/server/app/api/git/blob/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/branch-diff/route.js +1 -1
- package/.next-prod/server/app/api/git/branch-diff/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/branches/route.js +1 -1
- package/.next-prod/server/app/api/git/branches/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/commit-diff/route.js +1 -1
- package/.next-prod/server/app/api/git/commit-diff/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/commits/route.js +1 -1
- package/.next-prod/server/app/api/git/commits/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/current-branch/route.js +1 -1
- package/.next-prod/server/app/api/git/current-branch/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/diff/route.js +1 -1
- package/.next-prod/server/app/api/git/diff/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/discard/route.js +1 -1
- package/.next-prod/server/app/api/git/discard/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/stage/route.js +1 -1
- package/.next-prod/server/app/api/git/stage/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/status/route.js +1 -1
- package/.next-prod/server/app/api/git/status/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/unstage/route.js +1 -1
- package/.next-prod/server/app/api/git/unstage/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/git/worktree/route.js +1 -1
- package/.next-prod/server/app/api/git/worktree/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/glm/credentials/route.js +1 -1
- package/.next-prod/server/app/api/glm/credentials/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/glm/models/route.js +1 -1
- package/.next-prod/server/app/api/glm/models/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/glm/usage/route.js +1 -1
- package/.next-prod/server/app/api/glm/usage/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/global-state/route.js +2 -2
- package/.next-prod/server/app/api/global-state/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/health/route.js +1 -1
- package/.next-prod/server/app/api/health/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/html-apps/[id]/route.js +1 -1
- package/.next-prod/server/app/api/html-apps/[id]/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/html-apps/route.js +1 -1
- package/.next-prod/server/app/api/html-apps/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/instructions/config/route.js +1 -1
- package/.next-prod/server/app/api/instructions/config/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/kimi/credentials/route.js +1 -1
- package/.next-prod/server/app/api/kimi/credentials/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/kimi/models/route.js +1 -1
- package/.next-prod/server/app/api/kimi/models/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/kimi/usage/route.js +1 -1
- package/.next-prod/server/app/api/kimi/usage/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/definition/route.js +1 -1
- package/.next-prod/server/app/api/lsp/definition/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/hover/route.js +1 -1
- package/.next-prod/server/app/api/lsp/hover/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/references/route.js +1 -1
- package/.next-prod/server/app/api/lsp/references/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/status/route.js +1 -1
- package/.next-prod/server/app/api/lsp/status/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/lsp/warmup/route.js +1 -1
- package/.next-prod/server/app/api/lsp/warmup/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/columns/route.js +2 -2
- package/.next-prod/server/app/api/mysql/columns/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/connect/route.js +1 -1
- package/.next-prod/server/app/api/mysql/connect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/disconnect/route.js +1 -1
- package/.next-prod/server/app/api/mysql/disconnect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/export/route.js +1 -1
- package/.next-prod/server/app/api/mysql/export/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/query/route.js +1 -1
- package/.next-prod/server/app/api/mysql/query/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/mysql/schemas/route.js +2 -2
- package/.next-prod/server/app/api/mysql/schemas/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/neo4j/connect/route.js +1 -1
- package/.next-prod/server/app/api/neo4j/connect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/neo4j/disconnect/route.js +1 -1
- package/.next-prod/server/app/api/neo4j/disconnect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/neo4j/query/route.js +1 -1
- package/.next-prod/server/app/api/neo4j/query/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/neo4j/schema/route.js +1 -1
- package/.next-prod/server/app/api/neo4j/schema/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/note/route.js +1 -1
- package/.next-prod/server/app/api/note/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/ollama/config/route.js +1 -1
- package/.next-prod/server/app/api/ollama/config/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/ollama/default-model/route.js +1 -1
- package/.next-prod/server/app/api/ollama/default-model/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/ollama/models/route.js +1 -1
- package/.next-prod/server/app/api/ollama/models/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/ollama/start/route.js +1 -1
- package/.next-prod/server/app/api/ollama/start/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/open-cursor/route.js +1 -1
- package/.next-prod/server/app/api/open-cursor/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/open-vscode/route.js +1 -1
- package/.next-prod/server/app/api/open-vscode/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/output-styles/config/route.js +1 -1
- package/.next-prod/server/app/api/output-styles/config/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/pinned-sessions/route.js +1 -1
- package/.next-prod/server/app/api/pinned-sessions/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/project-settings/route.js +1 -1
- package/.next-prod/server/app/api/project-settings/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/project-state/route.js +1 -1
- package/.next-prod/server/app/api/project-state/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/affected/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/affected/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/callees/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/callees/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/callers/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/callers/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/coedit/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/coedit/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/context/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/context/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/file/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/file/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/file-functions/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/file-functions/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/impact/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/impact/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/related/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/related/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/risk/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/risk/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projectGraph/search/route.js +1 -1
- package/.next-prod/server/app/api/projectGraph/search/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/projects/route.js +1 -1
- package/.next-prod/server/app/api/projects/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/push/public-key/route.js +1 -1
- package/.next-prod/server/app/api/push/public-key/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/push/subscribe/route.js +1 -1
- package/.next-prod/server/app/api/push/subscribe/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/push/unsubscribe/route.js +1 -1
- package/.next-prod/server/app/api/push/unsubscribe/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/command/route.js +1 -1
- package/.next-prod/server/app/api/redis/command/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/connect/route.js +1 -1
- package/.next-prod/server/app/api/redis/connect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/delete/route.js +1 -1
- package/.next-prod/server/app/api/redis/delete/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/disconnect/route.js +1 -1
- package/.next-prod/server/app/api/redis/disconnect/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/get/route.js +1 -1
- package/.next-prod/server/app/api/redis/get/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/keys/route.js +1 -1
- package/.next-prod/server/app/api/redis/keys/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/redis/set/route.js +1 -1
- package/.next-prod/server/app/api/redis/set/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/restart/route.js +1 -1
- package/.next-prod/server/app/api/restart/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/[id]/comments/route.js +1 -1
- package/.next-prod/server/app/api/review/[id]/comments/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/[id]/replies/route.js +1 -1
- package/.next-prod/server/app/api/review/[id]/replies/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/[id]/route.js +1 -1
- package/.next-prod/server/app/api/review/[id]/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/identify/route.js +1 -1
- package/.next-prod/server/app/api/review/identify/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/order/route.js +1 -1
- package/.next-prod/server/app/api/review/order/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/route.js +1 -1
- package/.next-prod/server/app/api/review/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/share-info/route.js +1 -1
- package/.next-prod/server/app/api/review/share-info/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/review/users/route.js +1 -1
- package/.next-prod/server/app/api/review/users/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/scheduled-tasks/route.js +2 -2
- package/.next-prod/server/app/api/scheduled-tasks/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/services/config/route.js +1 -1
- package/.next-prod/server/app/api/services/config/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/services/scripts/route.js +1 -1
- package/.next-prod/server/app/api/services/scripts/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/fork/route.js +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/fork/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/history/route.js +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/history/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/session/[sessionId]/turn/route.js +2 -2
- package/.next-prod/server/app/api/session/[sessionId]/turn/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/session/user-messages/route.js +1 -1
- package/.next-prod/server/app/api/session/user-messages/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/session-by-path/route.js +1 -1
- package/.next-prod/server/app/api/session-by-path/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/sessions/delegate/route.js +1 -1
- package/.next-prod/server/app/api/sessions/delegate/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/sessions/projects/[encodedPath]/route.js +1 -1
- package/.next-prod/server/app/api/sessions/projects/[encodedPath]/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/sessions/projects/route.js +1 -1
- package/.next-prod/server/app/api/sessions/projects/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/sessions/search/route.js +1 -1
- package/.next-prod/server/app/api/sessions/search/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/sessions/status/route.js +1 -1
- package/.next-prod/server/app/api/sessions/status/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/settings/route.js +1 -1
- package/.next-prod/server/app/api/settings/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/shutdown/route.js +1 -1
- package/.next-prod/server/app/api/shutdown/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/skills/[id]/route.js +1 -1
- package/.next-prod/server/app/api/skills/[id]/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/skills/content/route.js +1 -1
- package/.next-prod/server/app/api/skills/content/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/skills/route.js +1 -1
- package/.next-prod/server/app/api/skills/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/snapshots/blob/route.js +1 -1
- package/.next-prod/server/app/api/snapshots/blob/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/snapshots/diff/route.js +1 -1
- package/.next-prod/server/app/api/snapshots/diff/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/snapshots/range-diff/route.js +1 -1
- package/.next-prod/server/app/api/snapshots/range-diff/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/snapshots/route.js +1 -1
- package/.next-prod/server/app/api/snapshots/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/aliases/route.js +1 -1
- package/.next-prod/server/app/api/terminal/aliases/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/autocomplete/route.js +1 -1
- package/.next-prod/server/app/api/terminal/autocomplete/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/bubble-order/route.js +1 -1
- package/.next-prod/server/app/api/terminal/bubble-order/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/env/route.js +1 -1
- package/.next-prod/server/app/api/terminal/env/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/history/route.js +1 -1
- package/.next-prod/server/app/api/terminal/history/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/terminal/running/route.js +1 -0
- package/.next-prod/server/app/api/terminal/running/route.js.nft.json +1 -0
- package/.next-prod/server/app/api/terminal/running/route_client-reference-manifest.js +1 -0
- package/.next-prod/server/app/api/update/route.js +1 -1
- package/.next-prod/server/app/api/update/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/update-state/route.js +1 -1
- package/.next-prod/server/app/api/update-state/route.js.nft.json +1 -1
- package/.next-prod/server/app/api/version/route.js +1 -1
- package/.next-prod/server/app/api/version/route.js.nft.json +1 -1
- package/.next-prod/server/app/apps/[...path]/route.js +1 -1
- package/.next-prod/server/app/apps/[...path]/route.js.nft.json +1 -1
- package/.next-prod/server/app/favicon.ico/route.js +1 -1
- package/.next-prod/server/app/favicon.ico/route.js.nft.json +1 -1
- package/.next-prod/server/app/m/page.js +1 -1
- package/.next-prod/server/app/m/page.js.nft.json +1 -1
- package/.next-prod/server/app/m/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/manifest.webmanifest/route.js +2 -2
- package/.next-prod/server/app/manifest.webmanifest/route.js.nft.json +1 -1
- package/.next-prod/server/app/page.js +1 -1
- package/.next-prod/server/app/page.js.nft.json +1 -1
- package/.next-prod/server/app/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/project/page.js +1 -1
- package/.next-prod/server/app/project/page.js.nft.json +1 -1
- package/.next-prod/server/app/project/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app/review/[id]/page.js +1 -1
- package/.next-prod/server/app/review/[id]/page.js.nft.json +1 -1
- package/.next-prod/server/app/review/[id]/page_client-reference-manifest.js +1 -1
- package/.next-prod/server/app-paths-manifest.json +6 -5
- package/.next-prod/server/chunks/1863.js +1 -0
- package/.next-prod/server/chunks/2493.js +9 -9
- package/.next-prod/server/chunks/411.js +1 -0
- package/.next-prod/server/chunks/5591.js +2 -2
- package/.next-prod/server/chunks/7438.js +18 -17
- package/.next-prod/server/chunks/7918.js +1 -0
- package/.next-prod/server/chunks/8022.js +1 -1
- package/.next-prod/server/middleware-build-manifest.js +1 -1
- package/.next-prod/server/pages/404.html +2 -2
- package/.next-prod/server/pages/500.html +1 -1
- package/.next-prod/server/server-reference-manifest.json +1 -1
- package/.next-prod/static/_195_hPNVuma2vZS7bpTW/_buildManifest.js +1 -0
- package/.next-prod/static/chunks/81016-71999ca5bd6a6b2f.js +36 -0
- package/.next-prod/static/chunks/{95313-eb607273c688b022.js → 95313-af5cc33125d6c0ff.js} +3 -3
- package/.next-prod/static/chunks/99092-d9525c22b942b051.js +716 -0
- package/.next-prod/static/chunks/app/_global-error/page-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/agent/test/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/bash/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/bots/[id]/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/bots/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/codex/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/deepseek/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/glm/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/kimi/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/ollama/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/chat/stop/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/claude-stats/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/commands/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/comments/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/db/columns/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/db/connect/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/db/disconnect/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/db/export/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/db/query/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/db/schemas/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/deepseek/balance/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/deepseek/credentials/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/deepseek/models/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/dev/spans/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/extension/version/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/file/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/blame/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/clipboard/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/copy/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/delete/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/expanded/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/index/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/init/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/paste/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/read/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/readdir/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/recent/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/save/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/search/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/stat/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/files/text/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/fs/dirs/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/blob/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/branch-diff/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/branches/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/commit-diff/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/commits/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/current-branch/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/diff/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/discard/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/stage/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/status/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/unstage/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/git/worktree/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/glm/credentials/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/glm/models/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/glm/usage/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/global-state/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/health/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/html-apps/[id]/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/html-apps/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/instructions/config/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/kimi/credentials/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/kimi/models/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/kimi/usage/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/definition/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/hover/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/references/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/status/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/lsp/warmup/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/columns/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/connect/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/disconnect/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/export/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/query/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/mysql/schemas/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/neo4j/connect/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/neo4j/disconnect/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/neo4j/query/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/neo4j/schema/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/note/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/ollama/config/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/ollama/default-model/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/ollama/models/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/ollama/start/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/open-cursor/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/open-vscode/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/output-styles/config/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/pinned-sessions/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/project-settings/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/project-state/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/affected/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/callees/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/callers/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/coedit/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/context/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/file/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/file-functions/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/impact/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/related/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/risk/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projectGraph/search/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/projects/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/push/public-key/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/push/subscribe/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/push/unsubscribe/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/command/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/connect/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/delete/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/disconnect/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/get/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/keys/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/redis/set/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/restart/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/review/[id]/comments/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/review/[id]/replies/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/review/[id]/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/review/identify/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/review/order/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/review/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/review/share-info/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/review/users/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/scheduled-tasks/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/services/config/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/services/scripts/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/session/[sessionId]/fork/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/session/[sessionId]/history/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/session/[sessionId]/turn/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/session/user-messages/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/session-by-path/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/sessions/delegate/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/sessions/projects/[encodedPath]/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/sessions/projects/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/sessions/search/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/sessions/status/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/settings/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/shutdown/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/skills/[id]/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/skills/content/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/skills/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/snapshots/blob/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/snapshots/diff/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/snapshots/range-diff/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/snapshots/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/aliases/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/autocomplete/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/bubble-order/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/env/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/history/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/terminal/running/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/update/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/update-state/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/api/version/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/apps/[...path]/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/{layout-589122feb9071556.js → layout-0c3dcac0764d9e97.js} +1 -1
- package/.next-prod/static/chunks/app/manifest.webmanifest/route-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/app/page-b472e7f948959009.js +1 -0
- package/.next-prod/static/chunks/app/project/page-b472e7f948959009.js +1 -0
- package/.next-prod/static/chunks/next/dist/client/components/builtin/app-error-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/next/dist/client/components/builtin/forbidden-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/next/dist/client/components/builtin/not-found-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/chunks/next/dist/client/components/builtin/unauthorized-4e18b53a1ed48d45.js +1 -0
- package/.next-prod/static/css/e70d0cefe04f0619.css +1 -0
- package/.next-prod/trace +15 -15
- package/.next-prod/trace-build +1 -1
- package/.next-prod/types/app/api/{pick-folder → fs/dirs}/route.ts +3 -3
- package/.next-prod/types/app/api/terminal/running/route.ts +353 -0
- package/.next-prod/types/routes.d.ts +3 -2
- package/.next-prod/types/validator.ts +18 -9
- package/bin/pty-host.mjs +423 -0
- package/dist/{chunk-LPZXJPD6.mjs → chunk-3LSLUAN6.mjs} +143 -95
- package/dist/{chunk-W5MB7DIM.mjs → chunk-N6CFCP2N.mjs} +655 -9
- package/dist/httpApi.mjs +7 -3
- package/dist/scheduledTasks.mjs +67 -11
- package/dist/wsServer.mjs +118 -141
- package/package.json +3 -3
- package/server.mjs +12 -0
- package/skills/cr/SKILL.md +306 -126
- package/skills/ex/SKILL.md +39 -59
- package/skills/fx/SKILL.md +46 -4
- package/skills/go/SKILL.md +26 -87
- package/skills/qa/SKILL.md +46 -36
- package/.next-prod/server/app/api/pick-folder/route.js +0 -1
- package/.next-prod/server/app/api/pick-folder/route.js.nft.json +0 -1
- package/.next-prod/server/app/api/pick-folder/route_client-reference-manifest.js +0 -1
- package/.next-prod/server/chunks/6548.js +0 -1
- package/.next-prod/static/I8gbcTQRiRdMF09goE7WI/_buildManifest.js +0 -1
- package/.next-prod/static/chunks/60875-acaae14dd7ddcd91.js +0 -35
- package/.next-prod/static/chunks/99092-f94ee242866d22b9.js +0 -716
- package/.next-prod/static/chunks/app/_global-error/page-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/agent/test/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/bash/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/bots/[id]/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/bots/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/codex/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/deepseek/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/glm/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/kimi/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/ollama/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/chat/stop/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/claude-stats/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/commands/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/comments/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/db/columns/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/db/connect/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/db/disconnect/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/db/export/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/db/query/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/db/schemas/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/deepseek/balance/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/deepseek/credentials/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/deepseek/models/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/dev/spans/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/extension/version/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/file/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/blame/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/clipboard/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/copy/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/delete/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/expanded/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/index/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/init/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/paste/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/read/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/readdir/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/recent/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/save/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/search/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/stat/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/files/text/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/blob/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/branch-diff/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/branches/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/commit-diff/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/commits/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/current-branch/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/diff/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/discard/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/stage/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/status/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/unstage/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/git/worktree/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/glm/credentials/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/glm/models/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/glm/usage/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/global-state/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/health/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/html-apps/[id]/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/html-apps/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/instructions/config/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/kimi/credentials/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/kimi/models/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/kimi/usage/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/definition/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/hover/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/references/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/status/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/lsp/warmup/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/columns/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/connect/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/disconnect/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/export/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/query/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/mysql/schemas/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/neo4j/connect/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/neo4j/disconnect/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/neo4j/query/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/neo4j/schema/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/note/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/ollama/config/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/ollama/default-model/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/ollama/models/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/ollama/start/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/open-cursor/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/open-vscode/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/output-styles/config/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/pick-folder/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/pinned-sessions/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/project-settings/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/project-state/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/affected/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/callees/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/callers/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/coedit/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/context/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/file/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/file-functions/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/impact/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/related/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/risk/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projectGraph/search/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/projects/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/push/public-key/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/push/subscribe/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/push/unsubscribe/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/command/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/connect/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/delete/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/disconnect/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/get/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/keys/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/redis/set/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/restart/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/review/[id]/comments/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/review/[id]/replies/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/review/[id]/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/review/identify/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/review/order/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/review/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/review/share-info/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/review/users/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/scheduled-tasks/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/services/config/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/services/scripts/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/session/[sessionId]/fork/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/session/[sessionId]/history/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/session/[sessionId]/turn/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/session/user-messages/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/session-by-path/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/sessions/delegate/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/sessions/projects/[encodedPath]/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/sessions/projects/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/sessions/search/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/sessions/status/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/settings/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/shutdown/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/skills/[id]/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/skills/content/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/skills/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/snapshots/blob/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/snapshots/diff/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/snapshots/range-diff/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/snapshots/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/aliases/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/autocomplete/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/bubble-order/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/env/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/terminal/history/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/update/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/update-state/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/api/version/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/apps/[...path]/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/manifest.webmanifest/route-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/app/page-a69072e6dbd4a059.js +0 -1
- package/.next-prod/static/chunks/app/project/page-a69072e6dbd4a059.js +0 -1
- package/.next-prod/static/chunks/next/dist/client/components/builtin/app-error-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/next/dist/client/components/builtin/forbidden-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/next/dist/client/components/builtin/not-found-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/chunks/next/dist/client/components/builtin/unauthorized-b3c86dd8f06140fe.js +0 -1
- package/.next-prod/static/css/2abfec9d3e93011f.css +0 -1
- package/skills/ap/SKILL.md +0 -18
- /package/.next-prod/static/{I8gbcTQRiRdMF09goE7WI → _195_hPNVuma2vZS7bpTW}/_ssgManifest.js +0 -0
package/bin/pty-host.mjs
ADDED
|
@@ -0,0 +1,423 @@
|
|
|
1
|
+
// PTY host: owns every terminal bubble — PTY and pipe mode — so they outlive a
|
|
2
|
+
// server restart.
|
|
3
|
+
//
|
|
4
|
+
// Why a separate process: a PTY's controlling side (the master fd) belongs to
|
|
5
|
+
// whoever spawned it. When that was the cockpit server, every update/restart
|
|
6
|
+
// took all running terminals down with it — the server kills its children on
|
|
7
|
+
// exit, and even a surviving child gets SIGHUP the moment the master closes.
|
|
8
|
+
// Here the server is only a client over a local socket; it can come and go and
|
|
9
|
+
// the shells keep running. On reconnect it gets each session back together
|
|
10
|
+
// with the output it missed.
|
|
11
|
+
//
|
|
12
|
+
// SELF-CONTAINED BY REQUIREMENT — Node builtins + node-pty only. Like
|
|
13
|
+
// updater.mjs this runs from a staged copy under <cockpitHome>/pty-host/, never
|
|
14
|
+
// from the install directory: `npm i -g` replaces that directory while we are
|
|
15
|
+
// alive, and on Windows node-pty's loaded .node files would lock it and make
|
|
16
|
+
// the install fail outright.
|
|
17
|
+
//
|
|
18
|
+
// Two modes:
|
|
19
|
+
// --launch Run from the install dir by the server. Stages this script and
|
|
20
|
+
// node-pty into --dir, spawns the staged copy with --serve fully
|
|
21
|
+
// detached, and exits at once. Exiting is the point: the real host
|
|
22
|
+
// is then nobody's child, so the server's exit-time child cleanup
|
|
23
|
+
// (`pkill -P <server>` / its Windows equivalent) cannot reach it.
|
|
24
|
+
// --serve The host itself.
|
|
25
|
+
//
|
|
26
|
+
// Protocol: newline-delimited JSON over a unix socket (named pipe on Windows).
|
|
27
|
+
// No compatibility is kept across host code changes: `hello` reports BUILD (a
|
|
28
|
+
// hash of this file), and a server whose bin/pty-host.mjs hashes differently
|
|
29
|
+
// shuts this host down and launches its own — the sessions here end with it.
|
|
30
|
+
// Changes that leave this file untouched keep terminals alive across updates.
|
|
31
|
+
//
|
|
32
|
+
// client -> host host -> client
|
|
33
|
+
// hello hello {proto, build, pid, sessions[]}
|
|
34
|
+
// spawn {id,kind,file,args,cwd,env,..} spawned {id,pid} | spawnError {id,error}
|
|
35
|
+
// write {id,data} data {id,data,stream?}
|
|
36
|
+
// eof {id} close a pipe's stdin exit {id,exitCode,signal}
|
|
37
|
+
// resize {id,cols,rows}
|
|
38
|
+
// kill {id,signal?}
|
|
39
|
+
// ack {id} drop an exited session (the server has persisted it)
|
|
40
|
+
// shutdown kill everything and exit (`cockpit stop`)
|
|
41
|
+
//
|
|
42
|
+
// kind is 'pty' (default) or 'pipe'. A pipe command is a plain child with
|
|
43
|
+
// separate stdout/stderr (`stream` on its data events) and no TTY.
|
|
44
|
+
import { spawn } from 'child_process';
|
|
45
|
+
import { createHash } from 'crypto';
|
|
46
|
+
import { appendFileSync, cpSync, existsSync, mkdirSync, openSync, readFileSync, rmSync, unlinkSync, writeFileSync } from 'fs';
|
|
47
|
+
import { createServer, connect } from 'net';
|
|
48
|
+
import { createRequire } from 'module';
|
|
49
|
+
import { dirname, join } from 'path';
|
|
50
|
+
import { fileURLToPath } from 'url';
|
|
51
|
+
|
|
52
|
+
const PROTOCOL = 1;
|
|
53
|
+
/** Identifies this exact host code; must match hostBuildId() in ptyHostClient.ts. */
|
|
54
|
+
const BUILD = createHash('sha1').update(readFileSync(fileURLToPath(import.meta.url))).digest('hex').slice(0, 12);
|
|
55
|
+
/** Per-session replay buffer while no server is watching (matches the server's ring). */
|
|
56
|
+
const RING_MAX = 2 * 1024 * 1024;
|
|
57
|
+
/** Exit this long after the last client left, provided no session remains. */
|
|
58
|
+
const IDLE_EXIT_MS = 10_000;
|
|
59
|
+
|
|
60
|
+
function arg(name, fallback = null) {
|
|
61
|
+
const i = process.argv.indexOf(`--${name}`);
|
|
62
|
+
return i !== -1 && process.argv[i + 1] ? process.argv[i + 1] : fallback;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
const socketPath = arg('socket');
|
|
66
|
+
const stageDir = arg('dir');
|
|
67
|
+
const title = arg('title', 'cockpit-pty');
|
|
68
|
+
const logPath = arg('log');
|
|
69
|
+
|
|
70
|
+
if (!socketPath || !stageDir) {
|
|
71
|
+
console.error('pty-host: --socket and --dir are required');
|
|
72
|
+
process.exit(2);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
function log(line) {
|
|
76
|
+
const stamped = `[${new Date().toISOString()}] [pty-host ${process.pid}] ${line}\n`;
|
|
77
|
+
if (!logPath) return;
|
|
78
|
+
try { appendFileSync(logPath, stamped); } catch { /* logging must never kill the host */ }
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
// ─────────────────────────────────────────────────────────
|
|
82
|
+
// --launch
|
|
83
|
+
// ─────────────────────────────────────────────────────────
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* Copy node-pty's runtime files next to the staged script.
|
|
87
|
+
*
|
|
88
|
+
* Only what loads at runtime — lib/, package.json and the native binaries for
|
|
89
|
+
* this platform (a local build/Release wins over prebuilds, same order
|
|
90
|
+
* node-pty's own loader uses). The full package is ~60MB of sources and other
|
|
91
|
+
* platforms' prebuilds. Skipped when the stamp says the same node-pty was
|
|
92
|
+
* already staged from the same place; node-pty uses N-API, so a Node upgrade
|
|
93
|
+
* does not invalidate the binaries.
|
|
94
|
+
*/
|
|
95
|
+
function stageNodePty() {
|
|
96
|
+
const require = createRequire(import.meta.url);
|
|
97
|
+
const src = dirname(require.resolve('node-pty/package.json'));
|
|
98
|
+
const dest = join(stageDir, 'node_modules', 'node-pty');
|
|
99
|
+
const version = JSON.parse(readFileSync(join(src, 'package.json'), 'utf8')).version;
|
|
100
|
+
const stamp = `${version}\n${src}\n${process.platform}-${process.arch}\n`;
|
|
101
|
+
const stampPath = join(stageDir, 'node-pty.stamp');
|
|
102
|
+
try {
|
|
103
|
+
if (readFileSync(stampPath, 'utf8') === stamp && existsSync(join(dest, 'package.json'))) return;
|
|
104
|
+
} catch { /* no stamp yet */ }
|
|
105
|
+
|
|
106
|
+
rmSync(dest, { recursive: true, force: true });
|
|
107
|
+
mkdirSync(dest, { recursive: true });
|
|
108
|
+
cpSync(join(src, 'package.json'), join(dest, 'package.json'));
|
|
109
|
+
cpSync(join(src, 'lib'), join(dest, 'lib'), { recursive: true });
|
|
110
|
+
const built = join(src, 'build', 'Release');
|
|
111
|
+
const prebuilt = join(src, 'prebuilds', `${process.platform}-${process.arch}`);
|
|
112
|
+
if (existsSync(built)) cpSync(built, join(dest, 'build', 'Release'), { recursive: true });
|
|
113
|
+
if (existsSync(prebuilt)) cpSync(prebuilt, join(dest, 'prebuilds', `${process.platform}-${process.arch}`), { recursive: true });
|
|
114
|
+
writeFileSync(stampPath, stamp);
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
function launch() {
|
|
118
|
+
mkdirSync(stageDir, { recursive: true });
|
|
119
|
+
if (logPath) mkdirSync(dirname(logPath), { recursive: true });
|
|
120
|
+
const staged = join(stageDir, 'pty-host.mjs');
|
|
121
|
+
try {
|
|
122
|
+
stageNodePty();
|
|
123
|
+
cpSync(fileURLToPath(import.meta.url), staged);
|
|
124
|
+
} catch (e) {
|
|
125
|
+
// A previous host from this same protocol can still be exiting and, on
|
|
126
|
+
// Windows, holding these files. If a staged copy exists it is compatible
|
|
127
|
+
// by definition (same PROTOCOL directory), so run that.
|
|
128
|
+
if (!existsSync(staged)) {
|
|
129
|
+
log(`launch: staging failed: ${e.message}`);
|
|
130
|
+
process.exit(1);
|
|
131
|
+
}
|
|
132
|
+
log(`launch: staging failed, reusing existing copy: ${e.message}`);
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
const out = logPath ? openSync(logPath, 'a') : 'ignore';
|
|
136
|
+
const child = spawn(
|
|
137
|
+
process.execPath,
|
|
138
|
+
[staged, '--serve', '--socket', socketPath, '--dir', stageDir, '--title', title, ...(logPath ? ['--log', logPath] : [])],
|
|
139
|
+
{
|
|
140
|
+
// Never the install dir: on Windows a process's cwd blocks that
|
|
141
|
+
// directory from being replaced.
|
|
142
|
+
cwd: stageDir,
|
|
143
|
+
env: process.env,
|
|
144
|
+
// New session on POSIX: no controlling terminal, so a Ctrl-C in the
|
|
145
|
+
// shell that runs `npm run dev` never reaches us.
|
|
146
|
+
detached: true,
|
|
147
|
+
windowsHide: true,
|
|
148
|
+
stdio: ['ignore', out, out],
|
|
149
|
+
},
|
|
150
|
+
);
|
|
151
|
+
child.unref();
|
|
152
|
+
process.exit(0);
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
// ─────────────────────────────────────────────────────────
|
|
156
|
+
// --serve
|
|
157
|
+
// ─────────────────────────────────────────────────────────
|
|
158
|
+
|
|
159
|
+
/** Byte-capped replay buffer. Trimming may split an escape sequence; the
|
|
160
|
+
* server's findSafeStart() already handles that on replay. */
|
|
161
|
+
class Ring {
|
|
162
|
+
chunks = [];
|
|
163
|
+
len = 0;
|
|
164
|
+
append(data) {
|
|
165
|
+
this.chunks.push(data);
|
|
166
|
+
this.len += data.length;
|
|
167
|
+
while (this.len > RING_MAX && this.chunks.length > 0) {
|
|
168
|
+
const over = this.len - RING_MAX;
|
|
169
|
+
const head = this.chunks[0];
|
|
170
|
+
if (head.length <= over) {
|
|
171
|
+
this.chunks.shift();
|
|
172
|
+
this.len -= head.length;
|
|
173
|
+
} else {
|
|
174
|
+
this.chunks[0] = head.slice(over);
|
|
175
|
+
this.len -= over;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
snapshot() {
|
|
180
|
+
return this.chunks.join('');
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
async function serve() {
|
|
185
|
+
process.title = title;
|
|
186
|
+
const require = createRequire(import.meta.url);
|
|
187
|
+
const pty = require('node-pty');
|
|
188
|
+
|
|
189
|
+
/** id -> { kind, pty | child, pid, meta, ring, exited, exitCode, signal } */
|
|
190
|
+
const sessions = new Map();
|
|
191
|
+
const clients = new Set();
|
|
192
|
+
let idleTimer = null;
|
|
193
|
+
|
|
194
|
+
const broadcast = (msg) => {
|
|
195
|
+
const line = JSON.stringify(msg) + '\n';
|
|
196
|
+
for (const c of clients) {
|
|
197
|
+
try { c.write(line); } catch { /* closing */ }
|
|
198
|
+
}
|
|
199
|
+
};
|
|
200
|
+
|
|
201
|
+
const scheduleIdleCheck = () => {
|
|
202
|
+
clearTimeout(idleTimer);
|
|
203
|
+
idleTimer = null;
|
|
204
|
+
if (clients.size > 0 || sessions.size > 0) return;
|
|
205
|
+
idleTimer = setTimeout(() => {
|
|
206
|
+
if (clients.size === 0 && sessions.size === 0) {
|
|
207
|
+
log('idle, exiting');
|
|
208
|
+
process.exit(0);
|
|
209
|
+
}
|
|
210
|
+
}, IDLE_EXIT_MS);
|
|
211
|
+
};
|
|
212
|
+
|
|
213
|
+
const describe = (id, s) => ({
|
|
214
|
+
id,
|
|
215
|
+
kind: s.kind,
|
|
216
|
+
pid: s.pid,
|
|
217
|
+
meta: s.meta,
|
|
218
|
+
output: s.ring.snapshot(),
|
|
219
|
+
...(s.exited ? { exited: true, exitCode: s.exitCode, signal: s.signal } : {}),
|
|
220
|
+
});
|
|
221
|
+
|
|
222
|
+
const killSession = (s, signal) => {
|
|
223
|
+
if (s.exited) return;
|
|
224
|
+
if (s.kind === 'pty') {
|
|
225
|
+
try { s.pty.kill(signal); } catch { /* gone */ }
|
|
226
|
+
return;
|
|
227
|
+
}
|
|
228
|
+
// Pipe children run in their own process group (detached), so take the
|
|
229
|
+
// whole group — a `--login -c` shell's grandchildren included.
|
|
230
|
+
try {
|
|
231
|
+
if (process.platform === 'win32') throw new Error('no process groups');
|
|
232
|
+
process.kill(-s.pid, signal || 'SIGTERM');
|
|
233
|
+
} catch {
|
|
234
|
+
try { s.child.kill(signal || 'SIGTERM'); } catch { /* gone */ }
|
|
235
|
+
}
|
|
236
|
+
};
|
|
237
|
+
|
|
238
|
+
/** Record the exit once, and tell whoever is connected. */
|
|
239
|
+
const finish = (id, entry, exitCode, signal) => {
|
|
240
|
+
if (entry.exited) return;
|
|
241
|
+
entry.exited = true;
|
|
242
|
+
entry.exitCode = exitCode;
|
|
243
|
+
entry.signal = signal;
|
|
244
|
+
// Kept until a server acks it: if none is connected right now, the next
|
|
245
|
+
// one learns the exit code from `hello` and persists it.
|
|
246
|
+
broadcast({ ev: 'exit', id, exitCode, signal });
|
|
247
|
+
};
|
|
248
|
+
|
|
249
|
+
const spawnPty = (msg) => {
|
|
250
|
+
const p = pty.spawn(msg.file, msg.args, {
|
|
251
|
+
name: 'xterm-256color',
|
|
252
|
+
cols: msg.cols || 120,
|
|
253
|
+
rows: msg.rows || 30,
|
|
254
|
+
cwd: msg.cwd,
|
|
255
|
+
env: msg.env,
|
|
256
|
+
});
|
|
257
|
+
const entry = { kind: 'pty', pty: p, pid: p.pid, meta: msg.meta ?? null, ring: new Ring(), exited: false };
|
|
258
|
+
p.onData((data) => {
|
|
259
|
+
entry.ring.append(data);
|
|
260
|
+
broadcast({ ev: 'data', id: msg.id, data });
|
|
261
|
+
});
|
|
262
|
+
p.onExit(({ exitCode, signal }) => finish(msg.id, entry, exitCode, signal));
|
|
263
|
+
return entry;
|
|
264
|
+
};
|
|
265
|
+
|
|
266
|
+
const spawnPipe = (msg) => {
|
|
267
|
+
const child = spawn(msg.file, msg.args, {
|
|
268
|
+
cwd: msg.cwd,
|
|
269
|
+
env: msg.env,
|
|
270
|
+
stdio: ['pipe', 'pipe', 'pipe'],
|
|
271
|
+
// Own process group: Ctrl-C from the bubble signals the group.
|
|
272
|
+
detached: true,
|
|
273
|
+
windowsHide: true,
|
|
274
|
+
});
|
|
275
|
+
if (!child.pid) {
|
|
276
|
+
// Launch failures (ENOENT, bad cwd) report through a later 'error'.
|
|
277
|
+
child.on('error', () => {});
|
|
278
|
+
throw new Error('Failed to spawn process');
|
|
279
|
+
}
|
|
280
|
+
const entry = { kind: 'pipe', child, pid: child.pid, meta: msg.meta ?? null, ring: new Ring(), exited: false };
|
|
281
|
+
const onData = (stream) => (buf) => {
|
|
282
|
+
const data = buf.toString();
|
|
283
|
+
entry.ring.append(data);
|
|
284
|
+
broadcast({ ev: 'data', id: msg.id, data, stream });
|
|
285
|
+
};
|
|
286
|
+
child.stdout.on('data', onData('stdout'));
|
|
287
|
+
child.stderr.on('data', onData('stderr'));
|
|
288
|
+
// Writing after the child closed its stdin raises EPIPE here, not at the caller.
|
|
289
|
+
child.stdin.on('error', () => {});
|
|
290
|
+
child.on('close', (code, signal) => finish(msg.id, entry, code, signal));
|
|
291
|
+
child.on('error', () => finish(msg.id, entry, 1, null));
|
|
292
|
+
return entry;
|
|
293
|
+
};
|
|
294
|
+
|
|
295
|
+
const handle = (sock, msg) => {
|
|
296
|
+
const reply = (m) => { try { sock.write(JSON.stringify(m) + '\n'); } catch { /* gone */ } };
|
|
297
|
+
const s = msg.id !== undefined ? sessions.get(msg.id) : undefined;
|
|
298
|
+
switch (msg.op) {
|
|
299
|
+
case 'hello':
|
|
300
|
+
reply({ ev: 'hello', proto: PROTOCOL, build: BUILD, pid: process.pid, sessions: [...sessions].map(([id, x]) => describe(id, x)) });
|
|
301
|
+
return;
|
|
302
|
+
case 'spawn': {
|
|
303
|
+
if (sessions.has(msg.id)) {
|
|
304
|
+
// A rerun reuses the command id. The previous run must have exited
|
|
305
|
+
// (the UI only reruns finished bubbles); if it somehow has not, the
|
|
306
|
+
// new session replaces it and the old one is killed, so the two can
|
|
307
|
+
// never interleave output under one id.
|
|
308
|
+
killSession(sessions.get(msg.id));
|
|
309
|
+
sessions.delete(msg.id);
|
|
310
|
+
}
|
|
311
|
+
let entry;
|
|
312
|
+
try {
|
|
313
|
+
entry = msg.kind === 'pipe' ? spawnPipe(msg) : spawnPty(msg);
|
|
314
|
+
} catch (e) {
|
|
315
|
+
reply({ ev: 'spawnError', id: msg.id, error: e.message });
|
|
316
|
+
return;
|
|
317
|
+
}
|
|
318
|
+
sessions.set(msg.id, entry);
|
|
319
|
+
log(`spawn id=${msg.id} kind=${entry.kind} pid=${entry.pid} file=${msg.file}`);
|
|
320
|
+
reply({ ev: 'spawned', id: msg.id, pid: entry.pid });
|
|
321
|
+
clearTimeout(idleTimer);
|
|
322
|
+
return;
|
|
323
|
+
}
|
|
324
|
+
case 'write':
|
|
325
|
+
if (!s || s.exited) return;
|
|
326
|
+
try {
|
|
327
|
+
if (s.kind === 'pty') s.pty.write(msg.data);
|
|
328
|
+
else if (s.child.stdin.writable) s.child.stdin.write(msg.data);
|
|
329
|
+
} catch { /* exited */ }
|
|
330
|
+
return;
|
|
331
|
+
case 'eof':
|
|
332
|
+
if (s && !s.exited && s.kind === 'pipe') { try { s.child.stdin.end(); } catch { /* closed */ } }
|
|
333
|
+
return;
|
|
334
|
+
case 'resize':
|
|
335
|
+
if (s && !s.exited && s.kind === 'pty') { try { s.pty.resize(msg.cols, msg.rows); } catch { /* exited */ } }
|
|
336
|
+
return;
|
|
337
|
+
case 'kill':
|
|
338
|
+
if (s) killSession(s, msg.signal);
|
|
339
|
+
return;
|
|
340
|
+
case 'ack':
|
|
341
|
+
if (s?.exited) {
|
|
342
|
+
sessions.delete(msg.id);
|
|
343
|
+
scheduleIdleCheck();
|
|
344
|
+
}
|
|
345
|
+
return;
|
|
346
|
+
case 'shutdown':
|
|
347
|
+
log(`shutdown requested, killing ${sessions.size} session(s)`);
|
|
348
|
+
for (const x of sessions.values()) killSession(x);
|
|
349
|
+
// Give the SIGHUPs a moment to land before our own exit.
|
|
350
|
+
setTimeout(() => process.exit(0), 300);
|
|
351
|
+
return;
|
|
352
|
+
}
|
|
353
|
+
};
|
|
354
|
+
|
|
355
|
+
const server = createServer((sock) => {
|
|
356
|
+
clients.add(sock);
|
|
357
|
+
clearTimeout(idleTimer);
|
|
358
|
+
sock.setEncoding('utf8');
|
|
359
|
+
let buf = '';
|
|
360
|
+
sock.on('data', (chunk) => {
|
|
361
|
+
buf += chunk;
|
|
362
|
+
let nl;
|
|
363
|
+
while ((nl = buf.indexOf('\n')) !== -1) {
|
|
364
|
+
const line = buf.slice(0, nl);
|
|
365
|
+
buf = buf.slice(nl + 1);
|
|
366
|
+
if (!line) continue;
|
|
367
|
+
let msg;
|
|
368
|
+
try { msg = JSON.parse(line); } catch { continue; }
|
|
369
|
+
handle(sock, msg);
|
|
370
|
+
}
|
|
371
|
+
});
|
|
372
|
+
const drop = () => {
|
|
373
|
+
if (!clients.delete(sock)) return;
|
|
374
|
+
scheduleIdleCheck();
|
|
375
|
+
};
|
|
376
|
+
sock.on('close', drop);
|
|
377
|
+
sock.on('error', drop);
|
|
378
|
+
});
|
|
379
|
+
|
|
380
|
+
// Exactly one host per socket. A live one answers a connect; a stale socket
|
|
381
|
+
// file left by a crashed host does not, and is removed before we listen.
|
|
382
|
+
if (process.platform !== 'win32' && existsSync(socketPath)) {
|
|
383
|
+
const alive = await new Promise((resolve) => {
|
|
384
|
+
const probe = connect(socketPath);
|
|
385
|
+
probe.once('connect', () => { probe.destroy(); resolve(true); });
|
|
386
|
+
probe.once('error', () => resolve(false));
|
|
387
|
+
});
|
|
388
|
+
if (alive) {
|
|
389
|
+
log('another host already owns the socket, exiting');
|
|
390
|
+
process.exit(0);
|
|
391
|
+
}
|
|
392
|
+
try { unlinkSync(socketPath); } catch { /* raced with its owner */ }
|
|
393
|
+
}
|
|
394
|
+
|
|
395
|
+
server.on('error', (e) => {
|
|
396
|
+
log(`listen failed: ${e.message}`);
|
|
397
|
+
process.exit(1);
|
|
398
|
+
});
|
|
399
|
+
let listening = false;
|
|
400
|
+
server.listen(socketPath, () => {
|
|
401
|
+
listening = true;
|
|
402
|
+
log(`listening on ${socketPath} (build ${BUILD})`);
|
|
403
|
+
scheduleIdleCheck();
|
|
404
|
+
});
|
|
405
|
+
|
|
406
|
+
// Detached, so these only arrive when someone targets us on purpose. SIGHUP
|
|
407
|
+
// is the exception worth ignoring: nothing we own should hang up with a
|
|
408
|
+
// terminal we were never attached to.
|
|
409
|
+
process.on('SIGHUP', () => {});
|
|
410
|
+
process.on('uncaughtException', (e) => log(`uncaughtException: ${e?.stack || e}`));
|
|
411
|
+
process.on('exit', () => {
|
|
412
|
+
// Only a host that actually bound the socket may remove it — one that lost
|
|
413
|
+
// the race above would otherwise delete the winner's.
|
|
414
|
+
if (listening && process.platform !== 'win32') { try { unlinkSync(socketPath); } catch { /* gone */ } }
|
|
415
|
+
});
|
|
416
|
+
}
|
|
417
|
+
|
|
418
|
+
if (process.argv.includes('--launch')) launch();
|
|
419
|
+
else if (process.argv.includes('--serve')) await serve();
|
|
420
|
+
else {
|
|
421
|
+
console.error('pty-host: pass --launch or --serve');
|
|
422
|
+
process.exit(2);
|
|
423
|
+
}
|