summaryrefslogtreecommitdiffstats
path: root/urpm/download.pm
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2004-11-24 13:19:40 +0000
committerRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2004-11-24 13:19:40 +0000
commitd0975a4dc82a25a2f1e2105e9c405fcaf067bdfa (patch)
treea316b6b26c60105ff8d62140d59eb8b1b79cfe64 /urpm/download.pm
parent4e3a4d308ebedc84d154d8c55e10f9eeb8d754fc (diff)
downloadurpmi-d0975a4dc82a25a2f1e2105e9c405fcaf067bdfa.tar
urpmi-d0975a4dc82a25a2f1e2105e9c405fcaf067bdfa.tar.gz
urpmi-d0975a4dc82a25a2f1e2105e9c405fcaf067bdfa.tar.bz2
urpmi-d0975a4dc82a25a2f1e2105e9c405fcaf067bdfa.tar.xz
urpmi-d0975a4dc82a25a2f1e2105e9c405fcaf067bdfa.zip
When invoking urpmi.addmedia with --proxy, save this proxy setting for
this particular new media. (bug 12483)
Diffstat (limited to 'urpm/download.pm')
-rw-r--r--urpm/download.pm11
1 files changed, 11 insertions, 0 deletions
diff --git a/urpm/download.pm b/urpm/download.pm
index 7078fb11..03aa341b 100644
--- a/urpm/download.pm
+++ b/urpm/download.pm
@@ -88,6 +88,17 @@ sub get_proxy (;$) {
};
}
+#- copies the settings for proxies from the command line to media named $media
+#- and writes the proxy.cfg file (used for new media)
+sub copy_cmd_line_proxy {
+ my ($media) = @_;
+ return unless $media;
+ if (defined $proxy_config->{cmd_line}) {
+ $proxy_config->{$media} = $proxy_config->{cmd_line};
+ dump_proxy_config();
+ }
+}
+
#- overrides the config file proxy settings with values passed via command-line
sub set_cmdline_proxy {
my (%h) = @_;