Module::CoreList - what modules shipped with versions of perl
use Module::CoreList;
print $Module::CoreList::version{5.00503}{CPAN}; # prints 1.48
print Module::CoreList->first_release('File::Spec'); # prints 5.00405
print Module::CoreList->first_release_by_date('File::Spec'); # prints 5.005
print Module::CoreList->first_release('File::Spec', 0.82); # prints 5.006001
print join ', ', Module::CoreList->find_modules(qr/Data/);
# prints 'Data::Dumper'
print join ', ', Module::CoreList->find_modules(qr/test::h.*::.*s/i, 5.008008);
# prints 'Test::Harness::Assert, Test::Harness::Straps'
print join ", ", @{ $Module::CoreList::families{5.005} };
# prints "5.005, 5.00503, 5.00504"
Module::CoreList provides information on which core and dual-life modules shipped with each version of perl.
It provides a number of mechanisms for querying this information.
There is a utility called corelist provided with this module which is a convenient way of querying from the command-line.
There is a functional programming API available for programmers to query information.
Programmers may also query the contained hash structures to find relevant information.
These are the functions that are available, they may either be called as functions or class methods:
Module::CoreList::first_release('File::Spec'); # as a function
Module::CoreList->first_release('File::Spec'); # class method
first_release( MODULE )
Behaviour since version 2.11
Requires a MODULE name as an argument, returns the perl version when that module first appeared in core as ordered by perl version number or undef ( in scalar context ) or an empty list ( in list context ) if that module is not in core.
first_release_by_date( MODULE )
Requires a MODULE name as an argument, returns the perl version when that module first appeared in core as ordered by release date or undef ( in scalar context ) or an empty list ( in list context ) if that module is not in core.
find_modules( REGEX, [ LIST OF PERLS ] )
Takes a regex as an argument, returns a list of modules that match the regex given. If only a regex is provided applies to all modules in all perl versions. Optionally you may provide a list of perl versions to limit the regex search.
find_version( PERL_VERSION )
Takes a perl version as an argument. Returns that perl version if it exists or undef
otherwise.