How-toProjects and shipping

Choose where a chat works

Let each chat work in its own git worktree, start it from another branch, or have it edit your files directly.

All pages

You'll choose whether a chat works in its own copy or in your files. About 1 minute.

By default a chat in a mode that can change files gets its own git worktree and new branch with its first message.

For one chat

  1. Select the branch chip under the message box.
  2. Pick New branch from branch, a branch under Or continue a branch, Work on a pull request… or Edit my files directly instead.

Hovering the chip shows where the branch started.

Work on a pull request

Work on a pull request…, in the chip or Work panel, adopts one (only you, on the Mac).

  • The agent pushes there without force, merges to update and handles feedback.
  • A fork needs maintainer edits allowed. Otherwise, or for a protected branch, the chat gets a spark/ branch from it.
  • A chat with its own branch switches in its worktree; commit first. Work on it here in Links and Start chat adopt too.

For every chat in a project

  1. In Settings → Projects, select the project.
  2. Under Where Spark works, pick Each chat in its own worktree (recommended) or In my files.

What to expect

Choice Where changes land To get them into your checkout
Worktree On the chat's own spark/ branch Bring changes into branch, or open a pull request
My files Your checkout Nothing to do

A new worktree starts from the latest origin default branch. Picking main starts a new branch from its latest code; another picked branch catches up with its remote first.

If its lockfile differs from your checkout's, Spark installs dependencies, saying if that fails.

Archiving, deleting or merging a chat removes its worktree, unless it holds an ignored file like .env or a tab or server runs there.