Ⅰ. 插件描述
outline source for unite.vimⅡ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin 'shougo/unite-outline-love-story'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle 'shougo/unite-outline-love-story'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug 'shougo/unite-outline-love-story'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/shougo/unite-outline
Ⅳ. 文档说明
# unite-outline
Note: I am Shougo(unite plugin author). This plugin created by h1mesuke
- He is great VimL programmer. But he has not maintained this
- in several years. And I cannot contact with him. So I have maintained
it instead. To add features to this plugin is hard. I cannot extend it. Pull
requests are well come.
Introduction
unite-outline is a unite.vim's source
which provides your Vim's buffer with the outline view. It parses the current
buffer's content and extracts headings from the buffer. And then it shows the
list of the headings using unite.vim's interface. When you select a heading
from the list, you can jump to the corresponding location in the buffer.
The methods for extracting headings can be implemented for each individual
- You can customize them as you like with Vim script and can also
- new ones for unsupported filetypes.
Install
Install the distributed files into your Vim script directory which is usually
$HOME/.vim, or $HOME/vimfiles on Windows.
You can show the heading list of the current buffer with ":Unite outline"
command if you succeeded the installation (and unite-outline supports the
filetype of the buffer).
C, C++, Java, etc
- Exuberant Ctags (Required)
http://ctags.sourceforge.net/
Usage
To show the heading list of the current buffer, execute |:Unite| command with
"outline" as a source parameter.
:Unite outline
unite-outline parses the current buffer's content and extracts headings from
the buffer. And then it shows the list of the headings with unite.vim's
- When you select a heading from the list, you can jump to the
- location of the buffer.
See :help unite-outline for more details.
Extending
The easiest way to extend this plugin is if your language is supported by
If this is the case, add an entry to the lang_info dictionary in:
./autoload/unite/sources/outline/modules/ctags.vim
The --ctags-options field in the dictionary gets passed to ctags and specifies
the things ctags will report, the other fields control how unite-outline
organizines the items that ctags returns.
Finally, add an outline_info dictionary in a file named after your filetype:
./autoload/unite/sources/outline/defaults/{FILETYPE}.vim
See the other filetypes already in autoload/unite/sources/outline/defaults
for examples of what those files look like. Good luck!
Screenshots
See unite-outline's wiki.