summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2008-10-16 09:16:11 +0000
committerPascal Rigaux <pixel@mandriva.com>2008-10-16 09:16:11 +0000
commitfed9ca0197135dda347e2da9e34c56afaa0478db (patch)
tree6f6ebce3ff265decc809b56b58e2000fca3cc78b
parent421e054d011bcf0fe5cc31c7324dc2e170202de5 (diff)
downloadurpmi-fed9ca0197135dda347e2da9e34c56afaa0478db.tar
urpmi-fed9ca0197135dda347e2da9e34c56afaa0478db.tar.gz
urpmi-fed9ca0197135dda347e2da9e34c56afaa0478db.tar.bz2
urpmi-fed9ca0197135dda347e2da9e34c56afaa0478db.tar.xz
urpmi-fed9ca0197135dda347e2da9e34c56afaa0478db.zip
- gurpmi
o display the download errors (backported from trunk)
-rw-r--r--NEWS3
-rwxr-xr-xgurpmi27
2 files changed, 9 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index 873af1cd..29a1b1b2 100644
--- a/NEWS
+++ b/NEWS
@@ -1,7 +1,8 @@
Version 6.14.6 - 15 October 2008
- gurpmi
- o display all urpmi logs
+ o display the download errors
+ o log all urpmi logs
Version 6.14.5 - 15 October 2008
diff --git a/gurpmi2 b/gurpmi2
index 51db1e34..a981363f 100755
--- a/gurpmi2
+++ b/gurpmi2
@@ -136,6 +136,10 @@ sub configure_urpm() {
$urpm->{error} = sub {
my ($message) = @_;
printf STDERR "%s\n", $message;
+
+ if (my $download_errors = delete $urpm->{download_errors}) {
+ $message = join("\n", @$download_errors, $message);
+ }
my $nb_lines = $message =~ tr/\n/\n/;
my $w;
if ($nb_lines > 30) {
@@ -337,6 +341,9 @@ sub do_install_3 () {
$set_progressbar->($percent / 100);
} elsif ($mode eq 'end') {
$set_progressbar->(1);
+ } elsif ($mode eq 'error') {
+ #- error is 3rd argument, saved in $percent
+ push @{$urpm->{download_errors}}, N("...retrieving failed: %s", $percent);
}
sync();
},