core-agent-ide/shell-tool-mcp/src
Michael Bolin ee191dbe81
fix: path resolution bug in npx (#7134)
When running `npx @openai/codex-shell-tool-mcp`, the old code derived
`__dirname` from `process.argv[1]`, which points to npx’s transient
wrapper script in
`~/.npm/_npx/134d0fb7e1a27652/node_modules/.bin/codex-shell-tool-mcp`.
That made `vendorRoot` resolve to `<npx cache>/vendor`, so the startup
checks failed with "Required binary missing" because it looked for
`codex-execve-wrapper` in the wrong place.

By relying on the real module `__dirname` and `path.resolve(__dirname,
"..", "vendor")`, the package now anchors to its installed location
under `node_modules/@openai/codex-shell-tool-mcp/`, so the bundled
binaries are found and npx launches correctly.
2025-12-02 16:37:14 -08:00
..
bashSelection.ts feat: codex-shell-tool-mcp (#7005) 2025-11-21 08:16:36 -08:00
constants.ts feat: codex-shell-tool-mcp (#7005) 2025-11-21 08:16:36 -08:00
index.ts fix: path resolution bug in npx (#7134) 2025-12-02 16:37:14 -08:00
osRelease.ts feat: codex-shell-tool-mcp (#7005) 2025-11-21 08:16:36 -08:00
platform.ts feat: codex-shell-tool-mcp (#7005) 2025-11-21 08:16:36 -08:00
types.ts feat: codex-shell-tool-mcp (#7005) 2025-11-21 08:16:36 -08:00