script/podtree2html

filter: Statementstmt 100% 31 / 31 Branchbran 66.6% 4 / 6 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 5 / 5 Podpod n/a totaltotal 95.2% 40 / 42 CC 1 SCAR 0.0
CC
1
Cov
95%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« lib/Pod/Tree/BitBucket.pm ↑ Summary
1 #!/usr/local/bin/perl
2  
3 18 ▶use 5.006;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 18 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 18 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 18 ▶use Getopt::Long;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 18 ▶use Pod::Tree::HTML;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 18 my %Options;
10 18 $Options{toc} = 1;
11 18 my $ok = GetOptions( \%Options, "base:s", "css:s", "toc!", "hr:i", "bgcolor:s", "text:s", "variables:s" );
12 18 ▶$ok or die "Bad command line options\n";
Branch: 1 branch
BranchTrueFalseTotal
$ok or die "Bad command line options\n" 18 0 18
13  
14 18 umask 0022;
15  
16 18 ▶@ARGV < 2 and die "podtree2html PODfile HTMLfile [templateFile]\n";
Branch: 1 branch
BranchTrueFalseTotal
@ARGV < 2 and die "podtree2html PODfile HTMLfile [templateFile]\n" 0 18 18
17 18 my ( $source, $dest, $template, @variables ) = @ARGV;
18 18 my $html = Pod::Tree::HTML->new( $source, $dest );
19 18 $html->set_options(%Options);
20  
21 18 ▶do $Options{variables} if $Options{variables};
Branch: 1 branch
BranchTrueFalseTotal
if $Options{"variables"} 12 6 18
22  
23 18 for (@variables) {
24 6 chomp;
25 6 my ( $name, $value ) = split /=/, $_, 2;
26 6 $name =~ s(^\$)();
27 6 ${ $Pod::Tree::HTML::{$name} } = $value;
28 }
29  
30 18 $html->translate($template);
31  
32 __END__
« lib/Pod/Tree/BitBucket.pm ↑ Summary