/usr/share/doc/vile-common/perl/hgrep.doc is in vile-common 9.8s-5.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 | NAME
hgrep - recursive grep with hypertext links
SYNOPSIS
In .vilerc:
perl "use hgrep"
In [x]vile:
:hgrep
and then provide responses to the ensuing prompts.
DESCRIPTION
The hgrep module is used with [x]vile's perl interface to provide a
nifty recursive grep facility complete with hypertext links.
One of the things which makes it so nifty is that it doesn't search
binary files. (If you want it to, just search for and remove the -T in
hgrep.pm.) So it's perfectly safe to just search * in most cases rather
than using a restrictive filter like *.[hc]
Assuming that the hgrep extension has been loaded in your .vilerc file
(see above), it may be invoked from the editor via
:hgrep
You will then need to answer questions at three prompts. The first is
Pattern to search for?
At the prompt, you should enter a regular expression. Some of the more
useful patterns are
string Search for string.
\bword\b Search for word. Note that \b indicates a word boundary.
(?i)pattern Search for the specified pattern, but ignore case.
See the perlre man page for more information about Perl regular
expressions.
The second prompt is
Directory to search in?
By default, either . (the current working directory) or the last
directory you entered will be displayed at this prompt. This is the
directory hierarchy to be searched.
The third (and final prompt) is
File name pattern?
This should be a glob expression which indicates the names to search. By
default it is * which means match all files. (Only text files as
indicated by Perl's -T operator are searched however).
Once all three questions have been answered, hgrep will create a new
buffer in which lines from files where matches occur are listed. The
highlighted text matching the regular expression is a hypertext link
which may be used to visit the places in the files corresponding to the
matched text. These hypertext commands may be activated by double
clicking in xvile or using the "execute-hypertext-command" command from
vile. (See the Hypertext section of vile.hlp for some convenient key
bindings.)
The error finder ^X^X (find-next-error) may also be used to quickly go
to the next match in the list without returning to the hgrep buffer.
AUTHOR
Kevin Buettner
|