in reply to pp bleach main script and modules

What about -F, --modfilter=FILTER[=REGEX] ?

from pp

-f, --filter=FILTER

Filter source script(s) with a PAR::Filter subclass. You may specify multiple such filters.

If you wish to hide the source code from casual prying, this will do:

% pp -f Bleach source.pl

If you are more serious about hiding your source code, you should have a look at Steve Hay'sPAR::Filter::Crypto module. Make sure you understand the Filter::Crypto caveats!

...

-F, --modfilter=FILTER[=REGEX]

Filter included perl module(s) with a PAR::Filter subclass. You may specify multiple such filters.

By default, the PodStrip filter is applied. In case that causes trouble, you can turn this off by setting the environment variable PAR_VERBATIM to 1.

Since PAR 0.958, you can use an optional regular expression (REGEX above) to select the files in the archive which should be filtered. Example:

pp -o foo.exe -F Bleach=warnings\.pm$ foo.pl

This creates a binary executable foo.exe from foo.pl packaging all files as usual except for files ending inwarnings.pm which are filtered with PAR::Filter::Bleach

Cheers Rolf
(addicted to the Perl Programming Language and ☆☆☆☆ :)
Wikisyntax for the Monastery

Replies are listed 'Best First'.
Re^2: pp bleach main script and modules
by Anonymous Monk on May 25, 2018 at 07:53 UTC

    Cheers, it works.