summaryrefslogtreecommitdiffstats
path: root/urpm/download.pm
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2005-03-10 14:29:10 +0000
committerRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2005-03-10 14:29:10 +0000
commit4f1973e21f577f0e908d722421f2c61135ab9704 (patch)
tree50965216473b349aff50d73b060ab96bb94a22e4 /urpm/download.pm
parent42e551c708aed332e1e76a5de7cccdb7362b3c58 (diff)
downloadurpmi-4f1973e21f577f0e908d722421f2c61135ab9704.tar
urpmi-4f1973e21f577f0e908d722421f2c61135ab9704.tar.gz
urpmi-4f1973e21f577f0e908d722421f2c61135ab9704.tar.bz2
urpmi-4f1973e21f577f0e908d722421f2c61135ab9704.tar.xz
urpmi-4f1973e21f577f0e908d722421f2c61135ab9704.zip
Add a retry option to urpmi and urpmi.cfg (bug #1174)
Diffstat (limited to 'urpm/download.pm')
-rw-r--r--urpm/download.pm3
1 files changed, 3 insertions, 0 deletions
diff --git a/urpm/download.pm b/urpm/download.pm
index bcbc9105..3ce9ffde 100644
--- a/urpm/download.pm
+++ b/urpm/download.pm
@@ -192,6 +192,7 @@ sub sync_wget {
($options->{limit_rate} ? "--limit-rate=$options->{limit_rate}" : ()),
($options->{resume} ? "--continue" : ()),
($options->{proxy} ? set_proxy({ type => "wget", proxy => $options->{proxy} }) : ()),
+ ($options->{retry} ? ('-t', $options->{retry}) : ()),
($options->{callback} ? ("--progress=bar:force", "-o", "-") :
$options->{quiet} ? "-q" : @{[]}),
"--retr-symlinks",
@@ -266,6 +267,7 @@ sub sync_curl {
open my $curl, join(" ", map { "'$_'" } "/usr/bin/curl",
($options->{limit_rate} ? ("--limit-rate", $options->{limit_rate}) : ()),
($options->{proxy} ? set_proxy({ type => "curl", proxy => $options->{proxy} }) : ()),
+ ($options->{retry} ? ('--retry', $options->{retry}) : ()),
"--stderr", "-", # redirect everything to stdout
"--disable-epsv",
"--connect-timeout", $CONNECT_TIMEOUT,
@@ -323,6 +325,7 @@ sub sync_curl {
($options->{limit_rate} ? ("--limit-rate", $options->{limit_rate}) : ()),
($options->{resume} ? ("--continue-at", "-") : ()),
($options->{proxy} ? set_proxy({ type => "curl", proxy => $options->{proxy} }) : ()),
+ ($options->{retry} ? ('--retry', $options->{retry}) : ()),
($options->{quiet} && !$options->{verbose} ? "-s" : @{[]}),
"-k",
$location_trusted ? "--location-trusted" : @{[]},