vim-ack


Ⅰ. 插件描述

a simple ack plugin for vim

Ⅱ. 基本信息

创建日期:  2015-07-04
使用用户:  4
Github星:  0
插件作者:  Toran Billups

Ⅲ. 安装方法

使用Vundle管理器安装

在你的.vimrc下添加:
Plugin 'toranb/vim-ack-or-are-not'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall

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

使用NeoBundle管理器安装

在你的.vimrc下添加:
NeoBundle 'toranb/vim-ack-or-are-not'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall

使用VimPlug管理器安装

在你的.vimrc下添加:
Plug 'toranb/vim-ack-or-are-not'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall

使用Pathogen管理器安装

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

Ⅳ. 文档说明

# VIM-ACK

A wrapper for the Perl module Ack.
This plugin will allow you to run ack from vim, and shows the results in a split window.

INSTALLATION

Use your plugin manager of choice.

  • Pathogen

    • git clone https://github.com/JarrodCTaylor/vim-ack ~/.vim/bundle/vim-ack
  • Vundle

    • Add Bundle 'https://github.com/JarrodCTaylor/vim-ack' to .vimrc
    • Run :BundleInstall
  • NeoBundle

    • Add NeoBundle 'https://github.com/JarrodCTaylor/vim-ack' to .vimrc
    • Run :NeoBundleInstall
  • vim-plug

    • Add Plug 'https://github.com/JarrodCTaylor/vim-ack' to .vimrc
    • Run :PlugInstall

REQUIREMENTS

You must have ack installed.

Usage

:Ack [options] {pattern} [{directory}]

Search recursively in {directory} (which defaults to the current directory) for the {pattern}.

Files containing the search term will be listed in the split window, along with
the line number of the occurrence, once for each occurrence. [Enter] on a line
in this window will open the file, and place the cursor on the matching line.

SPECIAL CHARACTERS

Some characters have special meaning, and need to be escaped your search pattern.
For instance, '#'. You have to escape it as follows :Ack '\\\#define foo' to search
for #define foo.

KEYBOARD SHORTCUTS

In the quickfix window, you can use:

Enter Open in buffer and automatically close preview window

o    to open
go   to preview file (open but maintain focus on ack.vim results)
t    to open in new tab
T    to open in new tab silently
h    to open in horizontal split
H    to open in horizontal split silently
v    to open in vertical split
gv   to open in vertical split silently
q    to close the quickfix window

添加新评论