- Docs
- Working with agents
- Undo changes
Working with agents
Undo an agent’s changes
Every turn records which files changed. Undo the whole turn in one click, redo it, or discard single changes in the Changes pane.
Before an agent changes files, Codevalanche saves how they were. After the turn you get a record of what changed and a way back.
Turn changes
Each turn that changed files shows a Turn changes card: Turn in progress while it works, then Saved with the number of changed files.
- Choose Undo this turn’s changes.
- Confirm. The files go back to how they were before the agent changed them.
- Changed your mind? Choose Redo.
When undo is not offered
| Reason | Meaning |
|---|---|
| Files not shown on the card | The operation includes files outside this turn’s record. |
| Another turn | The change belongs to a different turn. |
| Incomplete record | The complete earlier state of the files was not captured. |
| Very large folder | A folder too large to snapshot runs without undo; the app tells you. |
If the app closes during a turn, the record is recovered on the next start (“Interrupted turn recovered”).
Fine-grained changes
The Changes pane (Ctrl+2) shows each changed file. You can discard a single change (a hunk) or a whole file. Discarding cannot be undone, so the app asks first.
Projects in git give you a second safety net: every change is also visible in git, and the Coordinator merges agents’ branches only when it is safe.
Disk space
Undo snapshots are kept with the AI tools’ sessions. Settings › Storage shows how much space they use.