#!/bin/sh
#
# Test the documentation.

set -e

suite=$(debian-edu-current-codename)
capsuite=$(echo $suite | sed 's/\([a-z]\)\([a-zA-Z0-9]*\)/\u\1\2/g')

docfile=/usr/share/doc/debian-edu-doc/en/debian-edu-$suite-manual.html
docurl=http://wiki.debian.org/DebianEdu/Documentation/$capsuite

if [ -r $docfile ] ; then
    fixmes=$(grep -c FIXME $docfile)
    if [ 0 -eq "$fixmes" ]; then
	echo "success: $0: Release manual have zero FIXMEs."
    else
	echo "error: $0: Release manual have $fixmes FIXMEs.  Please fix at $docurl ."
    fi
else
    echo "error: $0: Unable to find documentation at $docfile."
fi

exit 0
