Skip to main content

space

space puts worktrees from several repos in one disposable workspace. Branch them together, send agents to work on the feature, then tear down the workspace without touching the source repos.

Private repo

  • Rust
  • clap + ratatui
  • Developer tooling
fish: compose a working set
$ space ws new checkout api web payments
  set      checkout (created from api, web, payments)
  worktree checkout-workspace-1/api      → branch checkout-workspace-1
  worktree checkout-workspace-1/web      → branch checkout-workspace-1
  worktree checkout-workspace-1/payments → branch checkout-workspace-1

$ space ws ls
  checkout-workspace-1   api web payments   checkout-workspace-1

One ticket across a dozen services

A feature across a dozen services used to need a dozen clones, each with its own branch to keep in step. With space, you name the repos once. It creates a git worktree for each on a shared branch inside one disposable workspace.

Three tiers, one invariant

An area has read-only repo mirrors, sets that name which repos belong together, and workspaces for editing. Each workspace contains worktrees cut from the mirrors, so the clones never diverge. Deleting a workspace leaves the source repos untouched.

~/dev/acme/                      # an AREA — marked by a .space file
├── .space                       # marker + config (where the repos come from)
├── repos/                       # read-only clones — the primitives
│   ├── api/
│   └── web/
├── sets/                        # recipes: a manifest + docs, no code
│   └── checkout/
└── workspaces/                  # git worktrees — the only place you edit
    └── checkout-workspace-1/
        ├── api/                 # worktree of repos/api (nested, gitignored)
        └── web/

Forking a workspace

A second instance of a set uses the mirrors and fresh branches, so two agents can work on the same repos side by side. Copying a worktree aliases its git metadata and corrupts state. The core therefore exposes no copy or move operation.

fish: a parallel instance
$ space ws fork checkout-workspace-1 try-b
  re-instantiated sets/checkout → checkout-workspace-2
  branch try-b on api, web, payments

Grow the task or the recipe

Adding a repo to a workspace changes that instance. Adding it to the set changes the recipe, so new workspaces from that set include the repo. Checks before creation prevent a half-built workspace and report which branch is already in use.

fish: instance vs recipe
$ space ws add checkout-workspace-1 search
  worktree checkout-workspace-1/search → branch checkout-workspace-1

$ space set add checkout search
  recipe sets/checkout now lists search

The cockpit

space serve puts six screens over the same read-model the CLI prints. Attention shows which agents have stopped and are waiting on me, the board shows every workspace grouped by area and set, and the rest cover the journal feed, the task graph and the plans agents submit for approval. It is server-rendered Rust with one stylesheet and no JavaScript framework, and it only listens on localhost unless given a token.

The space dashboard's board: two areas, org-acme and org-labs, each with its repo, set and workspace counts, and a card per workspace showing its set, member repos with their branches, and whether an agent session is running, stalled or parked.

The surface

Commands follow space <noun> <verb>. Completions use your actual areas, repos, sets and workspaces. Areas register themselves, so -A <area> works from any directory. A bare space opens the TUI browser.

Commands

areainit · add · root · ls · info · sync · prune · open · ide · rm
repols · sync · add <url> · open · ide
setnew <name> <repo>… · ls · rm · sync · add <url> · open · ide
wsnew · ls · add · fork · branch · open · ide · rm
rootui · completion <bash|zsh|fish> · bare space → TUI

Build

LanguageRust, with clap for the CLI tree and ratatui for the TUI
Size~7.5k lines
ArchitectureHexagonal architecture: a pure core uses Git / Fs / Proc port traits; the CLI and TUI inject the real adapters
Optional companions
  • tmux: open drops you into a session
  • ghorg: mirrors an org into repos/
  • workmux: finds worktrees for agents
  • VS Code / Cursor: multi-root workspace files
Hard dependencygit, and nothing else

Where it is now

I use space on my own machine every day. The repository is private for now. This is a short account; the design notes cover the port traits, worktree invariants and how the CLI, TUI and dashboard share one core.

More of my work on GitHub