Update built-in vim on Mac OS X

后端 未结 8 952
后悔当初
后悔当初 2020-12-12 08:50

I know this might be more appropriate at Ask Different, but as I tried adding tags there, there was no vim tag, only macvim. So I figured I might g

8条回答
  •  隐瞒了意图╮
    2020-12-12 09:11

    Don't overwrite the built-in Vim.

    Instead, install it from source in a different location or via Homebrew or MacPorts in their default location then add this line to your .bashrc or .profile:

    alias vim='/path/to/your/own/vim'
    

    and/or change your $PATH so that it looks into its location before the default location.

    The best thing to do, in my opinion, is to simply download the latest MacVim which comes with a very complete vim executable and use it in Terminal.app like so.

    alias vim='/Applications/MacVim.app/Contents/MacOS/Vim' # or something like that, YMMV
    

提交回复
热议问题