App-pl

 view release on metacpan or  search on metacpan

pl  view on Meta::CPAN


=item C<-BI<prog>>

Add program before main program in same scope.  So you can use it to
initialise C<my> variables.  Whereas, if you define a my variable in the main
program of a B<-n>, B<-p>, B<-P>, B<-o> or B<-O> loop, it's a new variable on
each iteration.  This doesn't do a C<BEGIN> block, unless program is wrapped
in C<{}>.  May be mixed with B<-A>.

=item C<-c>

I<perl:> Check syntax only (runs C<BEGIN> and C<CHECK> blocks).

=item C<-CI<[number/list]>>

I<perl:> Enables the listed Unicode features.

=item C<--colorI<[=when]>>

Colorize (people with impairment have hopefully adapted their system or
browser) some of the output; when can be C<never>, C<always>, or C<auto> (the
default).

=item C<-dI<[:debugger]>>

I<perl:> Run program under debugger.

=item C<-DI<[number/list]>>

I<perl:> Set debugging flags (argument is a bit mask or alphabets).

=item C<-eI<prog>>

Run program after finishing reading a file in B<-n>/B<-p>.

=item C<-EI<prog>>

Add an C<END> block after main-program in same scope.  So C<my>-vars work as
follows: The C<END> block is a closure of the 1st C<$inner> variable.  Perl
warns "Variable "$inner" will not stay shared":

    pl -OB 'my $outer' -E 'echo $inner, $outer' 'my $inner = $outer = $ARGV' a b c
    pl -OB 'my $outer' -E 'e $inner, $outer' 'my $inner = $outer = $A' a b c

    >   a c

=item C<-f>

I<perl:> Don't do F<$sitelib/sitecustomize.pl> at startup.

=item C<-FI</pattern/>>

I<perl:> Provide C<split()> pattern for B<-a> switch (C<//>'s are optional).

=item C<-II<directory>>

I<perl:> Specify C<@INC>/C<#include> directory (several B<-I>'s allowed).

=item C<-iI<[extension]>>

I<perl:> Edit C<< <> >> files in place (makes backup if extension supplied).

=item C<-n>

I<As I said before, I never repeat myself. :-)>

I<perl:> Assume C<< while (<>) { ... } >> loop around program.  It's a little
richer than that: if you use C<last>, it closes the current file, leaving you
to continue the loop on the next file.

=item C<-oI<[number]>>

Assume C<for(@ARGV) { ... }> loop around main program, and C<$ARGIND> (or
C<$I>) is the current position.  In this case B<-p> doesn't imply B<-n>.  If
number is given, that many args are passed at once as an array, referencing
the original values.  If there are not enough on the last round, C<@A(RGV)> is
filled up with C<undef>.

    pl -opl '' I II III IV
    pl -o3 'echo $ARGIND, @$_' i ii iii iv v vi vii viii ix
    pl -opl '' I II III IV
    pl -o3 'e $I, @$_' i ii iii iv v vi vii viii ix

    >   I
    >   II
    >   III
    >   IV
    >   0 i ii iii
    >   3 iv v vi
    >   6 vii viii ix

=item C<-OI<[number]>>

like B<-o>, but use C<@A(RGV)> as loop variable.

=item C<-pI<[number]>>

I<Does C<pl -penis> do pussy?  B< >It implements C<cat>. :-*>

I<perl++:> On each loop C<print> (also B<-o> and B<-O>, in which case you must
fill C<$_>) iteration.  If number is given, print at most number times.

=item C<-PI<[number]>>

Like B<-p>, but print only if main program evaluates to true, like C<grep>.

=item C<-r>

Reset C<$.> and B<-p>/B<-P> counter for each file.

=item C<-T>

I<perl:> Enable tainting checks.

=item C<-t>

I<perl:> Enable tainting warnings.

=item C<-U>

I<perl:> Allow unsafe operations.



( run in 1.379 second using v1.01-cache-2.11-cpan-2398b32b56e )