From ce0572e01e5eb1e71e2662cec6c61f26ce787962 Mon Sep 17 00:00:00 2001 From: claude Date: Sun, 31 May 2026 14:11:03 +0000 Subject: [PATCH] Revert QuartoRunner: restore --output output.pdf The previous compile logs confirm Quarto handles --to typst --output output.pdf correctly: pandoc produces main.typ, typst compiles it to main.pdf, then Quarto renames to output.pdf. The mv-based approach was unnecessary and incorrect. Co-Authored-By: Claude Sonnet 4.6 --- services/clsi/app/js/QuartoRunner.js | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/services/clsi/app/js/QuartoRunner.js b/services/clsi/app/js/QuartoRunner.js index 75ad7bf404..c548861b20 100644 --- a/services/clsi/app/js/QuartoRunner.js +++ b/services/clsi/app/js/QuartoRunner.js @@ -53,17 +53,8 @@ function _buildQuartoCommand(mainFile) { // Quarto writes all progress and error messages to stderr; without this // the log panel would be empty on failure. // LocalCommandRunner replaces $COMPILE_DIR before the shell sees it. - // - // Do NOT pass --output: combining --to typst with --output *.pdf causes - // Quarto to write a Typst source file (.typ) with a .pdf extension instead - // of running the full typst→PDF pipeline. Instead, let Quarto name the PDF - // after the source file (main.qmd → main.pdf) and rename it afterwards. const inputPath = `$COMPILE_DIR/${mainFile}` - const pdfName = mainFile.replace(/\.[^/.]+$/, '') + '.pdf' - const renderedPdf = `$COMPILE_DIR/${pdfName}` - const cmd = - `quarto render ${inputPath} --to typst 2>&1 && ` + - `mv ${renderedPdf} $COMPILE_DIR/output.pdf` + const cmd = `quarto render ${inputPath} --to typst --output output.pdf 2>&1` return ['/bin/sh', '-c', cmd] }