vim-commandcaps


Ⅰ. 插件描述

vim-commandcaps

Ⅱ. 基本信息

创建日期:  2013-07-19
使用用户:  20
Github星:  20
插件作者:  Tom Cammann

Ⅲ. 安装方法

使用Vundle管理器安装

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

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

使用NeoBundle管理器安装

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

使用VimPlug管理器安装

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

使用Pathogen管理器安装

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

Ⅳ. 文档说明

# vim-commandcaps

Plugin to make those annoying mistyped capitalised commands go away!

Now you don't have to worry if you accidentally hit :Wq - it will act just like :wq
No messing with remappings or abbrevations either!

Commands fixed

:W
:Q
:Wq
:WQ
:WQA
:WQa
:Wqa
:Qa
:QA
:Wa
:WA
:Xa
:XA

Options

If a command for the abbrevations listed above already exist they will not be
overwritten unless you add the following your .vimrc.

let g:commandcaps_override = 1

This will make commandcaps override any commands that have been mapped before
this script gets run. This issue may occur when used in conjunction with
vim-eunuch which also has a command on
:W.

Installation

I recommend installing using Vundle:

Add Bundle 'takac/vim-commandcaps' to your ~/.vimrc and then:

  • either within Vim: :BundleInstall
  • or in your shell: vim +BundleInstall +qall

Other Installation Methods

  • Pathogen

    • git clone https://github.com/takac/vim-commandcaps ~/.vim/bundle/vim-commandcaps
  • Neobundle

    • NeoBundle 'takac/vim-commandcaps'
  • Manual

    • Copy the files into your ~/.vim directory

添加新评论