# Run script for ANSI lexicon, revised 6/2/92 by fwb.

OUTPUT=/tmp/doc
>ansi.x

troff -p -r#1 -mcohtext fonts.r top.r introduction \
	>$OUTPUT/ansi2.p 2>>ansi.x
tail -1 ansi.x >pgn.r
#
troff -p -mcohtext fonts.r pgn.r top.r lexicon.intro \
	>$OUTPUT/ansi3.p 2>>ansi.x
tail -1 ansi.x >pgn.r
#
# and do the troffing
#
for i in E _ a b c d e f g h i j k l m n o p q r s t u v w
do
	troff -p -mcohlex fonts.r pgn.r top.r /v/doc/coherent/alphabet/$i.r \
		../lx/ANSI/$i*	>$OUTPUT/ansi.$i.p 2>>ansi.x
	tail -1 ansi.x >pgn.r
done

#
# build the index
#
index < ansi.x > ansi.idx
troff -p -mcohindex pgn.r fonts.r top.r ansi.idx \
	>$OUTPUT/ansi6.p 2>>ansi.x
#
# build the table of contents
#
contents < ansi.x > ansi.toc
troff -p -r%1 -mcohcon fonts.r top.r ansi.toc \
	>$OUTPUT/ansi0.p
