#! /bin/sh # file: fixag.sh G. Moody 10 April 1997 # Last revised: 24 October 2018 # # Post-process WFDB Applications Guide HTML files set -e URLPREFIX=http://www.physionet.org/physiotools/wag/ LONGDATE=$1 shift for i in $* do F=`basename $i .html` G=`echo $F | sed 's/\./-/g'` echo processing $F ... sed 's/\.html/\.htm/g' <$F.html | sed 's/evfootnode\.htm/evfoot\.htm/g' | sed 's/
//' | sed 's/\.\(.\)\.htm/-\1.htm/g' >$G.htm done mv -f evfootnode.htm evfoot.htm for i in *.htm do echo fixing links in $i ... cp $i .fix.$$ sed -f fixag.sed <.fix.$$ | sed "s/LONGDATE/$LONGDATE/" | sed "s+PAGENAME+$URLPREFIX$i+" >$i done rm .fix.$$ PREVT= PREVU= THIST=FAQ THISU="faq.htm" NEXTT= NEXTU= for i in *-1.htm *-3.htm *-5.htm *-7.htm do NEXTT=`grep "