@echo on copy %1.mp temp.mp /Y mpost -tex=latex temp.mp mpost -tex=latex temp.mp copy temp.1 %1.mps /Y del temp.mp del *.mpx del *.tmp @echo \input{mphead} > %1.tex @echo \usepackage[dvips]{graphicx} >> %1.tex @echo \pagestyle{empty} >> %1.tex @echo \begin{document} >> %1.tex @echo \includegraphics{temp.1} >> %1.tex @echo \end{document} >> %1.tex latex %1.tex dvips -Ppdf -G0 -E %1.dvi del temp.1 del %1.1 del %1.tex del %1.log del %1.aux del %1.dvi copy temp.log %1.log /Y del temp.log