Ⅰ. 插件描述
You can use ambiguous command.Ⅱ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin 'thinca/ambicmd-vim'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle 'thinca/ambicmd-vim'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug 'thinca/ambicmd-vim'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/thinca/vim-ambicmd
Ⅳ. 文档说明
ambicmd is a Vim plugin to use ambiguous command.
Some plugins provide many useful command, but sometimes these are very long.
At this time, you will define the key mappings to execute these. but:
- You will have to define quite a lot of key mappings.
- You should find unused key sequence for mapping.
- Do you define a key mapping for a command only occasionally used?
This plugin expands a ambiguous command by some patterns. For example,
("|" is cursor)
" Expands to the correct name from the lowercase.
:ref<Space> => :Ref |
" Expands from the capital letter of the command.
:qr<Space> => :QuickRun |
" There are some commands with "NeoComplCache" prefix.
:ncc<Space> => :NeoComplCache|
This plugin does nothing by default.
You need write some settings to vimrc as follows.
cnoremap <expr> <Space> ambicmd#expand("<Space>")
cnoremap <expr> <CR> ambicmd#expand("<CR>")
Latest Version:
https://github.com/thinca/vim-ambicmd