I use Vim a lot. For almost all my text editing on a regular basis. On my Mac I use MacVim. I have XCode installed. Wonderful program I guess but I have yet to use it. But how many people actually Vi (not Vim) on a regular basis. I don’t. And why should I? Vim does everything Vi does and more.
The other day at work though I was tasked with editing some files on our servers. Mainly bash scripts, a couple of SQL packages, and I was forced to Vi. Using Vi is a whole other game from Vim. Things like syntax highlighting don’t exist. Niceties like your rc files don’t exist. The difference between insert and command mode is hard and unforgiving. In Vim its softer. You might be in command mode, but a lot of time you’d never know it the way you still navigate thought the text.
I’ll tell you though. If you want to learn how to use Vim, learn Vi. It’ll make a man out of you.
Enjoy the Penguins!
I found two new things to stuff in my vimrc file. I thought I would post about them here so that others could revel in the glory of v-i-m.
On Linux these two commands do not really appear to help you that much. On Windows though (haven’t tried on any other OSes) these two lines are a life saver.
If you have backup set in your vimrc you’ll notice that Vim leaves little backup files of every file you edit in the same location as that file. Well, generally, these are hidden files on Linux so you might very well have hundreds of them laying around and you don’t even know it. On Windows though they’re not hidden and constantly clog of you desktop along with every other folder full of text files. So the first one is a lifesaver.
The second command, the directory setting, is were Vim will store its swap files that it creates. I do not honestly know what exactly is kept in these things, but they’re temp files who are removed as soon as the editor is closed. But this command keeps them out of sight if nothing else. I’m anal about my desktop so that explains my love of the second setting as well.
I put both of mine in a directory, simply titled, “backup.” I do not know what the difference is between the vimfiles directory and the vim71 directory, but I put them in the latter. Everything else seemed to be there.
So there you have it. Two little tidbits to tiddy of your desktop.
Enjoy the Penguins!