Your teammate gets a diff and a note: should be fixed now. The code moved. The reasoning did not. The dead ends, the command that finally reproduced the bug, the warning that turned out to matter, the reason one fix won over another, all of that stays locked in a local session that is now closed.
AgentGit is an open source tool built to close that gap. It applies version control ideas to agent sessions so work can be saved at named checkpoints, inspected, shared, branched, and resumed rather than rebuilt from a blank prompt.
Who It Supports
Current integrations include Claude Code, Codex, OpenCode, OpenClaw, Hermes, and WorkBuddy. More are being added. Because session formats differ across environments, the developer recommends verifying what arrived after a move or restore.
️ Basic Handoff Workflow
Install AgentGit and configure integrations:
npx -y create-agitAdopt the existing local agent session, then save a named checkpoint and review the recorded history:
agit import
agit commit
agit logShare the session for review, or run a published branch when the recipient needs to continue working:
agit share
agit run owner/repository@branchBefore sending, add a short handoff note covering the goal, the key failed attempt, what has been verified, and the next logical step. The full session history sits behind that note if the reviewer needs to check the evidence.

Security Check Before You Share
Coding sessions collect things that were never meant to travel. A command output can print an API key. A stack trace can expose a private hostname. A prompt can include customer data or unreleased product details. Generated patches can contain secrets too.
Run an automated credential scan, then read the record yourself. Scanners catch common patterns but miss unusual token formats and confidential business context. If a real credential appears anywhere in the history, rotate it. Deleting the visible line later does not make the credential safe.
Verify the Handoff Actually Worked
A shared link opening successfully proves almost nothing. Before the recipient continues, ask them or the resumed agent to explain five things: the goal, the most important failed attempt, why the current approach was chosen, which checks passed, and what remains unresolved. For a risky change, rerun the decisive test on the receiving machine. Dependencies, permissions, and repository state may differ from the original environment.
AgentGit is free and open source. If you have an agent session you would rather not reconstruct from scratch, that is the right one to test it on first.
