#! /bin/bash
# Script to generate HTML for handbook
# 17-10-2007

HDOC1=handbook/chap_C.html
HDOC2=handbook/chap_D.html

cat head1.html > "$HDOC1"
cat ../NEWS |
while read line
do
	line2=`echo "$line" | sed -e 's/\&/\&amp;/' | sed -e 's/>/\&gt;/' | sed -e 's/</\&lt;/'`
	# Replace &, >, <, characters with proper html codes
	echo "$line2<BR>" >> "$HDOC1"
done
cat tail1.html >> "$HDOC1"

cat head2.html > "$HDOC2"
cat ../README |
while read line
do
	line2=`echo "$line" | sed -e 's/\&/\&amp;/' | sed -e 's/>/\&gt;/' | sed -e 's/</\&lt;/'`
	# Replace &, >, <, characters with proper html codes
	echo "$line2<BR>" >> "$HDOC2"
done
cat tail2.html >> "$HDOC2"
