summaryrefslogtreecommitdiff
path: root/Master/tlpkg/bin/tl-prune-platforms
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-01-24 18:11:41 +0000
committerKarl Berry <karl@freefriends.org>2018-01-24 18:11:41 +0000
commit70ef0d6846c2da4367cc9968ed84040d2462622e (patch)
tree822fc89c8d51592161ced643161c5e012ec05d93 /Master/tlpkg/bin/tl-prune-platforms
parenta0e7279f5e56528d24f512e841c42649bfe4427e (diff)
save backup of tlpdb when building or pruning release image
git-svn-id: svn://tug.org/texlive/trunk@46428 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/bin/tl-prune-platforms')
-rwxr-xr-xMaster/tlpkg/bin/tl-prune-platforms19
1 files changed, 13 insertions, 6 deletions
diff --git a/Master/tlpkg/bin/tl-prune-platforms b/Master/tlpkg/bin/tl-prune-platforms
index 0dd7462471d..bbc9fd458e6 100755
--- a/Master/tlpkg/bin/tl-prune-platforms
+++ b/Master/tlpkg/bin/tl-prune-platforms
@@ -1,5 +1,5 @@
#!/usr/bin/env perl
-# Copyright 2012-2016 Norbert Preining
+# Copyright 2012-2018 Norbert Preining
# This file is licensed under the GNU General Public License version 2
# or any later version.
#
@@ -41,8 +41,7 @@ if ($opt_version) { print "$vc_id\n"; exit 0; }
exit (&main());
-sub main
-{
+sub main {
# prune db in the same hierarchy from which we are being run.
chomp(my $Master = `cd $mydir/../.. && pwd`);
# necessary for TLUtils->platform
@@ -104,8 +103,13 @@ sub main
push @newarchs, $a if !TeXLive::TLUtils::member($a, @ARGV);
}
- $tlpdb->setting("available_architectures",@newarchs);
- $tlpdb->save unless $opt_dry;
+ $tlpdb->setting("available_architectures", @newarchs);
+
+ if (! $opt_dry) {
+ TeXLive::TLUtils::copy ("-f", $tlpdb->location,
+ $tlpdb->location . ".preprune");
+ $tlpdb->save;
+ }
return 0;
}
@@ -139,7 +143,7 @@ accepted; see the C<process_logging_options> function in
L<TeXLive::TLUtils> for details.
The format of the containers and the splitting of source and
-documentation files are controlled by the TLPDB options in the
+documentation files are controlled by the tlpdb options in the
pseudo-package C<00texlive.config>. See L<TeXLive::TLPDB>.
=head1 DESCRIPTION
@@ -151,6 +155,9 @@ the containers. (Any xz and wget binaries for the installer remain, though.)
It is used during DVD production to exclude certain platforms, and is
run from the L<tl-update-images> script.
+The pre-existing tlpdb file is saved with extension C<.preprune> before
+the modified version is written.
+
=head1 AUTHORS AND COPYRIGHT
This script and its documentation were written for the TeX Live