Bopytex/bopytex/worker/compile.py

16 lines
418 B
Python

import subprocess
from bopytex.message import Message
from ..message import SubprocessMessage
def latexmk(args: dict, deps, output):
compile_process = subprocess.Popen(
["latexmk", "-f", deps[0]],
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
universal_newlines=True
)
return Message(compile_process.wait(), list(compile_process.stdout), list(compile_process.stderr))