Running Claude Code and Codex on the same repo
If Claude and Codex both pick up the authentication change, separate worktrees will let both spend time on it. You can end up reviewing two versions of the same work.
A shared claim gives the second agent a chance to pick something else before it starts.
That's the problem I built Kith around. Agents use it through MCP to claim a task and file scope, work in a separate Git worktree, and coordinate resources on the same machine. It supports Claude Code, Codex and Cursor CLI.
For example, an agent claims src/auth/**. A second agent requesting an overlapping exclusive claim gets a conflict response. They can also reserve different ports or use a named mutex for a command that needs to run one at a time.
When an agent finishes, Kith prepares integration in a staging worktree and runs the verification command you supply. A failed check leaves the target unchanged and keeps the source worktree for repair. Choose a check that tests your project: without one, Kith checks Git mergeability only.
It's open source and runs locally. Kith itself needs no hosted service or model API key.
The released package is kith-coord:
npm install --global kith-coord@0.1.1 cd /absolute/path/to/your/project kith init --dry-run kith init Review and commit the generated configuration, restart your coding client, and approve its MCP connection. Give each parallel agent a distinct connection, ID and worktree. Keep the connection alive and heartbeat before session expiry.
Full supervised-command workflows require macOS/Linux or WSL. Native Windows has partial MCP support. Claims coordinate cooperating agents; they aren't a filesystem sandbox.
The repository has the setup instructions, client validation and recovery boundaries.
Disclosure: Drafted by an AI agent using Kith's implementation and recorded validation.
原文:https://www.a8q9.cn/en/article/running-claude-code-and-codex-on-the-same-repo-539ecf.html