sanity_check 715 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
#!/bin/sh

VERSION=$1

if [ ! -f glib-$VERSION.tar.gz ]; then
	echo "ERROR: glib-$VERSION.tar.gz does not exist..."
	exit 1
fi

echo ""

echo "Checking glib-$VERSION.tar.gz..."
tar xfz glib-$VERSION.tar.gz


16
for file in INSTALL NEWS
17 18
do
	echo -n "$file... "
19
	if [ "x`grep $VERSION glib-$VERSION/$file | wc -l | awk -F' ' '{print $1}'`" = "x0" ]; then
20
		echo "failed."
Matthias Clasen's avatar
Matthias Clasen committed
21
		#exit 1
Matthias Clasen's avatar
Matthias Clasen committed
22 23
	else
		echo "ok"
24 25 26 27
	fi
done

echo -n "INSTALL..."
28
if [ "x`grep $VERSION glib-$VERSION/INSTALL | wc -l | awk -F' ' '{print $1}'`" = "x2" ]; then 
29 30 31 32 33 34 35 36 37
	echo "ok" 
else
	echo "failed."
	exit 1
fi

echo ""
echo "Number of lines in created documentation files:"

Matthias Clasen's avatar
Matthias Clasen committed
38
wc -l glib-$VERSION/docs/reference/*/html/*.html | grep total 
39 40

rm -rf glib-$VERSION