summaryrefslogtreecommitdiff
path: root/Master/texmf
diff options
context:
space:
mode:
authorNorbert Preining <preining@logic.at>2010-10-26 16:27:05 +0000
committerNorbert Preining <preining@logic.at>2010-10-26 16:27:05 +0000
commite9dbd753fa0f5419db47d3a4fc48eb056b337e1e (patch)
tree68ea96de73dbff2a3dc9eeabb108d052203d079a /Master/texmf
parent46cc0f2198d079f628f1112ee5edbacdee5d2ba3 (diff)
rename gui_expertmode to gui-expertmode, and allow for upgrading users
settings files git-svn-id: svn://tug.org/texlive/trunk@20215 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf')
-rwxr-xr-xMaster/texmf/scripts/texlive/tlmgr.pl21
-rw-r--r--Master/texmf/scripts/texlive/tlmgrgui.pl4
2 files changed, 14 insertions, 11 deletions
diff --git a/Master/texmf/scripts/texlive/tlmgr.pl b/Master/texmf/scripts/texlive/tlmgr.pl
index 953fa2af3b2..95be200f597 100755
--- a/Master/texmf/scripts/texlive/tlmgr.pl
+++ b/Master/texmf/scripts/texlive/tlmgr.pl
@@ -4633,28 +4633,31 @@ sub finish
# key=value
#
# allowed keys at the moment
-# gui_expertmode = 0|1
+# gui-expertmode = 0|1
#
sub load_config_file
{
#
# first set default values
- # the default for gui_expertmode is 1 since that is what we
+ # the default for gui-expertmode is 1 since that is what we
# have shipped till now
- $config{"gui_expertmode"} = 1;
+ $config{"gui-expertmode"} = 1;
chomp (my $TEXMFCONFIG = `kpsewhich -var-value=TEXMFCONFIG`);
my $fn = "$TEXMFCONFIG/tlmgr/config";
$tlmgr_config_file = TeXLive::TLConfFile->new($fn, "#", "=");
+ if ($tlmgr_config_file->key_present("gui_expertmode")) {
+ $tlmgr_config_file->rename_key("gui_expertmode", "gui-expertmode");
+ }
for my $key ($tlmgr_config_file->keys) {
my $val = $tlmgr_config_file->value($key);
- if ($key eq "gui_expertmode") {
+ if ($key eq "gui-expertmode") {
if ($val eq "0") {
- $config{"gui_expertmode"} = 0;
+ $config{"gui-expertmode"} = 0;
} elsif ($val eq "1") {
- $config{"gui_expertmode"} = 1;
+ $config{"gui-expertmode"} = 1;
} else {
- tlwarn("Unknown value >$val< for gui_expertmode in $fn\n");
+ tlwarn("Unknown value >$val< for gui-expertmode in $fn\n");
}
} elsif ($key eq "persistent-downloads") {
if (($val eq "0") || ($val eq "1")) {
@@ -5904,10 +5907,10 @@ other lines must look like
key = value
-where the allowed keys are C<gui_expertmode> and
+where the allowed keys are C<gui-expertmode> and
C<persistent-downloads>. The values can only be 0 or 1 for those
settings. C<persistent-downloads> corresponds to the respective command
-line options of C<tlmgr>. C<gui_expertmode> switches between the full
+line options of C<tlmgr>. C<gui-expertmode> switches between the full
GUI and a simplified with only the important and mostly used settings.
diff --git a/Master/texmf/scripts/texlive/tlmgrgui.pl b/Master/texmf/scripts/texlive/tlmgrgui.pl
index 4a0ea709515..0046c0b6c51 100644
--- a/Master/texmf/scripts/texlive/tlmgrgui.pl
+++ b/Master/texmf/scripts/texlive/tlmgrgui.pl
@@ -48,7 +48,7 @@ use TeXLive::TLConfig;
# GUI mode
#
our %config;
-my $mode_expert = $config{"gui_expertmode"};
+my $mode_expert = $config{"gui-expertmode"};
#
# stuff defined in tlmgr.pl that needs to be our-ed
@@ -1263,7 +1263,7 @@ sub do_and_warn_gui_mode_settings {
-default_button => 'Ok',
-buttons => [__("Ok"), __("Cancel")])->Show;
if ($ans eq __("Ok")) {
- $config{"gui_expertmode"} = $mode_expert;
+ $config{"gui-expertmode"} = $mode_expert;
write_config_file();
}
}