(cwd, fn)
| 642 | } |
| 643 | |
| 644 | async function withDirectAppServer(cwd, fn) { |
| 645 | const client = await CodexAppServerClient.connect(cwd, { disableBroker: true }); |
| 646 | try { |
| 647 | return await fn(client); |
| 648 | } finally { |
| 649 | await client.close(); |
| 650 | } |
| 651 | } |
| 652 | |
| 653 | function resolveCodexHome() { |
| 654 | return path.resolve(process.env.CODEX_HOME || path.join(os.homedir(), ".codex")); |
no test coverage detected