From 50d227c793cfa9d79ddce33b28e8cb8b1a3615dc Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Mon, 4 May 2009 14:08:58 +0000 Subject: warn if a backupdir is set that does not exist git-svn-id: svn://tug.org/texlive/trunk@12922 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf/scripts/texlive/tlmgr.pl | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'Master/texmf') diff --git a/Master/texmf/scripts/texlive/tlmgr.pl b/Master/texmf/scripts/texlive/tlmgr.pl index 9c0cbb99770..ca00d7c8740 100755 --- a/Master/texmf/scripts/texlive/tlmgr.pl +++ b/Master/texmf/scripts/texlive/tlmgr.pl @@ -1996,6 +1996,19 @@ sub action_option { info("Default destination for symlinks to binaries: ", $localtlpdb->option_sys_bin, "\n"); } + } elsif ($what =~ m/^backupdir$/i) { + my $val = shift @ARGV; + if (defined($val)) { + info("tlmgr: setting option $what to $val.\n"); + if (! -d $val) { + info("tlmgr: the directory $val does not exists, it has to be created\n"); + info("tlmgr: before backups can be done automatically.\n"); + } + $localtlpdb->option($what,$val); + $localtlpdb->save; + } else { + info("Option $what = ", $localtlpdb->option($what), "\n"); + } } elsif (member($what, @AllowedConfigOptions)) { # for all further options not handled above, we check whether they # appear in the list of allowed options; if they do, we set/read -- cgit v1.2.3