set_undo_barrier
Insert an undo barrier at the current stack position to protect existing work, so later undo steps cannot cross it before a risky batch.
Instructions
Drop a floor in the undo stack at the current position so no later undo can cross it -- the way to protect everything done SO FAR (yours or the human's) before starting a risky batch that you may want to unwind. Idempotent: a barrier already sitting at the cursor is not pushed twice (already_existed:true). Lift it with remove_undo_barrier, or clear_undo_barriers for all of them.
Returns: { success: bool (hardcoded), already_existed: bool (true = nothing new was pushed), undo_barrier: int (cursor it sits at), undo_count: int, queue_length: int }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||