App-eachperl

 view release on metacpan or  search on metacpan

bin/eachperl  view on Meta::CPAN


Builds and tests the distribution in the current working directory, then
invokes perl on the remaining commandline. Remember to include C<-Mblib> to
instruct the perl to use the newly-built code

   $ eachperl build-then-perl -Mblib -MMy::Module -E'say My::Module::func()'

=head2 modversion

Prints the version of the named module.

   $ eachperl modversion CPAN
   perl5.30.0: 2.22
   bleadperl: 2.27

=head2 modpath

Prints the path to the named module.

   $ eachperl modpath CPAN
   perl5.30.0: /usr/share/perl/5.30/CPAN.pm
   bleadperl: /home/user/perl5/perlbrew/perls/bleadperl/lib/5.32.0/CPAN.pm

=head2 uninstall

Attempts to uninstall an installed module, by removing each of the files
listed in its F<.packlist> and the packlist itself.

   $ eachperl uninstall A::CPAN::Module

=head1 OPTIONS

=head2 --since VER

Selects only perl versions that are at least as new as the requested version.
Any perl binaries older than this will be skipped.

=head2 --until VER

Selects only perl versions that are at least as old as the requested version.
Any perl binaries newer than this will be skipped.

=head2 --ver VER

Selects only this exact perl version.

=head2 --devel, --no-devel

Selects only perl versions that are (or are not) development versions (i.e.
having an odd-numbered minor version).

=head2 --only-if EXPR

An additional perl expression that will be evaluated within the target perl
which must additionally return true, to select that perl version. If it
returns false then this version will be skipped.

The L<Config> module will already be loaded here; this is useful for
expressions like

   --only-if '$Config{usethreads}'

=head2 --reverse, -r

Reverses the order in which perl versions are invoked.

=head2 --stop-on-fail, -s

Stops running after the first failure. Without this option, every version is
attempted even if some fail.

Useful when combined with C<--reverse> to test a module to see how far back in
earlier perl versions it will support.

=head2 --no-system-perl

Deselects the system perl version. The perl version matching the system
version (or rather, the version running this script) is skipped.

=head2 --no-test

Skip the C<Build test> or C<make test> step when building a local
distribution.

=head1 CONFIG

The list of available perls is given by a config file, which is found in the
user's home directory at F<$HOME/.eachperlrc>. This should be a file in INI
format.

In addition, a file of the same name can be placed at the current working
directory (presumably the root directory of a project) to override any
settings in the main file.

The following keys are recognised

=head2 perls

A space-separated list of command names. Each should be searchable using
C<$PATH> but need not be specified as a fully-qualified path.

   perls = perl5.30.0 bleadperl

=head2 Default Commandline Options

Default values for the following commandline options can also be supplied:

   since_version = 5.16
   until_version = 5.30
   only_if = EXPR

=head1 AUTHOR

Paul Evans <leonerd@leonerd.org.uk>



( run in 0.563 second using v1.01-cache-2.11-cpan-39bf76dae61 )