summaryrefslogtreecommitdiff
path: root/Master/tlpkg
diff options
context:
space:
mode:
authorNorbert Preining <preining@logic.at>2017-04-16 02:13:17 +0000
committerNorbert Preining <preining@logic.at>2017-04-16 02:13:17 +0000
commit6953459a76c7d73e4cd1a2bfb57878c8f66e98fb (patch)
treec70ac38cf6a90f66d4ef3242e7dc4a08415ee13a /Master/tlpkg
parent219afd32966778a9ba24a031a7a820c3288b4eba (diff)
more variable standardization for installer options
we now use instopt_ as prefix for installer only options that are not saved into the TLPDB. git-svn-id: svn://tug.org/texlive/trunk@43824 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg')
-rw-r--r--Master/tlpkg/installer/install-menu-perltk.pl40
-rw-r--r--Master/tlpkg/installer/install-menu-text.pl76
-rw-r--r--Master/tlpkg/installer/install-menu-wizard.pl8
-rw-r--r--Master/tlpkg/installer/installer-options.txt8
4 files changed, 66 insertions, 66 deletions
diff --git a/Master/tlpkg/installer/install-menu-perltk.pl b/Master/tlpkg/installer/install-menu-perltk.pl
index fd3cf112309..8f6a6ea3e88 100644
--- a/Master/tlpkg/installer/install-menu-perltk.pl
+++ b/Master/tlpkg/installer/install-menu-perltk.pl
@@ -127,18 +127,18 @@ $::run_menu = \&run_menu_perltk;
# ##################################################################
sub setup_perltk_local_strings {
- $portableyesno = $::yesno[$vars{'portable'}];
- $letteryesno = $::letterdesc[$vars{'option_letter'}];
- $fmtyesno = $::yesno[$vars{'option_fmt'}];
- $srcyesno = $::yesno[$vars{'option_src'}];
+ $portableyesno = $::yesno[$vars{'instopt_portable'}];
+ $letteryesno = $::letterdesc[$vars{'instopt_letter'}];
+ $fmtyesno = $::yesno[$vars{'option_create_formats'}];
+ $srcyesno = $::yesno[$vars{'option_install_srcfiles'}];
$deskintyesno = $::deskintdesc[$vars{'option_desktop_integration'}];
$pathadjyesno = $::yesno[$vars{'option_path'}];
$fileassocyesno = $::fileassocdesc[$vars{'option_file_assocs'}];
$editoryesno = $::yesno[$vars{'collection-texworks'}];
$adminallyesno = $::yesno[$vars{'option_w32_multi_user'}];
- $docyesno = $::yesno[$vars{'option_doc'}];
+ $docyesno = $::yesno[$vars{'option_install_docfiles'}];
$restrictedyesno = $::yesno[$vars{'option_write18_restricted'}];
- $adjustrepoyesno = $::yesno[$vars{'adjustrepo'}];
+ $adjustrepoyesno = $::yesno[$vars{'instopt_adjustrepo'}];
}
sub menu_abort {
@@ -442,7 +442,7 @@ Please select a different mirror.',
-command => sub { menu_edit_vars_value("TEXMFHOME"); })
->grid(-row => $row, -column => 3, -sticky => "ew", -padx => "2m");
- if ($vars{'portable'}) {
+ if ($vars{'instopt_portable'}) {
for my $b (
$tmflocalbutton, $tmfsysvarbutton, $tmfsysconfigbutton, $tmfhomebutton) {
$b->configure(-state => 'disabled')
@@ -464,7 +464,7 @@ Please select a different mirror.',
-text => __("Toggle"),
-command => sub {
toggle_and_set_opt_variable(
- \$vars{'option_letter'}, \$letteryesno, \@::letterdesc); })
+ \$vars{'instopt_letter'}, \$letteryesno, \@::letterdesc); })
->grid(-row => $row, -column => 3, -sticky => "ew", -padx => "2m");
$row++;
@@ -491,7 +491,7 @@ Please select a different mirror.',
$format_toggle_button = $fr->Button(
-text => __("Toggle"),
-command => sub {
- toggle_and_set_opt_variable(\$vars{'option_fmt'}, \$fmtyesno); })
+ toggle_and_set_opt_variable(\$vars{'option_create_formats'}, \$fmtyesno); })
->grid(-row => $row, -column => 3, -sticky => "ew", -padx => "2m");
if ($vars{'doc_splitting_supported'} and !$opt_in_place) {
@@ -503,7 +503,7 @@ Please select a different mirror.',
$doc_files_toggle_button = $fr->Button(
-text => __("Toggle"),
-command => sub {
- toggle_and_set_opt_variable(\$vars{'option_doc'}, \$docyesno); })
+ toggle_and_set_opt_variable(\$vars{'option_install_docfiles'}, \$docyesno); })
->grid(-row => $row, -column => 3, -sticky => "ew", -padx => "2m");
}
@@ -516,7 +516,7 @@ Please select a different mirror.',
$src_files_toggle_button = $fr->Button(
-text => __("Toggle"),
-command => sub {
- toggle_and_set_opt_variable(\$vars{'option_src'}, \$srcyesno); })
+ toggle_and_set_opt_variable(\$vars{'option_install_srcfiles'}, \$srcyesno); })
->grid(-row => $row, -column => 3, -sticky => "ew", -padx => "2m");
}
@@ -605,11 +605,11 @@ Please select a different mirror.',
-text => __("Toggle"),
-command => sub {
toggle_and_set_opt_variable(
- \$vars{'adjustrepo'}, \$adjustrepoyesno); })
+ \$vars{'instopt_adjustrepo'}, \$adjustrepoyesno); })
->grid(-row => $row, -column => 3, -sticky => "ew", -padx => "2m");
}
- if ($vars{'portable'}) {
+ if ($vars{'instopt_portable'}) {
for $b ($pathbutton, $deskintbutton, $assocbutton, $adminbutton) {
$b->configure(-state => 'disabled') if $b;
}
@@ -1151,10 +1151,10 @@ sub menu_update_texts {
menu_set_collections_text;
menu_set_binbutton_text;
menu_set_schemebutton_text;
- $optletterstate = $::letterdesc[$vars{'option_letter'}];
- $optfmtstate = ($vars{'option_fmt'} ? __("Yes") : __("No"));
- $optsrcstate = ($vars{'option_src'} ? __("Yes") : __("No"));
- $optdocstate = ($vars{'option_doc'} ? __("Yes") : __("No"));
+ $optletterstate = $::letterdesc[$vars{'instopt_letter'}];
+ $optfmtstate = ($vars{'option_create_formats'} ? __("Yes") : __("No"));
+ $optsrcstate = ($vars{'option_install_srcfiles'} ? __("Yes") : __("No"));
+ $optdocstate = ($vars{'option_install_docfiles'} ? __("Yes") : __("No"));
}
sub callback_select_scheme {
@@ -1232,8 +1232,8 @@ sub callback_edit_var() {
sub toggle_portable {
my $td = $vars{'TEXDIR'};
my $b;
- if ($vars{'portable'}) {
- $vars{'portable'} = 0;
+ if ($vars{'instopt_portable'}) {
+ $vars{'instopt_portable'} = 0;
$portableyesno = __('No');
# enable some buttons
for $b (
@@ -1244,7 +1244,7 @@ sub toggle_portable {
$b->configure(-state => 'normal') if $b;
}
} else {
- $vars{'portable'} = 1;
+ $vars{'instopt_portable'} = 1;
$portableyesno = __('Yes');
# disable some buttons. These should get a name first.
for $b (
diff --git a/Master/tlpkg/installer/install-menu-text.pl b/Master/tlpkg/installer/install-menu-text.pl
index 521fa0af8cc..8cec73c7764 100644
--- a/Master/tlpkg/installer/install-menu-text.pl
+++ b/Master/tlpkg/installer/install-menu-text.pl
@@ -99,7 +99,7 @@ sub other_options {
'Q' => 'quit'
);
- $opts{'I'}=$vars{'portable'} ? 'start portable installation' :
+ $opts{'I'}=$vars{'instopt_portable'} ? 'start portable installation' :
'start installation to hard disk';
print "\nActions:";
@@ -520,7 +520,7 @@ EOF
support tree: $texmfdir
EOF
}
- if (!$vars{'portable'}) {
+ if (!$vars{'instopt_portable'}) {
print <<"EOF";
<2> TEXMFLOCAL: $vars{'TEXMFLOCAL'}
@@ -562,37 +562,37 @@ EOF
}
return $command{'self'};
- } elsif ("\u$answer" eq '2' and !$vars{'portable'}) {
+ } elsif ("\u$answer" eq '2' and !$vars{'instopt_portable'}) {
print "New value for TEXMFLOCAL [$vars{'TEXMFLOCAL'}]: ";
$answer = &input_dirname ();
$vars{'TEXMFLOCAL'} = $answer if $answer ne "";
return $command{'self'};
- } elsif ("\u$answer" eq '3' and !$vars{'portable'}) {
+ } elsif ("\u$answer" eq '3' and !$vars{'instopt_portable'}) {
print "New value for TEXMFSYSVAR [$vars{'TEXMFSYSVAR'}]: ";
$answer = &input_dirname ();
$vars{'TEXMFSYSVAR'} = $answer if $answer ne "";
return $command{'self'};
- } elsif ("\u$answer" eq '4' and !$vars{'portable'}) {
+ } elsif ("\u$answer" eq '4' and !$vars{'instopt_portable'}) {
print "New value for TEXMFSYSCONFIG [$vars{'TEXMFSYSCONFIG'}]: ";
$answer = &input_dirname ();
$vars{'TEXMFSYSCONFIG'} = $answer if $answer ne "";
return $command{'self'};
- } elsif ("\u$answer" eq '5' and !$vars{'portable'}) {
+ } elsif ("\u$answer" eq '5' and !$vars{'instopt_portable'}) {
print "New value for TEXMFVAR [$vars{'TEXMFVAR'}]: ";
$answer = &input_dirname ("noexpansion");
$vars{'TEXMFVAR'} = $answer if $answer ne "";
return $command{'self'};
- } elsif ("\u$answer" eq '6' and !$vars{'portable'}) {
+ } elsif ("\u$answer" eq '6' and !$vars{'instopt_portable'}) {
print "New value for TEXMFCONFIG [$vars{'TEXMFCONFIG'}]: ";
$answer = &input_dirname ("noexpansion");
$vars{'TEXMFCONFIG'} = $answer if $answer ne "";
return $command{'self'};
- } elsif ("\u$answer" eq '7' and !$vars{'portable'}) {
+ } elsif ("\u$answer" eq '7' and !$vars{'instopt_portable'}) {
print "New value for TEXMFHOME [$vars{'TEXMFHOME'}]: ";
$answer = &input_dirname ("noexpansion");
$vars{'TEXMFHOME'} = $answer if $answer ne "";
@@ -759,11 +759,11 @@ sub help_menu {
sub options_menu {
my $b_path=obutton($vars{'option_path'});
- my $b_doc=obutton($vars{'option_doc'});
- my $b_src=obutton($vars{'option_src'});
- my $b_fmt=obutton($vars{'option_fmt'});
- my $b_letter=obutton($vars{'option_letter'});
- my $b_adjustrepo=obutton($vars{'adjustrepo'});
+ my $b_doc=obutton($vars{'option_install_docfiles'});
+ my $b_src=obutton($vars{'option_install_srcfiles'});
+ my $b_fmt=obutton($vars{'option_create_formats'});
+ my $b_letter=obutton($vars{'instopt_letter'});
+ my $b_adjustrepo=obutton($vars{'instopt_adjustrepo'});
my $b_deskint=obutton(
$vars{'option_desktop_integration'}, \@::deskintdesc);
my $b_admin=obutton($vars{'option_w32_multi_user'});
@@ -799,7 +799,7 @@ EOF
if ($vars{'src_splitting_supported'} and !$opt_in_place) {
print " <S> install font/macro source tree: $b_src\n";
}
- if (!$vars{'portable'}) {
+ if (!$vars{'instopt_portable'}) {
if (unix() || $::opt_all_options) {
print <<"EOF";
<L> create symlinks in standard directories: $b_path
@@ -814,7 +814,7 @@ EOF
EOF
;
}
- if ((win32() && !$vars{'portable'}) || $::opt_all_options) {
+ if ((win32() && !$vars{'instopt_portable'}) || $::opt_all_options) {
print " <M> Start menu shortcuts / launcher: ".obutton(
$vars{'option_desktop_integration'}, \@::deskintdesc)."\n";
print " <N> update file associations: ".obutton(
@@ -837,7 +837,7 @@ EOF
# option_path
if (unix()) {
- if (("\u$answer" eq 'L') and !$vars{'portable'}) {
+ if (("\u$answer" eq 'L') and !$vars{'instopt_portable'}) {
my $home = getenv('HOME');
$home = getenv('USERPROFILE') if (win32());
$home ||= '~';
@@ -867,7 +867,7 @@ EOF
return $command{'self'};
}
} else {
- if (("\u$answer" eq 'L') and !$vars{'portable'}) {
+ if (("\u$answer" eq 'L') and !$vars{'instopt_portable'}) {
my $home = getenv('HOME');
$home = getenv('USERPROFILE') if (win32());
$home ||= '~';
@@ -879,11 +879,11 @@ EOF
# # option_desktop_integration, option_file_assocs
#
# if (win32() || $::opt_all_options) {
-# if ("\u$answer" eq 'M' and !$vars{'portable'}) {
+# if ("\u$answer" eq 'M' and !$vars{'instopt_portable'}) {
# toggle 'option_desktop_integration';
# return $command{'self'};
#
-# } elsif ("\u$answer" eq 'N' and !$vars{'portable'}) {
+# } elsif ("\u$answer" eq 'N' and !$vars{'instopt_portable'}) {
# print "New value for file_assocs:\n";
# print " 0 -- don't tweak the file associations\n";
# print " 1 -- only add new file associations, don't overwrite old ones\n";
@@ -895,7 +895,7 @@ EOF
# }
# return $command{'self'};
#
-# } elsif ("\u$answer" eq 'U' and !$vars{'portable'}) {
+# } elsif ("\u$answer" eq 'U' and !$vars{'instopt_portable'}) {
# toggle 'option_w32_multi_user';
# return $command{'self'};
# }
@@ -903,20 +903,20 @@ EOF
# other options
- if (("\u$answer" eq 'M') && !$vars{'portable'}) {
+ if (("\u$answer" eq 'M') && !$vars{'instopt_portable'}) {
toggle ('option_desktop_integration', \@::deskintdesc);
return $command{'self'};
- } elsif (("\u$answer" eq 'N') && !$vars{'portable'}) {
+ } elsif (("\u$answer" eq 'N') && !$vars{'instopt_portable'}) {
toggle ('option_file_assocs', \@::fileassocdesc);
return $command{'self'};
} elsif ("\u$answer" eq 'P') {
- toggle 'option_letter';
+ toggle 'instopt_letter';
return $command{'self'};
} elsif ("\u$answer" eq 'F') {
- toggle 'option_fmt';
+ toggle 'option_create_formats';
return $command{'self'};
} elsif ("\u$answer" eq 'E') {
@@ -924,11 +924,11 @@ EOF
return $command{'self'};
} elsif ("\u$answer" eq 'S' and !$opt_in_place) {
- toggle 'option_src';
+ toggle 'option_install_srcfiles';
return $command{'self'};
} elsif ("\u$answer" eq 'D' and !$opt_in_place) {
- toggle 'option_doc';
+ toggle 'option_install_docfiles';
return $command{'self'};
} elsif (defined $command{"\u$answer"}) {
@@ -940,7 +940,7 @@ EOF
return $command{'self'};
} elsif ("\u$answer" eq 'Y' and $media ne "NET") {
- toggle 'adjustrepo';
+ toggle 'instopt_adjustrepo';
return $command{'self'};
} else {
@@ -960,14 +960,14 @@ sub do_install {
}
sub toggle_portable {
- if ($vars{'portable'}) {
- $vars{'portable'} = 0;
+ if ($vars{'instopt_portable'}) {
+ $vars{'instopt_portable'} = 0;
$vars{'option_desktop_integration'} = 0;
$vars{'option_path'} = 0;
$vars{'option_file_assocs'} = 0;
$vars{'option_w32_multi_user'} = 0;
} else {
- $vars{'portable'} = 1;
+ $vars{'instopt_portable'} = 1;
$vars{'option_desktop_integration'} = 1;
$vars{'option_path'} = 1;
$vars{'option_file_assocs'} = 1;
@@ -988,10 +988,10 @@ sub main_menu {
my $this_platform=platform_desc($vars{'this_platform'});
my $b_path=button($vars{'option_path'});
- my $b_doc=button($vars{'option_doc'});
- my $b_src=button($vars{'option_src'});
- my $b_fmt=button($vars{'option_fmt'});
- my $b_letter=button($vars{'option_letter'});
+ my $b_doc=button($vars{'option_install_docfiles'});
+ my $b_src=button($vars{'option_install_srcfiles'});
+ my $b_fmt=button($vars{'option_create_formats'});
+ my $b_letter=button($vars{'instopt_letter'});
my $b_deskint=button($vars{'option_desktop_integration'}, \@::deskintdesc);
if (win32()) {
my $b_fileassoc=button($vars{'option_file_assocs'}, \@::fileassocdesc);
@@ -999,7 +999,7 @@ sub main_menu {
my $b_admin=button($vars{'option_w32_multi_user'});
my $b_addoneditor=button($vars{'collection-texworks'});
my $b_restricted=button($vars{'option_write18_restricted'});
- my $b_adjustrepo=button($vars{'adjustrepo'});
+ my $b_adjustrepo=button($vars{'instopt_adjustrepo'});
my $warn_nobin;
@@ -1103,7 +1103,7 @@ EOF
}
}
if (win32()) {
- if (!$vars{'portable'}) {
+ if (!$vars{'instopt_portable'}) {
print " $b_path adjust search path\n";
print " $b_deskint add menu items, shortcuts, etc.\n";
print " [$vars{'option_file_assocs'}] update file associations\n";
@@ -1115,13 +1115,13 @@ EOF
}
print " $b_path create symlinks to standard directories\n"
- unless ($vars{'portable'} || win32());
+ unless ($vars{'instopt_portable'} || win32());
print " $b_adjustrepo after install, use tlnet on CTAN "
. "for package updates\n"
unless ($media eq 'NET');
- if ($vars{'portable'}) {
+ if ($vars{'instopt_portable'}) {
print "\n <V> set up for regular installation to hard disk\n";
} else {
print "\n <V> set up for portable installation\n";
diff --git a/Master/tlpkg/installer/install-menu-wizard.pl b/Master/tlpkg/installer/install-menu-wizard.pl
index 7f92dd35d6c..6fee6de1954 100644
--- a/Master/tlpkg/installer/install-menu-wizard.pl
+++ b/Master/tlpkg/installer/install-menu-wizard.pl
@@ -20,8 +20,8 @@ load_translations();
# for unix and windows. On W32 with admin privileges both @w32 list options
# are shown
# the values are keys into the %vars array
-my @unix_opts = qw/option_letter/;
-my @w32_opts = qw/option_letter
+my @unix_opts = qw/instopt_letter/;
+my @w32_opts = qw/instopt_letter
option_desktop_integration
collection-texworks
/;
@@ -37,7 +37,7 @@ if (win32()) {
push @opts_list, @unix_opts;
}
my %opts_to_str = (
- "option_letter" => __("Default paper size"),
+ "instopt_letter" => __("Default paper size"),
"option_desktop_integration" => __("Add menu shortcuts"),
"option_file_assocs" => __("Change file associations"),
"option_path" => __("Adjust PATH setting in registry"),
@@ -45,7 +45,7 @@ my %opts_to_str = (
"collection-texworks" => __("Install TeXworks front end"),
);
my %opts_choices = (
- "option_letter" => ["A4", "letter"],
+ "instopt_letter" => ["A4", "letter"],
);
diff --git a/Master/tlpkg/installer/installer-options.txt b/Master/tlpkg/installer/installer-options.txt
index 495c358b032..38e606d2cdb 100644
--- a/Master/tlpkg/installer/installer-options.txt
+++ b/Master/tlpkg/installer/installer-options.txt
@@ -5,19 +5,19 @@
description
used in install-tl/tlmgr/TLMedia
----------------------------------------------------------------------------
-option_doc 1 x x
+option_install_docfiles 1 x x
option("install_docfiles")
install doc files
install-tl: sub do_install_packages
TLMedia.pm: sub install_package
-option_src 1 x x
+option_install_srcfiles 1 x x
option("install_srcfiles")
install src files
install-tl: sub do_install_packages
TLMedia.pm: sub install_package
-option_fmt 1 x x
+option_create_formats 1 x x
option("create_formats")
create all formats
install-tl: sub do_postinst_stuff
@@ -59,7 +59,7 @@ option_w32_multi_user 1 w32 w32 w32
install-tl: sub do_path_adjustments
TLMedia: remove_package, install_package
-option_letter 0 x x x
+instopt_letter 0 x x x
not saved into the local TLPDB
only for install time setting
use letter