Origami

Docs › Loops

Loop worktrees

A new loop works in the workspace's checkout, or in a worktree and on a branch of its own.

Where Loop › New loop › Under the message box 1 min read

How it works

  1. In a repository, under a new loop's message box, choose where it works: Current checkout, shown as its folder and branch, or New worktree.
  2. With New worktree, the button beside it, From and a branch, says what the worktree starts from: the checkout's branch, until you pick another. Picking one checks nothing out.
  3. The worktree is made when you send the first message, on a new branch named after that message under loop/. The loop works there from then on.
  4. The loop's line in the sidebar shows the worktree's name, and in the workspace's own checkout its branch, following it when the agent switches it.

Good to know

  • Only a new loop chooses: once its first message is sent, a loop stays where it began.
  • If the worktree cannot be made, nothing is sent, and your next message tries again.
  • Removing the loop asks whether to remove its worktree too, unless another loop works in it. A worktree with uncommitted changes is kept.
  • Loop worktrees are kept outside the project's folder and are listed with the others on the Worktrees page.

Related