my $Version = "BugCount 1.1\nCopyright (C) Wichert Akkerman <wakkerma\@debian.org>\n";
my $statusfile = "status";
-my $commentsfile = "comments";
sub ShowVersion() {
print "$Version\n";
-V show version
-h show some (hopefully) helpfull information
-S use different statusfile
- -C use different commentsfile
EOF
exit 0;
}
-our ($opt_h,$opt_V,$opt_S,$opt_C);
+our ($opt_h,$opt_V,$opt_S);
-getopts('VhS:C:');
+getopts('VhS:');
ShowUsage if ($opt_h);
ShowVersion if ($opt_V);
$statusfile=$opt_S if ($opt_S);
-$commentsfile=$opt_C if ($opt_C);
scanlib::readstatus($statusfile);
-scanlib::readcomments($commentsfile);
my $total=0; # total number of bugs
my $patchcount=0; # Number of bugs that have a fix proposed
my $ignorecount=0; # Number of bugs being ignored
my $nottestingcount=0; # Number of bugs on packages not in testing
my $worrycount=0; # Number of bugs we're actually worried about
-my %sectcount=(); # Bugs per type
for my $p (keys %scanlib::packagelist) {
next if (defined $bugcfg::exclude{$p});
$patchcount++ if ($scanlib::bugs{$nr} =~ m/^\[[^]]*\+/);
$ignorecount++ if ($scanlib::bugs{$nr} =~ m/^\[[^]]*I/);
$nottestingcount++ if ($scanlib::bugs{$nr} =~ m/ \[[^]]*X/);
- if (defined $scanlib::comments{$nr}) {
- my $sect = ($scanlib::comments{$nr} =~ m/\[([^]]*)\]/);
- $sectcount{$sect}++;
- }
$worrycount++ if (scanlib::check_worry($scanlib::bugs{$nr}));
}
}