History

Workflow

Every successful refactoring operation — rename, extract, move, inline — creates a checkpoint automatically. Use history to inspect and reverse those changes without re-reading files or diffing manually.

  1. Apply one or more refactor operations. Each creates a checkpoint.
  2. Call history_list to review what has been applied and confirm the result is correct.
  3. If a refactoring produced an unexpected result, call history_undo to revert it. The revert is itself safe — it can be re-done.
  4. Call history_redo to re-apply an undone operation if you change your mind.

History is session-scoped. Checkpoints are cleared when the act server restarts. Do not rely on history across sessions — commit or stash changes you want to keep.

Operations

OperationDescriptionParameters
history_listList recent operation checkpoints. Every refactoring tool (rename, extract, move, inline) creates a checkpoint that can be undone. Params: none [, limit (u32)]none [, limit (u32)]
history_redoRedo the last N undone refactoring operations (default: 1). Re-applies previously undone changes. Params: none [, count (u32), preview (bool)]none [, count (u32), preview (bool)]
history_undoUndo the last N refactoring operations (default: 1). Reverts all file changes from each operation. Safe to use — can be re-done. Params: none [, count (u32), preview (bool)]none [, count (u32), preview (bool)]