summaryrefslogtreecommitdiff
path: root/Build/tools/update-tpm
diff options
context:
space:
mode:
Diffstat (limited to 'Build/tools/update-tpm')
-rwxr-xr-xBuild/tools/update-tpm40
1 files changed, 40 insertions, 0 deletions
diff --git a/Build/tools/update-tpm b/Build/tools/update-tpm
new file mode 100755
index 00000000000..370553921a4
--- /dev/null
+++ b/Build/tools/update-tpm
@@ -0,0 +1,40 @@
+#!/bin/sh
+# $Id$
+# Public domain. Originally written 2004, Karl Berry.
+#
+# Regenerate the given set of tpm's using tpm-factory.
+
+mydir=`dirname $0`
+master=`cd $mydir/.. && pwd`
+tools=$master/Tools
+
+verbose=${OVERRIDE_VERBOSE-}
+
+if test "x$1" = x--debug; then
+ verbose=--debug
+ shift
+fi
+
+test $# -eq 0 && set - TLCore Package Documentation
+
+for type in "$@"; do
+ case $type in
+ TLCore) p=from; dir=texmf;;
+ Package) p=auto; dir=texmf-dist;;
+ Documentation) p=auto; dir=texmf-doc;;
+ *) echo "$0: unknown type $type, one of TLCore, Package, Documentation.">&2
+ exit 1;;
+ esac
+
+ cd $master/$dir/tpm || exit 1
+ chmod a+rw * >&/dev/null # all files must be writable for tpm-factory.
+
+ perl $tools/tpm-factory.pl $verbose \
+ --master_dir=$master --ftp_dir=/tmp \
+ --clean \
+ --arch=all \
+ --patterns=$p \
+ --type=$type \
+ | grep -v '^Writing '
+done
+exit 0