#!/bin/sh
set -e
cwd="`pwd`"
date="`date +'%d %h %Y'`"
txtconvert () {
src=$1; dst=$2
echo " generating $dst from $src ..."
rm -f /var/lib/debbugs/www/txt/$dst.html /var/lib/debbugs/www/txt/$dst
perl -ne 'print unless m/^Other pages:$/ .. /^\
/' \
/var/lib/debbugs/www/$src > /var/lib/debbugs/www/txt/$dst.html
HOME=/dev/null lynx -nolist -dump -cfg=/etc/debbugs/lynx-cfg \
file://localhost/var/lib/debbugs/www/txt/$dst.html > /var/lib/debbugs/www/txt/$dst
rm /var/lib/debbugs/www/txt/$dst.html
}
echo "documentation conversion ..."
txtconvert Reporting.html bug-reporting.txt
txtconvert Access.html bug-log-access.txt
txtconvert server-request.html bug-log-mailserver.txt
txtconvert Developer.html bug-maint-info.txt
txtconvert server-control.html bug-maint-mailcontrol.txt
txtconvert server-refcard.html bug-mailserver-refcard.txt
exit 0