The Best Git Worktree Tool I've Used (Worktrunk)

7:142 min readBetter Stack10/31/2026Computing/Software

Key Takeaway

WorkTrunk streamlines multi-agent development workflows by replacing complex multi-step Git commands with single-line operations like wt switch and wt merge.

Highlights

  • WorkTrunk is a terminal-native Rust CLI tool designed to manage Git work trees for running multiple AI coding agents in parallel.

  • Using copy-on-write file cloning via APFS on Mac, WorkTrunk copies a 14-gigabyte Rust build folder in about 20 seconds with virtually zero extra disk space.

  • The command wt merge combines six standard Git commands into one by committing, squashing, rebasing onto main, fast-forwarding, and deleting the work tree.

  • A built-in port filter assigns unique development server ports to each work tree to prevent multiple agents from colliding over port 3000.

  • WorkTrunk is currently at version 0.81, with the word breaking appearing over 80 times in its change log.

Timeline

  1. The Problem with Native Git Work Trees and AI Agents

    Running multiple coding agents simultaneously on the same repository leads to conflicts because agents overwrite shared files. Git work trees solve this by creating isolated checkouts of the repository in separate folders. However, native Git and built-in tool work trees leave out crucial lifecycle management commands like merging and centralized status tracking.

    • Running multiple AI agents on a single repository folder causes conflicting writes and failing tests.
    • Plain Git requires typing branch names multiple times for creation and cleanup while only outputting raw folder paths.
    • Native Claude Code work trees handle creation but lack commands for merging work back and lack a unified overview of active agent tasks.
  2. Core WorkTrunk Commands and Parallel Agent Workflow

    WorkTrunk allows developers to spin up multiple isolated agent environments using simple single-line commands. The status dashboard uses visual indicators to show whether an agent is actively working or waiting for user input. Once an agent finishes its task, a single merge command consolidates the changes and cleans up the work tree automatically.

    • The command wt switch creates and enters a work tree branch and folder in a single line.
    • The command wt list provides a single dashboard showing every work tree, its branch, its distance ahead of main, and active agent states.
    • The command wt merge automates committing, squashing, rebasing, fast-forwarding, and work tree deletion.
  3. Under the Hood: Shell Integration, Plugins, and Copy-on-Write

    Because standard programs cannot change terminal directories independently, WorkTrunk requires a quick shell configuration step during installation. To solve the cold-start problem where new work trees lack ignored files like build caches and node modules, WorkTrunk leverages file system copy-on-write capabilities. This makes environment duplication nearly instant and space-efficient until files are modified.

    • WorkTrunk installs a tiny shell function to handle directory changes since programs cannot modify terminal directories directly.
    • The tool integrates with multiple agent CLIs including Claude Code, Codex, OpenCode, and Gemini CLI.
    • Copy-on-write cloning on Mac APFS drives reduces heavy folder duplication time from minutes to seconds without consuming extra disk space.
  4. Alternative Comparison, Limitations, and Recommendations

    While WorkTrunk offers powerful terminal-native automation for multi-agent workflows, developers running only a single agent do not need it. Furthermore, users must review project hook commands carefully before execution and expect regular configuration adjustments due to the pre-1.0 development status.

    • WorkTrunk sits between minimalist native tool implementations and full GUI Kanban boards like Vibe Kanban.
    • The software is pre-1.0 (version 0.81) and features frequent breaking changes in its change logs.
    • Standard Linux ext4 file systems fall back to full folder copies rather than instant copy-on-write cloning.

Description

Claude Code already has built-in Git worktrees, so why are developers using Worktrunk? In this video, I test Worktrunk, an open-source Rust CLI that makes it easier to manage Git worktrees and run multiple AI coding agents in parallel without stepping on each other's code. I'll show you how to run three Claude Code agents on separate branches of the same repository, monitor their progress with wt list, switch between worktrees instantly, and merge finished changes back into main with a single wt merge command. 🔗 Relevant Links Worktrunk Repo - https://github.com/max-sixty/worktrunk Worktrunk Docs - https://worktrunk.dev/ ❤️ More about us Radically better observability stack: https://betterstack.com/ Written tutorials: https://betterstack.com/community/ Example projects: https://github.com/BetterStackHQ 📱 Socials Twitter: https://twitter.com/betterstackhq Instagram: https://www.instagram.com/betterstackhq/ TikTok: https://www.tiktok.com/@betterstack LinkedIn: https://www.linkedin.com/company/betterstack 📌 Chapters: 00:00 Why Claude Code's Built-In Worktrees Aren't Enough 00:30 The Problem With Running Multiple AI Coding Agents 00:46 Git Worktrees Explained 01:26 Running 3 Claude Code Agents in Parallel With Worktrunk 02:23 Monitor AI Agents With wt list 02:45 Switch Between Git Worktrees Instantly 02:58 Merge Agent Changes With One Command 04:00 Claude Code, Codex & OpenCode Integrations 04:31 Speed Up Git Worktrees With Copy-on-Write 05:31 Worktrunk vs Claude Code, Vibe Kanban & Dagger 06:10 Worktrunk Limitations & Real Downsides 06:45 Is Worktrunk Worth Using?

Write about this video