blob: 3d041a717b6dd10e75a0159fad8dd30ba64ce909 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#!/bin/sh
# $Id$
# Copyright 2007 Karl Berry
# This file is licensed under the GNU General Public License version 2
# or any later version.
#
# Check that tlpdb contains all the files in the trees, exactly once.
# also that collections don't have files.
cd `dirname $0`/../.. || exit 1
if test ! -s texlive.tlpdb; then
echo "$0: no (nonempty) texlive.tlpdb in $0, goodbye." >&2
exit 1
fi
: ${TMPDIR=/tmp}
trap "rm -f $TMPDIR/tlpdb*" 0 1 2 15
# Get list of files.
tlpdbfiles=$TMPDIR/tlpdbfiles.$$
grep '^ ' texlive.tlpdb | sort >$tlpdbfiles
echo "$0: checking duplicates..."
# GNU uniq makes it simple.
uniq --repeated $tlpdbfiles
echo "$0: checking coverage...(long)"
dirs=bin
diskfiles=$TMPDIR/tlpdbdisk.$$
find $dirs -name .svn -prune -o \( \( -type f -o -type l \) -print \) | sed 's/^/ /' | sort | tee /tmp/x >$diskfiles
comm -3 $tlpdbfiles $diskfiles
|