dante-ev / latex-action

:octocat: GitHub Action to compile LaTeX documents
MIT License
173 stars 25 forks source link

Labels ref is rendered as `??` #24

Open jmeinlschmidt opened 1 year ago

jmeinlschmidt commented 1 year ago

While the \ref macro renders normally in Overleaf, I get ?? for all references in the resulting file when processing this action.

Examples:

\ref{analysis}

% ...

\section{Analysis and design}
\label{analysis}

Used configuration

      - name: Compile LaTeX document
        uses: dante-ev/latex-action@latest
        with:
          root_file: $TEXT_SRC.tex
          compiler: lualatex
          args: -lualatex -latexoption=-file-line-error -latexoption=-interaction=nonstopmode -shell-escape

Any ideas? Thank you!

koppor commented 1 year ago

You need to run lualatex twice to get labels rendered correctly. Reason: lualatex is a single-pass compiler and the reference was put before the label.