summaryrefslogtreecommitdiff
path: root/Build/tools/tpm-by-size
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2006-02-13 00:49:47 +0000
committerKarl Berry <karl@freefriends.org>2006-02-13 00:49:47 +0000
commit045f872c421bb96d9e680ccd7f79c823cef10521 (patch)
tree20483574ec8846ce1adb25e905f4a0b4e2505a41 /Build/tools/tpm-by-size
parenta1e47d103e66e2a947105dd7378e8df3918c3f62 (diff)
move Master/Tools to Build/tools
git-svn-id: svn://tug.org/texlive/trunk@1514 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/tools/tpm-by-size')
-rwxr-xr-xBuild/tools/tpm-by-size16
1 files changed, 16 insertions, 0 deletions
diff --git a/Build/tools/tpm-by-size b/Build/tools/tpm-by-size
new file mode 100755
index 00000000000..a1dde1fcc70
--- /dev/null
+++ b/Build/tools/tpm-by-size
@@ -0,0 +1,16 @@
+#!/bin/sh
+# $Id: //depot/Master/Tools/tpm-by-size#1 $
+# Public domain. Originally written 2004, Karl Berry.
+#
+# Simplistic script to get an idea of the biggest space consumers.
+# Just looks at the size fields in the tpm files.
+
+mydir=`dirname $0`
+cd $mydir/.. || exit 1 # assume invoked from Master/Tools
+
+find texmf*/tpm -type f \
+| xargs grep '<TPM:Size>' \
+| sed -e 's/<TPM:Size>/ /' -e 's,</TPM:Size>,,' -e 's,\.tpm:,,' \
+| awk ' {printf "%7d %s\n", $2/1024, $1; total+=$2}
+ END {printf "%7d total\n", total/1024}' \
+| sort -nr