git workflow for the terminal

Solve big problems
one piece at a time

One piece of work. One worktree. One PR. mp stacks the pieces, opens the PRs, and cleans up after the merge. Hooks fire at every step.

$ brew install jewell-lgtm/tap/monkeypuzzle
See how it works
monkeypuzzle
~/acme mp create --name auth-schema✓ Created piece: auth-schema at ~/acme/.monkeypuzzle/pieces/auth-schema→ next: mp pr create --draft ~/acme mp pr create --draftPushing branch auth-schema to origin...Creating PR...✓ Created PR #481: https://github.com/you/acme/pull/481 # review, mark ready, merge #481 on GitHub ~/acme mp done✓ Done with piece: auth-schema
Why pieces

Big features, small reviews.

A worktree per piece

Every piece is a branch checked out in its own directory. Switch tasks without stashing, and nothing half-done gets in the way.

Stacks, not mega-PRs

Break a feature into a chain of small pieces, each built on the one below. Each PR reviews in minutes.

Restack on autopilot

Change a piece low in the stack and mp stack sync carries it up through every piece above. A conflict stops the sync and tells you where.

One command to submit

mp pr create pushes the piece and opens its PR against the piece below, so each PR holds one change.

Hooks at every transition

Scripts in .monkeypuzzle/hooks/ run on create, update, PR and merge. Install dependencies for a new piece, run the tests before a PR opens.

Native to GitHub & GitLab

Pull requests on GitHub, merge requests on GitLab, through gh and glab. Your checks and reviews stay where they are.

Three moves

Cut. Stack. Ship.

1

Cut

Start a piece: a new branch in its own worktree, one idea at a time.

mp create --name auth-schema
2

Stack

Build the next piece on top. Changed something below? Sync the tree in one go.

mp stack append auth-apimp stack sync
3

Ship

Open a PR per piece, merge from the bottom up, and clear away the worktree.

mp pr createmp mergemp done

Fits your setup your editor via mp open your shell via mp shell-init tmux or herdr coding agents Integrations →

the CLI is free & open source

Ship in small pieces.

Start with the free CLI today — the install command is at the top of the page. Leave your email to follow what ships next.

Star on GitHub