[Pkg-haskell-commits] [package-plan] 127/457: Analyze cabal-install output
Joachim Breitner
nomeata at moszumanska.debian.org
Mon Apr 14 20:05:18 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 0beae37f0d1452c9d3a95b8da21b5eff37d5cf13
Author: Joachim Breitner <mail at joachim-breitner.de>
Date: Sat Jun 15 11:17:12 2013 +0000
Analyze cabal-install output
---
test-packages.pl | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/test-packages.pl b/test-packages.pl
index 1a888d4..1a4a227 100644
--- a/test-packages.pl
+++ b/test-packages.pl
@@ -9,6 +9,7 @@ use File::Copy;
use Archive::Tar;
use File::Slurp;
use Text::Patch;
+use IPC::Run qw( run );
my %packages;
my %versions;
@@ -172,7 +173,21 @@ for my $pkg (sort keys %versions) {
}
print "Running cabal-install...\n";
-(system @params) == 0 or die "cabal install failed: $?";
+my $out;
+my $err;
+run \@params, \"", \$out, \$err or die "cabal install failed: $?";
+
+while ($out =~ m!^([a-zA-H0-9-]+)-([0-9.]+)$!gm) {
+ my ($pkg, $version) = ($1, $2);
+ unless (exists $versions{$pkg}) {
+ printf "Additional dependency pulled in: %s-%s\n", $pkg, $version;
+ next
+ }
+ unless ($versions{$pkg} eq $version) {
+ printf "ERROR: %s has %s but should have %\n", $pkg, $version, $versions{$pkg};
+ next
+ }
+}
system("rm -rf cabal-sandbox");
--
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