summaryrefslogtreecommitdiffstats
path: root/preps/perl
diff options
context:
space:
mode:
authorJustin Davis <jrcd83@gmail.com>2013-04-11 22:59:33 +0200
committerJustin Davis <jrcd83@gmail.com>2013-04-11 22:59:33 +0200
commit6d8daba2b1f377b59a3ffa0a55b6429703eb9672 (patch)
treed856674d13b6932d522ddd60060b3afdcdcfde3e /preps/perl
parentea8184012874f11d4ef9eed6e7fcc8cd5a1bf848 (diff)
downloadgenpkg-6d8daba2b1f377b59a3ffa0a55b6429703eb9672.tar.gz
genpkg-6d8daba2b1f377b59a3ffa0a55b6429703eb9672.tar.xz
Better error reporting if sync with CPAN fails.
Diffstat (limited to 'preps/perl')
-rwxr-xr-xpreps/perl5
1 files changed, 2 insertions, 3 deletions
diff --git a/preps/perl b/preps/perl
index 5e88b06..90f33d4 100755
--- a/preps/perl
+++ b/preps/perl
@@ -25,12 +25,11 @@ sub matchdist
or err('PKGVAR env variable is unset');
if(!-f "$var/cpan.dists" || -M "$var/cpan.dists" > 1) {
- print STDERR "$PROG: Refreshing local CPAN data... ";
+ print STDERR "$PROG: Refreshing local CPAN data.\n";
my $cwd = getcwd();
chdir $var or die "chdir: $!";
system 'fetchcpan';
- die "FAILED\n" unless($? == 0);
- print STDERR "OK\n";
+ exit 1 unless($? == 0);
chdir $cwd or die "chdir: $!";
}