vim 插件管理器-Vundle
2016-11-15 23:40
441 查看
Vim除了基本的使用方法,还有非常丰富的插件。如果没有管理器,插件的安装,更新,删除将会非常麻烦,个人感觉作用就类似RPM/yum, deb/apt-get,可以自行体会。
Vundle托管在G’itHub上,项目地址:https://github.com/VundleVim/Vundle.vim/
项目中的README.md有Vundle的基本介绍和安装及使用方法。
使用Vundle的好处:
- 在.vimrc中配置和管理plug-in
- 在vim中安装,更新,查找plug-in
重点说一下如何添加新的插件,在.vimrc的Vundle配置中有说明,可以使用如下四种方式添加需要的plug-in,前两种比较常用,主意查看每种插件在使用Vundle管理时在.vimrc中的配置(如一下第一种方式中的配色plug-in):
plugin on GitHub repo
plugin from http://vim-scripts.org/vim/scripts.html
Git plugin not hosted on GitHub
git repos on your local machine (i.e. when working on your own plugin)
Quick Start
Vundle托管在G’itHub上,项目地址:https://github.com/VundleVim/Vundle.vim/
项目中的README.md有Vundle的基本介绍和安装及使用方法。
使用Vundle的好处:
- 在.vimrc中配置和管理plug-in
- 在vim中安装,更新,查找plug-in
重点说一下如何添加新的插件,在.vimrc的Vundle配置中有说明,可以使用如下四种方式添加需要的plug-in,前两种比较常用,主意查看每种插件在使用Vundle管理时在.vimrc中的配置(如一下第一种方式中的配色plug-in):
plugin on GitHub repo
Plugin 'flazz/vim-colorschemes
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'
Quick Start
贴出我自己的.vimrc配置 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() " 必须安装,let Vundle manage Vundle, required Plugin 'VundleVim/Vundle.vim' " 来自github "主题 Plugin 'flazz/vim-colorschemes' "底部状态栏 Plugin 'Lokaltog/vim-powerline' "文件目录 Plugin 'scrooloose/nerdtree' "快速查找 Plugin 'kien/ctrlp.vim' "快速注释 Plugin 'scrooloose/nerdcommenter' "自动补全 Plugin 'Shougo/neocomplcache.vim' " 来自vim " non github repos call vundle#end() " required " ============================================================================== filetype plugin indent on " required " To ignore plugin indent changes, instead use: "filetype plugin on " ============================================================================== " vundle命令 " :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 " ============================================================================== " 组件设置 " flazz/vim-colorschemes,主题设置 colorscheme molokai "NERDTree 插件配置 map <F3> :NERDTreeToggle<CR> autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif let NERDTreeShowHidden = 1 "NERDTREE显示隐藏文件 " ============================================================================== " vim原生设置 " set rnu "显示相对行号 set nu syntax on " 打开语法检测 set tabstop=2 "设置tab键长度 set sw=2 set ts=2 set list "设置空格显示为+号 set listchars=trail:+ set foldmethod=syntax "代码折叠 set foldlevelstart=99 "默认不折叠 set cursorline "设置光标行 set noswapfile "不要生成swap文件 set nobackup set bufhidden=hide "当buffer被丢弃的时候隐藏它 set guicursor=n-v-c:hor10 "normal下贯标显示为下划线 set expandtab "Use space instead of tabs let mapleader = "," "设置外部复制粘帖 let g:mapleader = "," map Y "+y map P "+p "noremap ok o<esc> "插入新行 " Change cursor shape between insert and normal mode in iTerm2.app if $TERM_PROGRAM =~ "iTerm.app" let &t_SI = "\<Esc>]50;CursorShape=1\x7" " Vertical bar in insert mode let &t_EI = "\<Esc>]50;CursorShape=0\x7" " Block in normal mode endif "neocomplcache.vim let g:neocomplcache_enable_at_startup = 1 "打开vim时自动打开 let g:neocomplcache_force_overwrite_completefunc = 1
相关文章推荐
- Vundle(Vim bundle) 是一个vim的插件管理器。
- Vim插件之插件管理器Vundle
- vim之Vundle(插件的管理器)
- Vim插件之插件管理器Vundle
- vim插件管理器:Vundle的介绍及安装
- vim插件管理器:Vundle的介绍及安装(很全)
- VIM插件管理器之vundle
- vim中的杀手级插件: vundle (vim插件管理器)
- Vim插件之插件管理器Vundle
- 使用vundle进行Vim插件管理
- vim中的杀手级插件: vundle
- 用 Vundle 管理 vim 插件
- vim 插件 通过vundle 安装 tagbar
- 如何在 Linux 上使用 Vundle 管理 Vim 插件 | Linux 中国
- Vundle管理vim插件
- Linux基础(六) Vim之vundle插件
- Vimball : 基于vim的插件管理器
- vundle 管理 vim 插件
- VIM插件管理工具Vundle安装
- ubuntu12.04 vim的vundle插件安装方法