What modules are distributed with Perl?

前端 未结 8 1516
误落风尘
误落风尘 2021-02-13 20:00

How do I know what modules are distributed with Perl?

My first guess is that the core modules listed here are always included, though I cannot find this stated explicitl

8条回答
  •  野趣味
    野趣味 (楼主)
    2021-02-13 20:33

    Module::CoreList has already been mentioned. It comes with a command-line interface to make things easy. It's great if you have it installed already, or have a program that needs to figure out what may not come with a particular version of Perl.

    If you want to know what modules come with your particular version of perl, you can run perldoc perlmodlib on the command line for a complete list. For older or newer versions of Perl, you can just go to Perl's page on the CPAN and select the version you want (eg, 5.6.2) from the drop-down, and then navigate to the perlmodlib page in the documentation. (typing perlmodlib into your browser's text search will help).

    If you're thinking of not using a module because it's not core on an older version of Perl, then you may wish to consider using PAR, the Perl Archiver, to bundle your extra dependencies, or even Perl itself! Perl Training Australia also has a Perl Tip on using PAR which covers the basics on getting started with PAR.

    All the very best,

    Paul

提交回复
热议问题