Mac OS 上 VIM 8.0 安装体验

 

VIM 8.0 赶在中秋前发布

The best way to install Vim on Unix is to use the sources. This requires a compiler and its support files. Compiling Vim isn't difficult at all. You can simply type "make install" when you are happy with the default features. Edit the Makefile in the "src" directory to select specific features.

使用 git clone 比较浪费时间,还是下载压缩包比较好。在 Github Vim Releases 列表 选择一个最新版本,下载即可。例如,我下载的是 vim-8.0.0004.tar.gz。源码包大小有 12.9M 之巨。解压

tar xvzf vim-8.0.0004.tar.gz

编译安装

继续沿用 Vim7.4 在 Mac 10.11 上的编译参数

./configure --prefix=/opt/local --with-features=huge --enable-pythoninterp=yes --enable-multibyte --with-vim-name=vim --with-python-config-dir=/usr/lib/python2.7/config

注:由于,我要使用 UltiSnips,所以增加了 Python 支持。

make
sudo make install

然而当我敲下 sudo make install, 我吓尿了

% sudo make install

We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these three things:

    #1) Respect the privacy of others.
    #2) Think before you type.
    #3) With great power comes great responsibility.

好吧,能力越大责任越大,我庄严地输入了密码。安装过程结束。

基本功能体验

输入 vim 之后,出现了熟悉的画面

VIM 8.0 启动界面

没有报错,说明之前的 vimrc 配置没有兼容问题。又测试了几行最拿手的 Hello World 也没有问题。很好,兼容性甚佳。以往的 snippets 也可以正常使用。

新功能 - 包管理

看了一下 Vim 8 自带的包管理功能

:h package

无感,因为我没写过插件。。。还是继续使用我的 vundle。

原文地址:https://www.cnblogs.com/jackytang/p/9016062.html