GrepCommands


Ⅰ. 插件描述

Perform :vimgrep over arguments, buffers, windows.

Ⅱ. 基本信息

创建日期:  2012-08-16
使用用户:  2
Github星:  0
插件作者:  Ingo Karkat

Ⅲ. 安装方法

使用Vundle管理器安装

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

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

使用NeoBundle管理器安装

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

使用VimPlug管理器安装

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

使用Pathogen管理器安装

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

Ⅳ. 文档说明

DESCRIPTION
This plugin defines variants of the built-in :vimgrep command which target
all arguments, listed buffers, windows in the current tab page or all tab
pages for its search. Additionally, the search defaults to the last search
pattern, so using these commands is often much faster than building the
equivalent search with :vimgrep.

SEE ALSO

  • The GrepHere plugin (vimscript #4191) provides a :GrepHere command that
      covers only the current buffer.

RELATED WORKS

  • This is a modern re-implementation of the similar commands defined by
      greputils.vim (vimscript #1062), which hasn't been updated since 2005.
  • brep (vimscript #3653) can grep buffers (also unlisted with [!]) and show
      them in the quickfix list.
  • greplace (vimscript #1813) can search buffers and arguments; it shows the
      matches in a special replace buffer that can be edited and incorporated into

  the original files.

USAGE
:ArgGrepAdd [{pattern}]
:ArgGrepAdd /{pattern}/g
                        Search for {pattern} (or last search pattern if
                        omitted) in all files from the argument-list and set
                        the error list to the matches.
                        Same as :vimgrep {pattern} ##.

:BufGrepAdd [{pattern}]
:BufGrepAdd /{pattern}/g
                        Search for {pattern} (or last search pattern if
                        omitted) in all listed buffers and set the error list
                        to the matches.

:WinGrepAdd [{pattern}]
:WinGrepAdd /{pattern}/g
                        Search for {pattern} (or last search pattern if
                        omitted) in all buffers visible in the current tab
                        page and set the error list to the matches.

:TabGrepAdd [{pattern}]
:TabGrepAdd /{pattern}/g
                        Search for {pattern} (or last search pattern if
                        omitted) in all buffers visible in all tab pages and
                        set the error list to the matches.

添加新评论