Devlog · September 2026
Port42 hooks into Claude Code and Codex in completely different ways, and neither one touches your own setup
Port42 v1 has no model of its own. Your Claude Code or Codex is the companion, and Port42 just needs to hear when it starts and stops.
Claude Code has to be intercepted. A shim stands in for the binary so it can pass --settings, which takes a symlink, a shell function and a PATH prefix.
Codex needs none of that. Point CODEX_HOME at a directory with a config.toml and it reads the hooks itself.
Either way, your own setup comes along. A Port42 Codex keeps your skills, your AGENTS.md and your MCP servers, and never writes to ~/.codex. There's a test for that.
CLIHookProducer.swift
Claude has to be INTERCEPTED ... a symlink, a shell function and a
PATH prefix. Codex needs none of that: point CODEX_HOME at a
directory holding a config.toml and it reads the hooks itself.
@Test("the person's own Codex setup comes along: their skills,
AGENTS.md and MCP servers; ~/.codex is never written")
The code
- The two mechanisms:
CLIHookProducer.swift, one value per CLI rather than a subclass, because the mechanisms differ. - The test:
CLIHookProducerTests, "the person's own Codex setup comes along". - This covers Claude Code and Codex only.