To run: perl script.pl $(cat list_of_modules.txt)
#!/usr/bin/perl
use strict;
use warnings;
foreach my $mod (@ARGV) {
(my $fn="$mod.pm")=~s|::|/|g; # Foo::Bar::Baz => Foo/Bar/Baz.pm
if (eval { require $fn; 1; }) {
print "Module $mod loaded ok\n";
} else {
print "Could not load $mod. Error Message: $@\n";
}
}
# Thanks Perl Monks
Also try typing perldoc perllocal to see a list of all installed modules.
A piggy bank of commands, fixes, succinct reviews, some mini articles and technical opinions from a (mostly) Perl developer.