Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I accidentally deleted some files in the vim73 folder on my mac. How can I get the original files of my vim?

share|improve this question

migrated from stackoverflow.com Nov 1 '12 at 8:50

This question came from our site for professional and enthusiast programmers.

add comment

4 Answers 4

You can't hit a button and have this folder back. A system upgrade or a full re-install may help but it's maybe a little bit too much.

You could also install Vim from the sources and specify the default location as target. Normally I don't advocate that kind of method but you already messed with your system so…

The best solution, IMO, is simply to install another Vim, anywhere, and completely forget about the default Vim. It has always sucked in one way or the other anyway and the absolute best solution for using Vim on a Mac is still the same as it has been for quite some time: install (manualy or with Homebrew) MacVim which comes with a CLI executable.

And stop messing with those default files! If you want to customize/install stuff, do that in ~/.vim.

share|improve this answer
add comment

Do you use Time Machine?

If not, you should.

It really helps in times like these.

Plus it's SUPER easy to use.

share|improve this answer
2  
This isn't exactly a solution, but more of a comment on what the OP should do in the future. –  TheAmateurProgrammer Nov 1 '12 at 6:56
    
It is a solution if the OP already uses TimeMachine... Although he probably doesn't if he's asking this question, so good point. –  jahroy Jun 21 '13 at 2:52
add comment

If you don’t want to reinstall vim (which is the preferred solution) then runtime files (those that are in /usr/share/vim/vim73) are located in mercurial repository of vim in runtime/ subfolder: http://code.google.com/p/vim/source/browse/runtime. You may need to specify exact vim version like http://code.google.com/p/vim/source/browse/runtime?name=v7-3-712 (directly in URL or by selecting in “Tag:” list), but most of time vim runtime files from newer versions work normally on older ones.

Note though that I would recommend reinstalling vim, not trying to undo the changes manually.

share|improve this answer
    
I deleted some files in /usr/share/vim/vim73, how to install the original vim. I only found an app called macvim which may not be what i want. –  user1684696 Nov 1 '12 at 17:22
    
@user1684696 No idea, I don’t have mac. You can just fetch all files from the vim repository and put them into /usr/share/vim/vim73. Or install macvim, it should not hurt: What are the advantages of MacVim over Vim? There is also some advice to install vim from macports, but I don’t know how to do this exactly. –  ZyX Nov 1 '12 at 18:43
add comment

I would uninstall then reinstall vim, using whatever you used to install it in the first place.

share|improve this answer
    
It's preinstalled with the OS. –  duskwuff Nov 1 '12 at 0:38
    
how to uninstall and how to reinstall? Thx:) –  user1684696 Nov 1 '12 at 17:22
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.