summaryrefslogtreecommitdiffstats
path: root/urpmi.addmedia
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.org>2004-01-26 22:20:57 +0000
committerOlivier Blin <oblin@mandriva.org>2004-01-26 22:20:57 +0000
commitc9fdb6d4e5b72adba69f81692ee12c2e20366a85 (patch)
tree927d0f51c84340976d6ae781f31aba59eca43835 /urpmi.addmedia
parent80f4f65fcc51e585aa165e95710b37194b5ae5a3 (diff)
downloadurpmi-c9fdb6d4e5b72adba69f81692ee12c2e20366a85.tar
urpmi-c9fdb6d4e5b72adba69f81692ee12c2e20366a85.tar.gz
urpmi-c9fdb6d4e5b72adba69f81692ee12c2e20366a85.tar.bz2
urpmi-c9fdb6d4e5b72adba69f81692ee12c2e20366a85.tar.xz
urpmi-c9fdb6d4e5b72adba69f81692ee12c2e20366a85.zip
add downloader option in global config section
Diffstat (limited to 'urpmi.addmedia')
-rwxr-xr-xurpmi.addmedia7
1 files changed, 2 insertions, 5 deletions
diff --git a/urpmi.addmedia b/urpmi.addmedia
index caecc345..5e0f3f38 100755
--- a/urpmi.addmedia
+++ b/urpmi.addmedia
@@ -90,11 +90,8 @@ and [options] are from
/^--?h$/ and next;
/^--?f$/ and ++$options{force}, next;
/^--?z$/ and ++$options{compress}, next;
- /^--wget$/ and $urpm->{sync} = sub { my $options = shift @_;
- if (ref $options) { $options->{prefer} = 'wget' }
- else { $options = { dir => $options, prefer => 'wget' } }
- urpm::sync_webfetch($options, @_) }, next;
- /^--curl$/ and $urpm->{sync} = \&urpm::sync_webfetch, next;
+ /^--wget$/ and $urpm->{options}{downloader} = 'wget', next;
+ /^--curl$/ and $urpm->{options}{downloader} = 'curl', next;
/^--limit-rate$/ and do { $options{limit_rate} = shift @_; next };
/^--proxy$/ and do {
my ($proxy, $port) = ($_ = shift @_) =~ m,^(?:http://)?([^:]+(:\d+)?)/*$, or