title: Syncing vimrc and plugins between unix and windows machine
body: <p>I am using the method described <a href="http://vimcasts.org/episodes/synchronizing-plugins-with-git-submodules-and-pathogen/" rel="nofollow">in this screencast</a> to keep my vimrc and plugins synced across multiple machines.  The problem I'm running into is that one machine is running ubuntu and the other running win7.  </p>
  
  <p>I've found two types of problems so far.  The first seems to be with line endings.  To get my windows vimrc to be read on the linux box, I had to do <code>:set fileformat=unix   and write</code>.  But even after doing that, I am getting similar line-ending problems with all the plugins:  </p>
  
  <pre><code>jg@jg-VirtualBox:~$ vim ~/.vimrc
  Error detected while processing /home/jg/.vimrc:
  line   11:
  E484: Can't open file /home/jg/vimfiles/plugin/autotag.vim
  Error detected while processing /home/jg/.vim/plugin/DrawIt.vim:
  line   60:
  E492: Not an editor command: ^M
  line   62:
  E15: Invalid expression: &amp;cp^M
  line 1290:
  E171: Missing :endif
  Error detected while processing /home/jg/.vim/plugin/auto_number.vim:
  line    5:
  E488: Trailing characters
  </code></pre>
  
  <p>I could do something like <code>vim ~/.vim/**/*.vim</code>  to load them all and then <code>:argdo set ff=unix | w</code> to fix all the files in the same way, but that seems like a poor method, since any time I update the git repo with my vimfiles from one computer and pull it from the other, I'll have to remember to do this file conversion.  Is there a better way?</p>
  
  <p>Finally, certain configuration details in the vimrc, such as the location of the location of certain binaries, will be different depending on the OS.  What is the best way to handle these differences?  Should I be peppering my .vimrc with if statements branching on has("gui_win32"), or is there a better way?</p>
  
  <p>Thanks!</p>