vim-eh-docs


Ⅰ. 插件描述

Look up Elixir documentation from vim, using eh

Ⅱ. 基本信息

创建日期:  2015-01-17
使用用户:  31
Github星:  3
插件作者:  Martin Frost

Ⅲ. 安装方法

使用Vundle管理器安装

在你的.vimrc下添加:
Plugin 'frost/vim-eh-docs'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall

对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。

使用NeoBundle管理器安装

在你的.vimrc下添加:
NeoBundle 'frost/vim-eh-docs'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall

使用VimPlug管理器安装

在你的.vimrc下添加:
Plug 'frost/vim-eh-docs'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall

使用Pathogen管理器安装

在终端中运行以下命令:
cd ~/.vim/bundle
git clone https://github.com/frost/vim-eh-docs

Ⅳ. 文档说明

## Usage

Call EhDocs() to look up the current keyword.

There is also a keymapping for this. It defaults to <leader>k.

EhDocs will look up the module or function currently under the cursor,
by calling whatever keywordprg you have defined, for example
eh.

Examples: (<x> means that the cursor placed on x)

For docs on the Foo module:

(<F>oo.Bar.baz)
<F>oo.Bar.baz()
F<o>o.Bar.baz()
Fo<o>.Bar.baz()
Foo<.>Bar.baz()

For docs on the Foo.Bar module:

(Foo.<B>ar.baz())
Foo.<B>ar.baz()
Foo.B<a>r.baz()
Foo.Ba<r>.baz()
Foo.Bar<.>baz()

For docs on the Foo.Bar.baz function:

(Foo.Bar.<b>az())
Foo.Bar.<b>az()
Foo.Bar.b<a>z()
Foo.Bar.ba<z>()
Foo.Bar.baz<(>)
Foo.Bar.baz< >args
Foo.Bar.baz<$>

Configuration

Configure eh-docs map prefix (default is <leader>) with

let g:ehdocs_map_prefix = '<leader>'

Switch lookup command (default is mix eh) with

let g:ehdocs_lookup_command = 'mix eh'

Dependencies

EhDocs depends on having something that works like "eh", or the built-in
IEx.Helpers.h function, callable using

`:call g:ehdocs_lookup_command .  " " . some_key_word`

添加新评论