Working in a space
Archiving and deleting
How Astra reclaims a worktree without losing work, what reopening restores, and what deleting actually destroys.
Spaces accumulate. Archiving is how you clear them out without throwing anything away.
Archiving
Archiving parks a space: it leaves the sidebar and moves to the archive (⌘⇧A), along with its diff stats and, if it had a pull request, how that ended — merged, closed, or abandoned.
For a worktree space, archiving also reclaims the checkout from disk. That’s the point of it: worktrees are real directories, and a finished one is dead weight. The reclaim is lossless. Before removing the folder, Astra captures everything uncommitted and untracked to a side reference in the repo, so what survives is:
- the branch, with its commits,
- the full conversation,
- and any work in progress that was never committed.
Seeded files — the .env-style files Astra copied in when provisioning — are deliberately excluded. They’re config Astra owns, not work, and stashing them would write secrets into the object store and restore stale copies over fresh ones later.
Archiving a local space is just bookkeeping. There’s no separate checkout to reclaim, and your project folder is untouched.
Reopening
Reopening a worktree space re-creates the checkout — new worktree, seeds copied, setup command run — and restores the work in progress that was captured on archive. You get back the branch and the uncommitted changes exactly as they were, in a fresh, working copy.
The conversation comes back in full either way. It was never in the worktree; it’s in Astra’s own database.
Deleting
Deleting is permanent, and it means different things for the two kinds of space:
- Worktree space — the branch and anything uncommitted go with it. There’s no undo. If you’re not certain, archive instead: it costs nothing and keeps everything.
- Local space — only the conversation is removed. The files in your project folder stay exactly as they are. Astra never touches your repo root on delete.
Teardown commands
If a project needs something torn down before its worktree disappears — a container stopped, a port released — set a teardown command in the project’s settings. It runs in the worktree just before the folder is removed, on archive or delete. See Project setup.