pull-revu-source: Check for the availability of libwww-perl, and print a

more helpful error.
This commit is contained in:
Stefano Rivera 2011-02-13 15:29:15 +02:00
parent 3ab7f120da
commit ddf4bac12e
2 changed files with 10 additions and 2 deletions

4
debian/changelog vendored
View File

@ -13,8 +13,10 @@ ubuntu-dev-tools (0.117) UNRELEASED; urgency=low
qemu-user-static package, like Debian, since natty.
- Drop Build-Depend on Recommend on libapt-pkg-perl. No longer used.
* grab-merge: Show help when no arguments are provided.
* pull-revu-source: Check for the availability of libwww-perl, and print a
more helpful error.
-- Stefano Rivera <stefanor@ubuntu.com> Sun, 13 Feb 2011 15:03:36 +0200
-- Stefano Rivera <stefanor@ubuntu.com> Sun, 13 Feb 2011 15:28:18 +0200
ubuntu-dev-tools (0.116) unstable; urgency=low

View File

@ -21,7 +21,6 @@
use warnings;
use strict;
use File::Basename;
use LWP::Simple;
use Getopt::Long;
my $REVU = "revu.ubuntuwire.com";
@ -31,6 +30,13 @@ my($help)=0;
GetOptions('help' => \$help);
usage(0) if($help);
eval { require LWP::Simple; };
if ($@=~ m#^Can\'t locate LWP/Simple#) {
print(STDERR "Please install libwww-perl.\n");
exit(1);
}
use LWP::Simple;
dget(getURL());
sub getURL {