diff options
Diffstat (limited to 'Master/tlpkg/installer/install-menu-text.pl')
-rwxr-xr-x | Master/tlpkg/installer/install-menu-text.pl | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/Master/tlpkg/installer/install-menu-text.pl b/Master/tlpkg/installer/install-menu-text.pl index 5f4c4e07b55..59cc7d3e0ef 100755 --- a/Master/tlpkg/installer/install-menu-text.pl +++ b/Master/tlpkg/installer/install-menu-text.pl @@ -2,7 +2,7 @@ # $Id$ # install-menu-txt.pl # -# Copyright 2007, 2008, 2009, 2010 Norbert Preining, Karl Berry +# Copyright 2007, 2008, 2009, 2010, 2011 Norbert Preining, Karl Berry # Copyright 2007, 2008 Reinhard Kotucha # This file is licensed under the GNU General Public License version 2 # or any later version. @@ -117,7 +117,7 @@ sub run_menu_text { # network is always available my @mirror_list = TeXLive::TLUtils::create_mirror_list(); print "Please select a repository:\n"; - print "Network repositories:\n" if ($#media_available >= 0); + print "Network repositories:" if ($#media_available >= 0); my @sel_to_index; my $selind = 0; # this is for 0 mirror.ctan.org, but it is printed last! @@ -125,18 +125,19 @@ sub run_menu_text { $selind++; for my $i (0..$#mirror_list) { if ($mirror_list[$i] !~ m/^ /) { - print "$mirror_list[$i]\n"; + print "\n$mirror_list[$i]\n"; } else { + print " " if 1 <= $selind && $selind <= 9; # align print "[$selind] $mirror_list[$i]\n"; push @sel_to_index, $i; $selind++; } } - print "---\n"; + print "----\n"; print "[0] default mirror - http://mirror.ctan.org\n"; my $local_ind = "a"; if ($#media_available >= 0) { - print "Locally present repositories:\n"; + print "Local repositories:\n"; # we have some local media present, propose to use it for my $l (@media_available) { my ($a, $b) = split ('#', $l); @@ -154,7 +155,7 @@ sub run_menu_text { $default = $local_ind; $local_ind++; } else { - printf STDERR "Unknown media $l\n"; + warn "$0: Unknown media $l"; } } } @@ -180,7 +181,7 @@ sub run_menu_text { print $selstr; $ans = readline(*STDIN); if (!defined($ans)) { - print "Please select 'q' for quitting the program!\n"; + print "Please select `q' to quit the program!\n"; } else { chomp($ans); $ans = $default if ($ans eq ""); @@ -203,10 +204,10 @@ sub run_menu_text { $t =~ s/^[^#]*#//; $::init_remote_needed = $t; } elsif ($ans eq 'q' || $ans eq 'Q') { - print "Good bye.\n"; + print "Goodbye.\n"; exit 0; } else { - print "Not a valid answer.\n"; + print "Not a valid answer: $ans.\n"; $ans = undef; } } |