From 0477170315f7bbf8fcd35c9e3e87c692cfe10b89 Mon Sep 17 00:00:00 2001 From: 0x7969 <1438229+0x7969@users.noreply.github.com> Date: Fri, 8 Oct 2021 13:43:10 +0200 Subject: [PATCH] Quick fix to allow usage of tectonic tex compiler No extensive testing done. Someone would have to look over it. Would be a nice feature though. --- pylatex/document.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pylatex/document.py b/pylatex/document.py index 47d4c73f..a68b686f 100644 --- a/pylatex/document.py +++ b/pylatex/document.py @@ -235,8 +235,6 @@ def generate_pdf(self, filepath=None, *, clean=True, clean_tex=True, ('pdflatex', []) ) - main_arguments = ['--interaction=nonstopmode', filepath + '.tex'] - check_output_kwargs = {} if python_cwd_available: check_output_kwargs = {'cwd': dest_dir} @@ -244,6 +242,11 @@ def generate_pdf(self, filepath=None, *, clean=True, clean_tex=True, os_error = None for compiler, arguments in compilers: + if compiler == 'tectonic': + main_arguments = [filepath + '.tex'] + else: + main_arguments = ['--interaction=nonstopmode', filepath + '.tex'] + command = [compiler] + arguments + compiler_args + main_arguments try: