#!/usr/bin/perl #The tail of the directory chop($mydir=`pwd`); $mydir=substr($mydir,rindex($mydir,"/")+1); if (! -r $mydir.".tex") { print "Woops, this won't work\n"; print "You need the file $mydir.tex for the abstract\n"; exit 0; } if (! -r $mydir.".ps"){ print "Woops, this won't work\n"; print "You need the file $mydir.ps for the postscript paper\n"; exit 0; } #run latex2html `/usr/statlocal/bin/latex2html -no_navigation -info '' $mydir.tex`; ##mv files to . `mv $mydir/* .`; `mv $mydir/.??* .`; rmdir $mydir; ## Open the html file, remove the trailer, add stuff @dodo=split(' ',`ls -l $mydir".ps"`); $length=$dodo[4]; open(MYIN, $mydir.".html"); open(MYOUT, ">foobar"); read(MYIN, $html, 99999); $start = index($html,"
"); print MYOUT substr($html,0,$start); print MYOUT "Here is the full postscript text for this\n"; print MYOUT "technical report. It is $length bytes long. \n"; print MYOUT "