Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
My personal Vim setup - mainly for my own use but feel free to copy/fork/whatever.
VimL Ruby
branch: master

This branch is 8 commits ahead, 3 commits behind ecomba:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
autoload
bin
colors
compiler
doc
ftdetect
ftplugin
indent
plugin
ruby
syntax
.VimballRecord
README
filetype.vim
gvimrc
install.sh
vimrc

README

OH MY VIM! :)

My personal Vim setup. Using GitHub to sync between home/work/netbook. Feel free to use and/or fork your own.

Included plugins:
* rails.vim
* snippets.vim
* rspec.vim
* cucumber.vim
* git.vim
* tComment.vim
* FuzzyFinder and FuzzyFinder Textmate (needs Ruby)
* NERD Tree
* surround.vim
* ack.vim

Works best if you don't already have any Vim setup.

git clone git://github.com/sermoa/ohmyvim.git ~/.vim

Set the .vimrc file as a symlink to get updates.

ln -s ~/.vim/vimrc ~/.vimrc
ln -s ~/.vim/gvimrc ~/.gvimrc

Periodically, to keep up to date:

cd ~/.vim
git pull



Useful commands/shortcuts

,t - open the fuzzy finder search
,b - fuzzy finder buffer - helps you switch between open files
gc - toggle comments


Rails Vim
gf - go to file referenced under the cursor (even the class of a variable!)
:A - go to the alternate file (spec/code)
:Rake - run specs


NERD tree
,d - toggle the NERD tree (drawer)
o - expand directory
O - recursive expand
x - close parent directory

p - go to parent
P - go to root
u - go up a directory
C - set current directory to be the root.

r - refresh

o - open file in last window
i - open in a horizontal split
s - open in a vertical split

? - toggle help for more commands


Git Vim
,gs - git status
,gd - git diff
,ga - add current file
,gA - add all outstanding files (non-standard - i changed this!)
,gc - git commit
,gp - git push


Surround.vim
Visually select the text you wish to surround
Type s and then the thing you want to surround with
e.g {, (, <p>, <p class='amazing'>
It is super-clever and will insert the appropriate close for you.


Ack.vim
:Ack followed by the text you wish to ack for. It's fairly obvious how to navigate the results. Note that you will need ack installed.

Something went wrong with that request. Please try again.