vim-foldcomments


Ⅰ. 插件描述

Fold all comments.

Ⅱ. 基本信息

创建日期:  2013-12-02
使用用户:  1
Github星:  3
插件作者:  Xavier Nayrac

Ⅲ. 安装方法

使用Vundle管理器安装

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

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

使用NeoBundle管理器安装

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

使用VimPlug管理器安装

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

使用Pathogen管理器安装

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

Ⅳ. 文档说明

foldcomments.vim

Folds all commentaries of a source file.

Without:

Before

With:

After

Installation

With pathogen.vim

cd ~/.vim/bundle
git clone git://github.com/lkdjiin/vim-foldcomments.git

With vundle

Bundle 'git://github.com/lkdjiin/vim-foldcomments.git'

Usage

:FoldComments

Or, better, you could map the command FoldComments in your .vimrc, for example
on the F5 key:

map<F5> :FoldComments<Enter>

To unfold, use zE, or map it like this:

map<F6> zE

Caveats

Not all file's type are supported. This is curently limited to unix comment
style (#), Ruby, Haskell, Java, C, Javascript, Logo, Racket, Scheme
and Vim.

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

License

Copyright 2013, 2014 Xavier Nayrac. Distributed under the same terms as
Vim itself. See :help license.

Questions and/or Comments

Feel free to email Xavier Nayrac
with any questions, or follow me on twitter.

添加新评论