Skip to content

Commit

Permalink
'u' should undo atomic. Fixes #24
Browse files Browse the repository at this point in the history
  • Loading branch information
nosami committed May 3, 2017
1 parent 74deefb commit 4f5e09f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 5 additions & 1 deletion XSVim.Tests/MiscTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,8 @@ module ``Miscellaneous tests`` =

[<Test>]
let ``'I' should insert at first non whitespace``() =
assertText " abcdef$" "I" " |abcdef"
assertText " abcdef$" "I" " |abcdef"

[<Test>]
let ``Undo repeat``() =
assertText "a$bc def ghi" "3dwu" "a$bc def ghi"
2 changes: 2 additions & 0 deletions XSVim/XSVim.fs
Original file line number Diff line number Diff line change
Expand Up @@ -545,6 +545,8 @@ module Vim =
match command.repeat with
| Some r -> r
| None -> 1

use _group = editor.OpenUndoGroup()
processCommands count vimState

let (|Digit|_|) character =
Expand Down

0 comments on commit 4f5e09f

Please sign in to comment.