Technology TidBits

Answers to various technical questions on php programming, mysql, linux, and many more categories.



How can I undo and redo changes in vi?

Last updated: 07/30/2010
Add comment
Votes: 0
Comments: 0
Using vi, it's very easy to undo any number of changes you have made.  Make sure you are not editing (hit Esc), and hit the u.  This un-does the last change you made (in edit mode).  Repeating the u will continue to backtrack your changes. 

If you undo too many times, use cntrl-R will redo the last change you undid.  Again you can keep doing over and over.

Other questions in this category:
How do I set Tab stops in VI?
How can I turn on line numbering in Vi?
How can I jump to a line in the vi editor?
How can I remove DOS linebreaks (^M) from my files?
How can I remove leading whitespace in all lines in a file using vi?
How can I delete a large chunk of text using vi?
How can I search in the vi editor?



Powered by KnowledgebasePublisher 1.1
Superb Internet
Content provided by Roberts WebForge, Inc.