A frustrating week with textMate has proved it is simply better to control your own editor versus stick with the ideas predetermined by other programmers. I have bounced between Vim/MacVim/TextMate for about a year now. I am about to get a new Air and would really like to copy my .rc files and be good, so I spent a little time today working out some of the customizations I wanted in MacVim. Before starting this I had NERDTree and RailsVim already installed.

A few of the softwares I went and picked up were:

MacVim: choose-your-version
Vim ColorSamplePack: download | docs
Vim ScrollColor: download | docs
PeepOpen: download

After installing the above I added the alias to my ~/.bashrc so MacVim is simple to open.

alias gvim='/Applications/MacVim.app/Contents/MacOS/Vim -g'

Then I updated my .vimrc to this:

if &t_Co > 2 || has("gui_running")
  syntax on
  colorscheme slate
  :set hlsearch
  :set guifont=Menlo\ Regular:h14
  :set tabstop=2
  :set sw=2
endif
map <silent><F3> :NEXTCOLOR<cr> 
map <silent><F2> :PREVCOLOR<cr>

Next, I wanted to change the -p default for PeepOpen to cmd+T, so in my .gvimrc file I used the what the docs indicated:

if has("gui_macvim")
   macmenu &File.New\ Tab key=<nop>
   map <D-t> <Plug>PeepOpen
end

In terminal at my project root I can run:
$ gvim .

This brings up the pretty MacVim editor. One last setting to change is in MacVim > Preferences:

Snap! Now I have a full suite of great themes to use on MacVim. The best part is I don’t have to run out and download more themes for a while. With func+2/func+3 I can cycle through the list of themes, my tabs are set to mimic the rest of my teams, and I have a great way to search for documents and open them in a new split with cmd+T.

Leave a Reply

Your email address will not be published. Required fields are marked *