[Pkg-haskell-commits] [package-plan] 75/457: Show missing entries
Joachim Breitner
nomeata at moszumanska.debian.org
Mon Apr 14 20:05:12 UTC 2014
This is an automated email from the git hooks/post-receive script.
nomeata pushed a commit to branch master
in repository package-plan.
commit 29c062a32af8856f92d9f3cc1c453628c8912fad
Author: Joachim Breitner <mail at joachim-breitner.de>
Date: Sun May 26 10:06:12 2013 +0000
Show missing entries
---
test-packages.pl | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/test-packages.pl b/test-packages.pl
index 37855bf..eb4e96b 100644
--- a/test-packages.pl
+++ b/test-packages.pl
@@ -5,6 +5,7 @@ use warnings;
use version;
+my %packages;
my %versions;
my %available;
my %comments;
@@ -18,6 +19,7 @@ while (<PACKAGES>) {
unless (m/^(.*?) (.*?)(?: (.*))?$/) {
print "Ignoring unparseable line $.: $_\n";
}
+ $packages{$1}++;
$versions{$1} = $2;
$comments{$1} = $3 if $3;
}
@@ -31,13 +33,20 @@ while (<AVAILABLE>) {
print "Ignoring unparseable grep-aptavail output line $.: $_\n";
}
$available{$1} = $2;
+ $packages{$1}++;
}
close AVAILABLE;
print "Checking for outdated entries...\n";
-for my $pkg (keys %versions) {
- if ( version->parse($versions{$pkg}) < version->parse($available{$pkg}) ) {
+for my $pkg (sort keys %packages) {
+ if (! exists($versions{$pkg})) {
+ printf "Missing entry: %s %s\n" ,
+ $pkg, $available{$pkg};
+ } elsif (! exists($versions{$pkg})) {
+ printf "%s is %s here but does not exist in the archive.\n" ,
+ $pkg, $versions{$pkg};
+ } elsif ( version->parse($versions{$pkg}) < version->parse($available{$pkg}) ) {
printf "%s is %s here but %s exists in the archive.\n" ,
$pkg, $versions{$pkg}, $available{$pkg};
}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-haskell/package-plan.git
More information about the Pkg-haskell-commits
mailing list