aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2009-02-10 10:55:29 +0000
committerThierry Vignaud <tv@mandriva.org>2009-02-10 10:55:29 +0000
commit698e91d16f47f4674d81f116ecf9f648dac34fc5 (patch)
treefa8fca891449f4ef3f63612c79528781309c043c
parentac4d2d5030cae6b95e1aeb574d28b8a69df148e6 (diff)
downloadrpmdrake-698e91d16f47f4674d81f116ecf9f648dac34fc5.tar
rpmdrake-698e91d16f47f4674d81f116ecf9f648dac34fc5.tar.gz
rpmdrake-698e91d16f47f4674d81f116ecf9f648dac34fc5.tar.bz2
rpmdrake-698e91d16f47f4674d81f116ecf9f648dac34fc5.tar.xz
rpmdrake-698e91d16f47f4674d81f116ecf9f648dac34fc5.zip
(perform_installation) implement 'need_restart' so that we warn when rebooting
is needed after installing packages
-rw-r--r--NEWS1
-rw-r--r--Rpmdrake/pkg.pm7
2 files changed, 7 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index 454bbaa1..40e88e3f 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,7 @@
- MandrivaUpdate:
o use new proper API to select media, thus fixing not updating media
(side effect of urpmi API changes, #47209)
+ o warn when rebooting is needed after installing packages
Version 5.0.4 - 9 December 2008, Thierry Vignaud
diff --git a/Rpmdrake/pkg.pm b/Rpmdrake/pkg.pm
index 80e104ec..d7e429aa 100644
--- a/Rpmdrake/pkg.pm
+++ b/Rpmdrake/pkg.pm
@@ -722,7 +722,7 @@ sub perform_installation { #- (partially) duplicated from /usr/sbin/urpmi :-(
};
my $exit_code =
- urpm::main_loop::run($urpm, $state, undef, undef, $requested,
+ urpm::main_loop::run($urpm, $state, 1, undef, $requested,
{
completed => sub {
# explicitly destroy the progress window when it's over; we may
@@ -803,6 +803,11 @@ sub perform_installation { #- (partially) duplicated from /usr/sbin/urpmi :-(
scroll => 1,
);
},
+ need_restart => sub {
+ my ($need_restart_formatted) = @_;
+ interactive_msg(N("Warning"),
+ join("\n\n", values %$need_restart_formatted));
+ },
success_summary => sub {
if (!($done || @to_remove)) {
interactive_msg(N("Error"),