Still a work in progress, but I've published the first draft of a new chapter on "Using Git with coding agents" https://simonwillison.net/guides/agentic-engineering-patterns/using-git-with-coding-agents/
Using Git with coding agents - Agentic Engineering Patterns

Using Git with coding agents - Agentic Engineering Patterns

Simon Willison’s Weblog
@simon are git worktrees often used with agents? I find myself using the main working directory and an OpenCode instance messing around with a separate worktree

@simon I much prefer #Jujutsu #jjvcs to Git. I feel the flow is nicer: the working copy is always « on » a commit so running jj edit / jj new snapshots (commits) then moves.

I’ve had relative success with agents with light instructions. YMMV, N=1, yada.

@simon Brilliant! And thanks as always for the contribution you're making to everyone through all the talks, writing, etc.
@simon we could also add conventional commits as standard directive