Skip to content

Commit

Permalink
Save an undo checkpoint before paste in insert mode (#8121)
Browse files Browse the repository at this point in the history
  • Loading branch information
the-mikedavis authored Nov 20, 2024
1 parent 239262e commit 59b020e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions helix-term/src/commands.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4339,6 +4339,10 @@ fn paste_impl(
return;
}

if mode == Mode::Insert {
doc.append_changes_to_history(view);
}

let repeat = std::iter::repeat(
// `values` is asserted to have at least one entry above.
values
Expand Down

0 comments on commit 59b020e

Please sign in to comment.