Ⅰ. 插件描述
toggle related buffers. This can be .c <-> .h. It also can mean: show all files having same file extension in curent dir etc. Extend as you wishⅡ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin 'marcweber/vim-addon-toggle-buffer'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle 'marcweber/vim-addon-toggle-buffer'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug 'marcweber/vim-addon-toggle-buffer'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/marcweber/vim-addon-toggle-buffer
Ⅳ. 文档说明
== Allow toggling related buffers fast: ==
C/C++ and the like
.h .hh <-> .c .cc .cpp .cxx
ocaml
.ml <-> .mli
== implemntation details ==
a global dict keeps a list of functions which return alternate files.
A mode is passed to the function, so that you can change its behaviour from
"return most likely matches only" to "return all possible matches"
The functions are expected to return string(filename) or string({'file': file, 'line': line})
Each function is added to a dict so that no duplicates occur and so that you
can update entries easily
== notes ==
I recommend vim-addon-manager for installing plugins