> I would like to write a script to automate the following sequence of
 > commands in Linux:
 > 
 > tex \&opustex jobname
 > opusflex jobname
 > tex \&opustex jobname
 > dvips -o jobname.ps jobname
 > gv jobname
 > 

Create a file as follows:

#!/usr/bin/sh
tex \&opustex $1
opusflex $1
tex \&opustex $1
dvips -o $1.ps $1
gv $1.ps

Your sh executable might be elsewhere; do which sh to see.
Make filename executable by doing chmod +x filename.
Make sure that the file is in your path (or use the full path to call it).
If the file you want to process is foo.tex, call it with just foo
as the argument.

Some helpful hints.  You don't need to re-start gv every time.  Start it 
once and leave it running while you revise.  You can also preview using 
xdvi, which will give you better displays than gv and save you the dvips 
step.  You might want to remove the mx1 and mx2 files after the second TeXing.  
You can create an opustex "format" so that those macros don't have
to be re-processed again and again.

Bob T.

Reply via email to