bin/basepods

filter: Statementstmt 100% 16 / 16 Branchbran 75.0% 6 / 8 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 3 / 3 Podpod n/a totaltotal 92.5% 25 / 27 CC 1 SCAR 0.0
CC
1
Cov
92%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« bin/podpath ↑ Summary bin/modpods »
1 #!/usr/bin/env perl
2 # basepods - print out the standard perl*.pod manpages pod paths
3  
4 # ------ pragmas
5 5 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 5 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 5 ▶use Config;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 5 our $VERSION = '2.0.0';
10  
11 # ------ define variable
12 5 my $lib = undef; # standard POD library directory
13  
14 5 $lib = "$Config{'installprivlib'}/pods";
15 5 ▶$lib = "$Config{'installprivlib'}/pod" unless -d $lib;
Branch: 1 branch
BranchTrueFalseTotal
unless -d $lib 5 0 5
16  
17 5 ▶opendir(LIB, $lib) || die "$0: can't opendir $lib: $!\n";
Branch: 1 branch
BranchTrueFalseTotal
opendir LIB, $lib or die "$0: can't opendir ${lib}: $!\n" 5 0 5
18 5 ▶while ($_ = readdir(LIB)) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined($_ = readdir LIB)) 1155 5 1160
19 1155 ▶ print "$lib/$_\n" if /\.pod$/;
Branch: 1 branch
BranchTrueFalseTotal
if /\.pod$/ 1145 10 1155
20 }
21  
22 __END__
« bin/podpath ↑ Summary bin/modpods »