diff options
Diffstat (limited to 'Master/texmf-dist/scripts')
-rw-r--r-- | Master/texmf-dist/scripts/texlive/tlmgrgui.pl | 50 |
1 files changed, 23 insertions, 27 deletions
diff --git a/Master/texmf-dist/scripts/texlive/tlmgrgui.pl b/Master/texmf-dist/scripts/texlive/tlmgrgui.pl index 25b7148d7b5..dbe760fdb4f 100644 --- a/Master/texmf-dist/scripts/texlive/tlmgrgui.pl +++ b/Master/texmf-dist/scripts/texlive/tlmgrgui.pl @@ -1897,7 +1897,8 @@ sub install_selected_packages { my @foo = SelectedPackages(); if (@foo) { # that doesn't hurt if it is already loaded - init_install_media(); + # it does hurt when there are critical updates ... so don't do it + #init_install_media(); my @args = qw/install/; push @args, @foo; execute_action_gui(@args); @@ -1927,6 +1928,21 @@ sub SelectedPackages { return @ret; } +sub critical_updates_done_msg_and_end { + # terminate here immediately so that we are sure the auto-updater + # is run immediately + # make sure we exit in finish(0) + $::gui_mode = 0; + # warn that program will now be terminated + $mw->Dialog(-title => __("Warning"), + -text => __("Critical updates have been installed.\nProgram will terminate now.\nPlease restart if necessary."), + -buttons => [ __("Ok") ])->Show; + # also delete the main window before we kill the process to + # make sure that Tk is happy (segfault on cmd line, email Taco) + $mw->destroy; + finish(0); +} + sub update_all_packages { my @args = qw/update/; if (@critical_updates) { @@ -1935,21 +1951,11 @@ sub update_all_packages { $opts{"all"} = 1; } # that doesn't hurt if it is already loaded - init_install_media(); + # it does hurt when there are critical updates ... so don't do it + #init_install_media(); execute_action_gui(qw/update/); if (@critical_updates) { - # terminate here immediately so that we are sure the auto-updater - # is run immediately - # make sure we exit in finish(0) - $::gui_mode = 0; - # warn that program will now be terminated - $mw->Dialog(-title => __("Warning"), - -text => __("Critical updates have been installed.\nProgram will terminate now.\nPlease restart if necessary."), - -buttons => [ __("Ok") ])->Show; - # also delete the main window before we kill the process to - # make sure that Tk is happy (segfault on cmd line, email Taco) - $mw->destroy; - finish(0); + critical_updates_done_msg_and_end(); } reinit_local_tlpdb(); } @@ -1958,7 +1964,8 @@ sub update_selected_packages { my @foo = SelectedPackages(); if (@foo) { # that doesn't hurt if it is already loaded - init_install_media(); + # it does hurt when there are critical updates ... so don't do it + #init_install_media(); my @args = qw/update/; # argument processing # in case we have critical updates present we do put the list of @@ -1969,18 +1976,7 @@ sub update_selected_packages { push @args, @foo; execute_action_gui(@args); if (@critical_updates) { - # terminate here immediately so that we are sure the auto-updater - # is run immediately - # make sure we exit in finish(0) - $::gui_mode = 0; - # warn that program will now be terminated - $mw->Dialog(-title => __("Warning"), - -text => __("Critical updates have been installed.\nProgram will terminate now.\nPlease restart if necessary."), - -buttons => [ __("Ok") ])->Show; - # also delete the main window before we kill the process to - # make sure that Tk is happy (segfault on cmd line, email Taco) - $mw->destroy; - finish(0); + critical_updates_done_msg_and_end(); } reinit_local_tlpdb(); } |