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.

Searching over net shows :f filename would rename the current file in vim. But executing this and later exiting vim, shows the new file with all the contents and also the old file is present with the saved content untill executing the above command.

So, how can we rename the current file we are editing in vim ?

EDIT - Any solution that does not involve a plugin, as I guess that would require administrative privileges which I don't have. Any tweaks with config or mapping ?

share|improve this question
2  
You do not need root privileges to install normal vim plugins. As normal user, you can install them to the .vim subdirectory in your home folder. –  jofel Jan 31 '13 at 15:05
add comment

1 Answer

up vote 1 down vote accepted

I found this plugin as useful for you. Once you install it you get the opportunity to use :rename, which does what the mv command does on Unix. Also you might get some ideas from here for other alternatives.

share|improve this answer
2  
It would be nice if you can add a short explanation on each link. –  Bernhard Jan 31 '13 at 12:01
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.