Skip to content

Instantly share code, notes, and snippets.

@eddsteel
Created April 19, 2011 09:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save eddsteel/927043 to your computer and use it in GitHub Desktop.
Save eddsteel/927043 to your computer and use it in GitHub Desktop.
Allow gvim to be started from windows or the cygwin shell, peacefully co-existing with a symlinked .vimrc
" because cygwin sets $HOME, ~/.vimrc will be read if you launch gvim from cygwin.
" If you have a _vimrc as well, this will be read in preference on windows.
" You can then source your normal windows rc (which you probably pointed back at your unix one directly,
" avoiding symlinks.
" If you have pathogen, this will make it work on gvim launched from cygwin as well!
let &rtp = &rtp.','.'D:/opt/cygwin/home/<user name here>/dotfiles/home/.vim' " Where your bundles are.
so D:/opt/vim/_vimrc " Whatever your windows rc is.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment