[Pkg-haskell-commits] darcs: tools: Let test-packages report obsolete packages
Joachim Breitner
mail at joachim-breitner.de
Fri Mar 7 12:43:01 UTC 2014
Fri Mar 7 12:42:37 UTC 2014 Joachim Breitner <mail at joachim-breitner.de>
* Let test-packages report obsolete packages
M ./all-packages/packages.txt -1 +3
M ./all-packages/test-packages.pl -5 +16
Fri Mar 7 12:42:37 UTC 2014 Joachim Breitner <mail at joachim-breitner.de>
* Let test-packages report obsolete packages
diff -rN -u old-tools/all-packages/packages.txt new-tools/all-packages/packages.txt
--- old-tools/all-packages/packages.txt 2014-03-07 12:43:01.031707483 +0000
+++ new-tools/all-packages/packages.txt 2014-03-07 12:43:01.035707483 +0000
@@ -138,7 +138,7 @@
data-lens 2.10.4
data-memocombinators 0.4.4
data-pprint 0.2.3
-date-cache 0.3.0
+date-cache 0.3.0 obsolete
datetime 0.2.1
DAV 0.6.1
dbus 0.10.4
@@ -616,6 +616,7 @@
time-compat 0.1.0.1
TinyURL 0.1.0
tls 1.2.2
+tls-extra 0.6.6 obsolete
tokyocabinet-haskell 0.0.5
transformers 0.3.0.0
transformers-base 0.4.1
@@ -655,6 +656,7 @@
wai-handler-launch 2.0.0
wai-handler-scgi 2.0.0
wai-logger 2.1.1
+wai-logger-prefork 0.3.0 obsolete
wai-test 2.0.0.1
wai-websockets 2.0.0.1
warp 2.0.3.2
diff -rN -u old-tools/all-packages/test-packages.pl new-tools/all-packages/test-packages.pl
--- old-tools/all-packages/test-packages.pl 2014-03-07 12:43:01.031707483 +0000
+++ new-tools/all-packages/test-packages.pl 2014-03-07 12:43:01.099707482 +0000
@@ -19,6 +19,7 @@
my %comments;
my %notest;
my %binary;
+my %obsolete;
my @flags;
my $allow_upgrade = 0;
@@ -38,6 +39,10 @@
}
my ($pkg,$version,$comment) = ($1,$2,$3);
$packages{$pkg}++;
+ if ($comment and $comment =~ s/obsolete\s*//) {
+ $obsolete{$pkg}++;
+ next;
+ }
$versions{$pkg} = $version;
next unless $comment;
$notest{$pkg}++ if $comment =~ s/notest\s*//;
@@ -77,17 +82,23 @@
print "Checking for outdated entries...\n";
for my $pkg (sort keys %packages) {
- if (! exists($versions{$pkg})) {
- printf "MISSING: %s %s\n" ,
+ if ($obsolete{$pkg} && $available{$pkg}) {
+ printf "Obsolete: %s %s\n" ,
+ $pkg, $available{$pkg};
+ } elsif ($obsolete{$pkg} && !$available{$pkg}) {
+ printf "REMOVED: %s %s\n" ,
+ $pkg, $available{$pkg};
+ } elsif (! exists($versions{$pkg})) {
+ printf "MISSING: %s %s\n" ,
$pkg, $available{$pkg};
} elsif (! exists($available{$pkg})) {
- printf "Added: %s is %s here but does not exist in the archive.\n" ,
+ printf "Added: %s is %s here but does not exist in the archive.\n" ,
$pkg, $versions{$pkg};
} elsif ( version_compare($versions{$pkg}, $available{$pkg}) == -1 ) {
- printf "OLD: %s is %s here but %s exists in the archive.\n" ,
+ printf "OLD: %s is %s here but %s exists in the archive.\n" ,
$pkg, $versions{$pkg}, $available{$pkg};
} elsif ( version_compare($versions{$pkg}, $available{$pkg}) == 1 ) {
- printf "Updated: %s is %s in the archive but %s exists here.\n" ,
+ printf "Updated: %s is %s in the archive but %s exists here.\n" ,
$pkg, $available{$pkg}, $versions{$pkg};
}
}
More information about the Pkg-haskell-commits
mailing list