Updated for PHP.
[yaz-moved-to-github.git] / doc / indexdata.sh
1 #!/bin/sh
2 # $Id: indexdata.sh,v 1.2 2000-03-29 15:07:16 adam Exp $
3 # Script to convert documentation to indexdata.dk style...
4 for i in ${package}*.html; do
5         j=`basename $i html`php
6         awk 'BEGIN { body = 0 } /<\/BODY/ { body = 0; print "<?php id_footer(); ?>" } { if (body == 1) print $0} /<BODY>/ { body = 1; print "<?php require(\"../id_common.inc\"); id_header(\"YAZ Documentation\"); ?>"; } ' < $i | sed '-es/\(HREF=\"yaz.*\)\.html/\1.php/g' >$j
7 done