Skip to content
Fetching contributors…
Cannot retrieve contributors at this time
executable file 37 lines (28 sloc) 931 Bytes
# Copyright 2012-2016, Paul Johnson (
# This software is free. It is licensed under the same terms as Perl itself.
# The latest version of this software should be available from my homepage:
use strict;
use warnings;
my $moddir = glob "~/.cpanm/work";
my $covdir = glob "~/cpancover";
my $lnkdir = "$covdir/modules";
my $resdir = "$covdir/results";
mkdir $covdir, 0750 unless -d $covdir;
mkdir $lnkdir, 0750 unless -d $lnkdir;
mkdir $resdir, 0750 unless -d $resdir;
for my $d (grep -d, <$moddir/*/*>) {
print "Linking $d\n";
my ($e) = $d =~ m|/([^/]+)$| or die "Can't find module name";
my $new = "$lnkdir/$e";
unlink $new if -e $new;
symlink $d => $new;
my $c;
$c .= "cpancover -directory $lnkdir -outputdir $resdir ";
$c .= "-outputfile index.html -report html_basic";
# $c .= " -force";
# $c .= " -redo_html";
print "running [$c]\n";
system $c;
Something went wrong with that request. Please try again.