vim-non-blank


Ⅰ. 插件描述

Delete trailing whitespaces on every write

Ⅱ. 基本信息

创建日期:  2016-05-08
使用用户:  1
Github星:  4
插件作者:  Yota Toyama

Ⅲ. 安装方法

使用Vundle管理器安装

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

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

使用NeoBundle管理器安装

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

使用VimPlug管理器安装

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

使用Pathogen管理器安装

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

Ⅳ. 文档说明

# vim-nonblank

This plugin deletes trailing whitespaces on every write.

Installation

Using vim-plug,

Plug 'raviqqe/vim-nonblank'

Example

A buffer ($ denotes a newline character)

foo  $
$
  $
bar baz   $
  $
$

will be normalized as below.

foo$
$
$
bar baz$

Configuration

Disabling auto deletion

Set the enabled flag to 0.

let g:nonblank_enabled = 0

Then you can run :NonBlank command manually.

Blacklisting filetypes

Set the blacklist flag.

let g:nonblank_blacklist = ['python']

The default value is ['diff', 'gitcommit'].

License

The Unlicense

添加新评论