summaryrefslogtreecommitdiffstats
path: root/perl-install/any.pm
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install/any.pm')
-rw-r--r--perl-install/any.pm9
1 files changed, 8 insertions, 1 deletions
diff --git a/perl-install/any.pm b/perl-install/any.pm
index ee5322d79..e5d62371f 100644
--- a/perl-install/any.pm
+++ b/perl-install/any.pm
@@ -841,7 +841,7 @@ sub sessions_with_order() {
}
sub urpmi_add_all_media {
- my ($in) = @_;
+ my ($in, $o_previous_release) = @_;
my $binary = find { whereis_binary($_, $::prefix) } 'gurpmi.addmedia', 'urpmi.addmedia' or return;
@@ -855,6 +855,13 @@ sub urpmi_add_all_media {
mygtk2::destroy_previous_popped_and_reuse_window();
mygtk2::flush();
}
+
+ my $reason = join(',', $o_previous_release ?
+ ('reason=upgrade', 'upgrade_by=drakx', "upgrade_from=$o_previous_release->{version}") :
+ 'reason=install');
+ log::l("URPMI_ADDMEDIA_REASON $reason");
+ local $ENV{URPMI_ADDMEDIA_REASON} = $reason;
+
run_program::rooted($::prefix, $binary, '--distrib', '--mirrorlist', '$MIRRORLIST');
}