Orchestrate parallel AI agents in isolated git worktrees.
Flock is a CLI tool designed to streamline multi-agent development workflows. It spins up containerized, branch-native execution environments using Docker and Git Worktreesβallowing AI agents to build, test, and commit code concurrently without polluting your local workspace or colliding with each other.
You can quickly install Flock using the official installation script:
curl -fsSL https://juancsucoder.github.io/flock/install_flock.sh | bash
feature/agent-<name>). This keeps all agent changes isolated on disk so you can easily review, test, and merge them into your main branch..gitignore updates automatically to keep temporary worktrees and session state files out of your source control.To spin up an isolated containerized session for an agent, simply pass your desired session or task name to flock:
flock test1
β― flock test1
Line added to gitignore.
Line added to gitignore.
Preparing worktree (new branch 'feature/agent-test1')
HEAD is now at e0101ca Fix: Permissions
β
ββββ ββββ ββββ ββββ ββββ ββββ ββββ ββββ
β β β β ββββ β β β β β β β ββββ
ββββ ββββ ββββ ββββ ββββ ββββ ββββ ββββ
Session Worktree task with commit guidelines
Continue opencode -s ses_03b1c817affeMmzJicE4qcQs8B
flock updates .gitignore and creates a local Git worktree for the requested session (feature/agent-<session_name>).Distributed under the MIT License. See LICENSE for details.