undo_write
Revert a journaled write to restore touched files to their exact pre-write state, including moves, renames, and permanent deletes. Defaults to last journal entry; force restores despite later changes.
Instructions
Revert a journaled write: restores every file it touched to its byte-identical pre-write state (a multi-file move or heading rename is restored whole; a delete is restored even if it was permanent). Defaults to the most recent undoable write. Refuses with undo_conflict if a file changed since that write, unless force: true. The undo is itself journaled — undo it to redo.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| seq | No | Journal entry to revert (from list_writes). Defaults to the most recent undoable write. | |
| force | No | Restore even if a file changed after the journaled write; the clobbered state is journaled first so nothing is lost. Defaults to false. |