安装MacVim:

方法一:

使用brew安装MacVim。

在shell下执行以下语句安装brew

$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

系统返回

==> Installation successful!

时表示brew安装成功。

现在,还需要将Homebrew目录加入到PATH环境变量,这样,Homebrew的安装将优先于MacOS的安装。打开或创建文件 ~/.bash_profile在文件中写入

  1 # Setting PATH for homebrew2 export PATH=/usr/local/bin:$PATH

再执行以下语句安装MacVim(同时安装cscope和lua)

$ brew install macvim --with-cscope --with-lua

方法二:

从GitHub下载MacVim,当前最新版为MacVim-7.4.dmg,下载完成后双击dmg文件安装。

MacVim下载地址:https://github.com/macvim-dev/macvim/releases

安装Vim的插件管理工具Vundle:

Bundle主页:https://github.com/VundleVim/Vundle.vim

主页有其详细的安装使用说明

shell下执行

$ git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim

配置MacVim:

Vim的配置文件有:vimrc,gvimrc和exrc三个。这些配置文件的所在位置由vim的安装目录和操作系统决定。因为MacVim也是Vim的一个版本,故MacVim与Vim的配置方法一样。

vimrc

vimrc是Vim的最主要配置文件,其有两个版本:全局版本(global)和用户版本(personal)。全局版本的vimrc文件在Vim的安装目录中,Mac OS系统中其所在目录为/usr/share/vim/vimrc。

用户版本的vimrc文件在当前用户的主目录下,Mac OS系统中用户版本的vimrc文件目录为/user/用户名/.vimrc。(注:Mac下默认是没有用户版本的vimrc,所以如果需要可以自己创建一个)

使用中只需修改用户版本的vimrc文件,因为用户版本的设置总是会覆盖全局版本中的设置。

gvimrc

gvimrc是gvim的配置文件,与vimrc相似,并且是放在同一个目录下的,也分为全局版本和用户版本。我们要用的是vim所以不需要修改这个文件。

exrc

exrc是用于vim或ex向后兼容的,也于vimrc放于同一目录,同样也分为全局版本和用户版本。只有在我们想用vi的兼容模式来使用vim时才会用到这个文件。

将一下代码复制到vimrc文件里以启用Vundle。

set nocompatible              " be iMproved, required
filetype off                  " required" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'" The following are examples of different formats supported.
" Keep Plugin commands between vundle#begin/end.
" plugin on GitHub repo
Plugin 'tpope/vim-fugitive'
" plugin from http://vim-scripts.org/vim/scripts.html
Plugin 'L9'
" Git plugin not hosted on GitHub
Plugin 'git://git.wincent.com/command-t.git'
" git repos on your local machine (i.e. when working on your own plugin)
Plugin 'file:///home/gmarik/path/to/plugin'
" The sparkup vim script is in a subdirectory of this repo called vim.
" Pass the path to set the runtimepath properly.
Plugin 'rstacruz/sparkup', {'rtp': 'vim/'}
" Avoid a name conflict with L9
Plugin 'user/L9', {'name': 'newL9'}" All of your Plugins must be added before the following line
call vundle#end()            " required
filetype plugin indent on    " required
" To ignore plugin indent changes, instead use:
"filetype plugin on
"
" Brief help
" :PluginList       - lists configured plugins
" :PluginInstall    - installs plugins; append `!` to update or just :PluginUpdate
" :PluginSearch foo - searches for foo; append `!` to refresh local cache
" :PluginClean      - confirms removal of unused plugins; append `!` to auto-approve removal
"
" see :h vundle for more details or wiki for FAQ
" Put your non-Plugin stuff after this line

重启MacVim。

插件安装:

在MacVim里运行:PluginInstall

MacVim> PluginInstall

在shell下执行

$ vim +PluginInstall +qall

MAC MacVim及Vundle安装相关推荐

  1. linux查找部署目录,mac/linux 查找软件安装、配置路径

    在mac/linux系统下用brew.yum.apt等下载软件,需要修改配置文件时,经常懵逼不知道安装路径或者配置文件路径在哪.这里总结一下我常用的查找方法. 1. whereis 输入man whe ...

  2. MongoDB学习第一篇 --- Mac下使用HomeBrew安装MongoDB

    2019独角兽企业重金招聘Python工程师标准>>> MongoDB学习第一篇 --- Mac下使用HomeBrew安装MongoDB 0.确保mac已经安装了HomeBrew ( ...

  3. 在 Mac OS X 上安装 TensorFlow

    在 Mac OS X 上安装 TensorFlow 这个文档说明了如何在 Mac OS X 上安装 TensorFlow. 注意:从 1.2 版本开始,在 Mac OS X 上 TensorFlow ...

  4. mac安装完python怎么打开-Mac OS系统如何安装python

    Mac OS安装python步骤 如果你使用苹果电脑的 Mac OS 系统,下载时,请进入 https://www.python.org/页面,选择Downloads,在弹出的菜单中选择Mac OS ...

  5. python下载安装教程mac-教程|如何在mac上为Python安装XGBoost!

    原标题:教程|如何在mac上为Python安装XGBoost! 摘要:XGBoost是一个开发非常快速和准确的梯度增强模型的库,它在Kaggle数据科学竞赛中被大量的kaggle选手选用,其中包括两个 ...

  6. 在Mac OS X上安装 Ruby运行环境

    2019独角兽企业重金招聘Python工程师标准>>> 系统需求 首先确定操作系统环境,不建议在 Windows 上面搞,所以你需要用: Mac OS X 任意 Linux 发行版本 ...

  7. 在Mac OS环境下安装MySQL服务

    在Mac OS环境下安装MySQL服务 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 我之前介绍过window环境下安装mysql服务,以及在Linux环境下安装mysql服务,今 ...

  8. 苹果MAC OS X怎么安装双系统?

    苹果MAC OS X怎么安装双系统? | 浏览:179543 | 更新: 2012-06-05 22:56 | 标签: 苹果 1 2 3 4 5 6 7 分步阅读 苹果的MacBook NB传承其一惯 ...

  9. mac photoshop install无法安装_MAC安装应用报错:无法打开或文件损坏的处理方法~...

    有些用户下载了一些程序之后,却发现无法在MAC中安装,安装时会弹出下图所示警告框:"打不开 xxx,因为它来自身份不明的开发者".那么该如何解决这个问题呢? 在MAC下安装一些软件 ...

最新文章

  1. scrapy的几个文件属性
  2. 介绍一个.Net资源站点
  3. java内存图怎么画,jvm内存模型怎么画?简单美观的模型图制作软件
  4. 引入Jaeger——使用
  5. 统计sql server数据库中所有表的记录数
  6. 字节面试:如何用Redis实现一个分布式锁?
  7. SVG添加链接(转载)
  8. 早期微信抢红包插件项目分享
  9. quartus破解!!!!!
  10. 计算机水平测试在线模拟,计算机等级考试一级模拟试题「附答案」
  11. Could not transfer artifact org.springframework.boot:spring-boot-starter-parent:pom:2.3.0.RELEAS错误解决
  12. PassMark 更新排行,苹果 M1 杀疯了
  13. visio2013-软件UML序列图02
  14. 【学习OpenCV4】进度条实现总结
  15. HTML结构及常用的标签
  16. 企业级360用户画像
  17. win7安装node版本最高只支持13.14.0
  18. 在sh_goods表中查询评分小于4的商品的不同分类id。
  19. 制作ubuntu系统的 usb启动盘
  20. Friends number

热门文章

  1. 【JavaScript练习】用户输入一个数判断是否是素数,并弹出返回值
  2. 物理PC机ping不通虚拟机解决方法(亲测可用)
  3. ​Web前端剪切板文本分享到文件发送
  4. 利用ArcGIS提取高光谱图像每个像素的光谱信息,再利用matlab显示每个像素的光谱信息
  5. LTE-5G学习笔记33--通信行业考哪些证可以升职加薪
  6. Qt5之qrc资源文件
  7. 11- 移动车辆识别统计项目 (OpenCV操作指南) (项目十一) *
  8. Eclipse一直building workspace: invoking maven project builder卡主
  9. MySQL+Java 图书管理系统
  10. 首批最佳骑行路线揭晓