Vim

Vim later, Vim earlier

Today I will tell about a very interesting feature of vim. It allows you to jump back in time and change a file to what it looked like at a particular time.

You are editing a document, and now suppose after 10 minutes you realize that you want to revert to the revision of the file before 10 minutes ago, use:


:earlier 10m

Now if you want to jump ahead, may be 10 seconds, use


:later 5s

Now if you want to revert to 10 edits before,


:earlier 10

 

Happy Vimming.! 🙂

Advertisements

2 thoughts on “Vim later, Vim earlier

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s