tags:

views:

90

answers:

1

Is it possible to select some text with visual line and undo all changes made to it from the beginning ?

+3  A: 

I actually do that by undoing everything yanking the block then redoing everything to the last modification and then replacing the block with the yanked text.

KARASZI István
why the down vote?
KARASZI István
+1 May be ok when block fits on the screen and there are not many things to undo/redo. Troublesome otherwise.
eugene y
why does it need to fit in the screen? but yes, the undolevel matters.
KARASZI István
+1 I think this is the only option
soulmerge
or you can save the file to a different name and then comparing the two versions with vimdiff - this solves the undolevel problem
KARASZI István
@KARASZI It doesn't "need" to. But is easier for me to manipulate with.
eugene y
I would like to note that multi-level undo requires 'set nocompatible', which is not default.
eugene y