diff --git a/archon-ui-main/src/features/mcp/components/McpConfigSection.tsx b/archon-ui-main/src/features/mcp/components/McpConfigSection.tsx index 3a9a11fe..3f011f9d 100644 --- a/archon-ui-main/src/features/mcp/components/McpConfigSection.tsx +++ b/archon-ui-main/src/features/mcp/components/McpConfigSection.tsx @@ -19,6 +19,7 @@ const ideConfigurations: Record< steps: string[]; configGenerator: (config: McpServerConfig) => string; supportsOneClick?: boolean; + platformSpecific?: boolean; } > = { claudecode: { @@ -56,6 +57,42 @@ const ideConfigurations: Record< 2, ), }, + codex: { + title: "Codex Configuration", + steps: [ + "Step 1: Install mcp-remote globally: npm install -g mcp-remote", + "Step 2: Add configuration to ~/.codex/config.toml", + "Step 3: Find your exact mcp-remote path by running: npm root -g", + "Step 4: Replace the path in the configuration with your actual path + /mcp-remote/dist/proxy.js", + ], + configGenerator: (config) => { + const isWindows = navigator.platform.toLowerCase().includes("win"); + + if (isWindows) { + return `[mcp_servers.archon] +command = 'node' +args = [ + 'C:/Users/YOUR_USERNAME/AppData/Roaming/npm/node_modules/mcp-remote/dist/proxy.js', + 'http://${config.host}:${config.port}/mcp' +] +env = { + APPDATA = 'C:\\Users\\YOUR_USERNAME\\AppData\\Roaming', + LOCALAPPDATA = 'C:\\Users\\YOUR_USERNAME\\AppData\\Local', + SystemRoot = 'C:\\WINDOWS', + COMSPEC = 'C:\\WINDOWS\\system32\\cmd.exe' +}`; + } else { + return `[mcp_servers.archon] +command = 'node' +args = [ + '/usr/local/lib/node_modules/mcp-remote/dist/proxy.js', + 'http://${config.host}:${config.port}/mcp' +] +env = { }`; + } + }, + platformSpecific: true, + }, cursor: { title: "Cursor Configuration", steps: [ @@ -144,27 +181,6 @@ const ideConfigurations: Record< 2, ), }, - augment: { - title: "Augment Configuration", - steps: [ - "Open Augment settings", - "Navigate to Extensions > MCP", - "Add the configuration shown below", - "Reload configuration", - ], - configGenerator: (config) => - JSON.stringify( - { - mcpServers: { - archon: { - url: `http://${config.host}:${config.port}/mcp`, - }, - }, - }, - null, - 2, - ), - }, }; export const McpConfigSection: React.FC = ({ config, status, className }) => { @@ -240,14 +256,14 @@ export const McpConfigSection: React.FC = ({ config, stat value={selectedIDE} onValueChange={(value) => setSelectedIDE(value as SupportedIDE)} > - + Claude Code Gemini + Codex Cursor Windsurf Cline Kiro - Augment @@ -255,10 +271,32 @@ export const McpConfigSection: React.FC = ({ config, stat

{selectedConfig.title}

    - {selectedConfig.steps.map((step) => ( -
  1. {step}
  2. - ))} + {selectedConfig.steps.map((step) => { + // Highlight npm install command for Codex + if (selectedIDE === "codex" && step.includes("npm install -g mcp-remote")) { + const parts = step.split("npm install -g mcp-remote"); + return ( +
  3. + {parts[0]} + + npm install -g mcp-remote + + {parts[1]} +
  4. + ); + } + return
  5. {step}
  6. ; + })}
+ {/* macOS note for Codex */} + {selectedIDE === "codex" && ( +

+ Note: On macOS with Homebrew on Apple Silicon, the path might be{" "} + + /opt/homebrew/lib/node_modules/mcp-remote/dist/proxy.js + +

+ )}
{/* Special Commands for Claude Code */} @@ -280,10 +318,28 @@ export const McpConfigSection: React.FC = ({ config, stat )} + {/* Platform-specific note for Codex */} + {selectedIDE === "codex" && ( +
+

+ Platform Note: The configuration below shows{" "} + {navigator.platform.toLowerCase().includes("win") ? "Windows" : "Linux/macOS"} format. Adjust paths + according to your system. This setup is complex right now because Codex has some bugs with MCP currently. +

+
+ )} + {/* Configuration Display */}
- Configuration + + Configuration + {selectedIDE === "codex" && ( + + ({navigator.platform.toLowerCase().includes("win") ? "Windows" : "Linux/macOS"}) + + )} +