App-Greple
view release on metacpan or search on metacpan
script/greple view on Meta::CPAN
Abort the operation.
=item B<ignore>
Ignore error and continue to read anyway.
=back
You may occasionally want to find text in binary data. Next command
will work like L<strings(1)> command.
greple -o --re '(?a)\w{4,}' --error=retry --uc /bin/*
If you want read all files as binary data, use C<--icode=binary>
instead.
=item B<-w>, B<--warn> I<type>=[C<0>,C<1>]
Control runtime message mainly about file operation related to
C<--error> option. Repeatable. Value is optional and 1 is assumed
when omitted. So C<-wall> option is the same as C<-wall=1> and enables
all messages, and C<-wall=0> disables all.
Types are:
=over 4
=item B<read>
(Default 0) Errors occurred during file read. Mainly unicode related
errors when reading binary or ambiguous text file.
=item B<skip>
(Default 1) File skip message.
=item B<retry>
(Default 0) File retry message.
=item B<begin>
(Default 0) When C<--begin> function died with C</^SKIP/i> message,
the file is skipped without any notice. Enables this to see the dying
message.
=item B<all>
Set same value for all types.
=back
=item B<--alert> [ C<size>=#, C<time>=# ]
Set alert parameter for large file. B<Greple> scans whole file
content to know line borders, and it takes several seconds or more if
it contains large number of lines.
By default, if the target file contains more than B<512 * 1024
characters> (I<size>), B<2 seconds> timer will start (I<time>). Alert
message is shown when the timer expired.
To disable this alert, set the size as zero:
--alert size=0
=item B<-Mdebug>, B<-d>I<x>
Debug option is described in L<App::Greple::debug> module.
=back
=head1 ENVIRONMENT and STARTUP FILE
=over 7
=item B<GREPLEOPTS>
Environment variable GREPLEOPTS is used as a default options. They
are inserted before command line options.
=item B<GREPLE_NORC>
If set non-empty string, startup file F<~/.greplerc> is not processed.
=item B<DEBUG_GETOPT>
Enable L<Getopt::Long> debug option.
=item B<DEBUG_GETOPTEX>
Enable L<Getopt::EX> debug option.
=item B<NO_COLOR>
If true, all coloring capability with ANSI terminal sequence is
disabled. See L<https://no-color.org/>.
=back
Before starting execution, B<greple> reads the file named F<.greplerc>
on user's home directory. Following directives can be used.
=over 7
=item B<option> I<name> string
Argument I<name> of B<option> directive is user defined option name.
The rest are processed by C<shellwords> routine defined in
Text::ParseWords module. Be sure that this module sometimes requires
escape backslashes.
Any kind of string can be used for option name but it is not combined
with other options.
option --fromcode --outside='(?s)\/\*.*?\*\/'
option --fromcomment --inside='(?s)\/\*.*?\*\/'
If the option named B<default> is defined, it will be used as a
( run in 0.867 second using v1.01-cache-2.11-cpan-39bf76dae61 )