@cg3/equip 0.2.1 → 0.2.2

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.
Files changed (2) hide show
  1. package/lib/mcp.js +5 -3
  2. package/package.json +1 -1
package/lib/mcp.js CHANGED
@@ -319,11 +319,13 @@ function installMcp(platform, serverName, mcpEntry, options = {}) {
319
319
  } catch { /* fall through */ }
320
320
  }
321
321
 
322
- // Codex: try CLI first (codex mcp add <name> <url>)
323
- if (platform.platform === "codex" && platform.hasCli && mcpEntry.url) {
322
+ // Codex: skip CLI for HTTP (codex mcp add treats URLs as stdio commands).
323
+ // Use CLI only for stdio transport where the command syntax is unambiguous.
324
+ if (platform.platform === "codex" && platform.hasCli && mcpEntry.command) {
324
325
  try {
326
+ const cliArgs = [serverName, "--", mcpEntry.command, ...(mcpEntry.args || [])].join(" ");
325
327
  if (!dryRun) {
326
- execSync(`codex mcp add ${serverName} ${mcpEntry.url}`, {
328
+ execSync(`codex mcp add ${cliArgs}`, {
327
329
  encoding: "utf-8", timeout: 15000, stdio: "pipe",
328
330
  });
329
331
  const check = readMcpEntry(platform.configPath, platform.rootKey, serverName, "toml");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cg3/equip",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "Universal MCP + behavioral rules installer for AI coding agents",
5
5
  "main": "index.js",
6
6
  "bin": {