Ticket #3541: vimrc.diff

File vimrc.diff, 1.6 KB (added by IngmarStein@…, 19 years ago)

vimrc patch

  • vimrc

    old new  
    11" System vimrc file for Mac OS X
    22" Author:  Benji Fisher <benji@member.AMS.org>
    3 " Last modified:  5 April 2003
    4 
    5 " Get a good value for $PATH.  For example, if teTeX is installed, this
    6 " should add the path to tex, pdflatex, etc.
    7 " This should only make a difference when vim is started from the Finder or
    8 " with open.
    9 let $PATH = system("printenv PATH")
    10 let $PATH = substitute($PATH, "\<C-J>$", "", "")
     3" Last modified:  23 February 2004
    114
     5" TODO:  Is there any way to test whether Vim.app was started from the Finder?
     6if has("gui_running")
     7  " Get the value of $PATH from a login shell.
     8  " If your shell is not on this list, it may be just because we have not
     9  " tested it.  Try adding it to the list and see if it works.  If so,
     10  " please post a note to the vim-mac list!
     11  if $SHELL =~ '/\(sh\|csh\|bash\|tcsh\|zsh\)$'
     12    let s:path = system("echo echo VIMPATH'${PATH}' | $SHELL -l")
     13    let $PATH = matchstr(s:path, 'VIMPATH\zs.\{-}\ze\n')
     14  endif
     15  " Change directory on startup.
     16  autocmd VimEnter * if getcwd()=="/" | if strlen(@%) | cd %:p:h | else | cd | endif | endif
    1217" If running in a Terminal window, set the terminal type to allow syntax
    1318" highlighting.
    14 " Otherwise, change directory on startup.
    15 if !has("gui_running")
    16         set term=ansi
    17 else
    18         autocmd VimEnter * if getcwd()=="/" | if strlen(@%) | cd %:p:h | else | cd | endif | endif
     19" else
     20"   set term=ansi
    1921endif