Welcome 微信登录

首页 / 操作系统 / Linux / Vim好用的插件: vundle

相比sublime text2等现代编辑器,Vim缺乏默认的插件管理器,所有插件的文件都散布在~/.vim下的几个文件夹中,配置vim的过程, 就是在网上不停的搜插件,拷贝到~/.vim下,发现更新,要重新下载重新拷贝,想要删除某个不需要插件,更是要小心翼翼的不要删错。配置出顺手的Vim, 需要极大的耐心和运气。当然vim社区的活力是不容怀疑的,没有枪没有炮大神们自己造。以前使用过tpope的pathogen,使用git submodule和pathogen, 管理插件已经大大简化。而今天介绍的vundle, 更是把git操作整合进去,用户需要做的只是去Github上找到自己想要的插件的名字,安装,更新和卸载都可有vundle来完成了。虽然去发现一个好的插件仍然是一个上下求索的过程,但是用户已经可以从安装配置的繁琐过程解脱了。Vundle的具体介绍查看vim.org,或者github repo安装和配置下载vundle $ git clone https://github.com/gmarik/vundle.git ~/.vim/bundle/vundle在.vimrc 中添加bundle的配置set nocompatible                " be iMproved
filetype off                    " required!
set rtp+=~/.vim/bundle/vundle/
call vundle#rc()" let Vundle manage Vundle
Bundle "gmarik/vundle""my Bundle here:
"
" original repos on github
Bundle "kien/ctrlp.vim"
Bundle "sukima/xmledit"
Bundle "sjl/gundo.vim"
Bundle "jiangmiao/auto-pairs"
Bundle "klen/python-mode"
Bundle "Valloric/ListToggle"
Bundle "SirVer/ultisnips"
Bundle "Valloric/YouCompleteMe"
Bundle "scrooloose/syntastic"
Bundle "t9md/vim-quickhl"
" Bundle "Lokaltog/vim-powerline"
Bundle "scrooloose/nerdcommenter"
"..................................
" vim-scripts repos
Bundle "YankRing.vim"
Bundle "vcscommand.vim"
Bundle "ShowPairs"
Bundle "SudoEdit.vim"
Bundle "EasyGrep"
Bundle "VOoM"
Bundle "VimIM"
"..................................
" non github repos
" Bundle "git://git.wincent.com/command-t.git"
"......................................
filetype plugin indent onbundle分为三类:
1.在Github vim-scripts 用户下的repos,只需要写出repos名称
2.在Github其他用户下的repos, 需要写出”用户名/repos名”
3.不在Github上的插件,需要写出git全路径安装插件打开一个vim, 运行:BundleInstall或者在命令行运行 vim +BundleInstall +qall安装完成后插件就能用了其它常用命令:
•更新插件:BundleUpdate
•清除不再使用的插件:BundleClean,
•列出所有插件:BundleList
•查找插件:BundleSearch更多Vim相关教程见以下内容:把VIM打造成一个简单实用的IDE http://www.linuxidc.com/Linux/2011-06/37032.htmVim学习指南 http://www.linuxidc.com/Linux/2013-08/89096.htm快速学会 Vi编辑器 http://www.linuxidc.com/Linux/2013-08/88586.htm强大的Vim 编辑器 http://www.linuxidc.com/Linux/2013-07/87544.htm在CentOS 6.2上搭建Vim开发环境 http://www.linuxidc.com/Linux/2013-07/87363.htmCentOS 5.4 安装高亮Vim编辑工具 http://www.linuxidc.com/Linux/2013-06/86508.htmVim技巧分享:C语言设置 http://www.linuxidc.com/Linux/2012-12/77124.htmUbuntu中设置Vim的行号 http://www.linuxidc.com/Linux/2012-12/75485.htmVim编辑器使用基础教程 http://www.linuxidc.com/Linux/2013-05/84031.htm本文永久更新链接地址