fix: 修复 Windows MCP 配置 npx 命令重复问题 (v1.7.23)

- 移除 applyPlatformCommand 中重复追加的 originalCommand
- getMcpCommand 已返回完整命令,无需再追加
This commit is contained in:
li committed 2026-01-13 21:14:40 +08:00
1 parent 88286dcaa5
commit 30276e8a1b
2 files changed
+3 -4

No files matched your search

+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "ccg-workflow",
"version": "1.7.22",
"version": "1.7.23",
"description": "Claude-Codex-Gemini 多模型协作系统 - 智能路由多模型开发工作流",
"type": "module",
"packageManager": "pnpm@10.17.1",
+2 -3
View File
@@ -91,11 +91,10 @@ export function applyPlatformCommand(config: McpServerConfig): void {
// Only modify if command needs Windows wrapper (cmd /c)
if (mcpCmd[0] === 'cmd') {
const originalCommand = config.command
const originalArgs = config.args || []
config.command = mcpCmd[0] // 'cmd'
config.args = [...mcpCmd.slice(1), originalCommand, ...originalArgs] // ['/c', 'npx', ...originalArgs]
// getMcpCommand 已返回 ['cmd', '/c', 'npx'],slice(1) = ['/c', 'npx']
config.args = [...mcpCmd.slice(1), ...originalArgs]
}
}
}