Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

Various editors like gedit detect if the file is changed and asks to reload it. Sometimes in vim when I got many files to edit, I sometimes end up opening same file in different tabs for quick look with other files and several other reasons.

So is there anyway I can force to reload the current file before I update anything to it.

I know one option is to exit and reopen it, but I have splitted the screen and I don't want to loose that view.

share|improve this question
add comment

1 Answer

up vote 3 down vote accepted

With :e! you can reload the same file and dismiss any changes that you did until that point, after the last save.

If you did not do anything in vim, but changed the file externally, you can reload by just type :e.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.