Skip to content

Commit

Permalink
ci: update latex pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
felixevers committed Aug 19, 2024
1 parent 8032e3d commit 8c11242
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 13 deletions.
57 changes: 44 additions & 13 deletions .github/workflows/latex.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,47 @@
name: Build AVV LaTeX document
on: [push]
name: LaTeX to PDF

on: [push, pull_request]

jobs:
build_latex:
build:
runs-on: ubuntu-latest

steps:
- name: Set up Git repository
uses: actions/checkout@v1
- name: Compile LaTeX document
uses: xu-cheng/latex-action@master
with:
root_file: avv.tex
- uses: actions/upload-artifact@v1
with:
name: avv.pdf
path: document.pdf
- name: Checkout repository
uses: actions/checkout@v3

- name: Install Inter font
run: |
sudo apt-get update
sudo apt-get install -y unzip fontconfig wget
mkdir -p ~/.local/share/fonts
wget -qO Inter.zip https://github.com/rsms/inter/releases/download/v3.19/Inter-3.19.zip
unzip -o Inter.zip -d ~/.local/share/fonts
fc-cache -f -v
- name: Compile LaTeX documents
uses: xu-cheng/latex-action@v2
with:
root_file: |
agb_app_zum_doc_patient.tex
agb_mediquu_connect.tex
agb_app_zum_doc.tex
agb_mediquu_netzmanager.tex
agb_mediquu_chat.tex
extra_system_packages: "inkscape"
latexmk_shell_escape: true
latexmk_use_lualatex: false

- name: Compile all LaTeX documents
run: |
mkdir -p output
for file in *.tex; do
latexmk -pdf -shell-escape -interaction=nonstopmode -output-directory=output "$file"
done
- name: Upload PDFs
uses: actions/upload-artifact@v3
with:
name: pdfs
path: output/*.pdf

4 changes: 4 additions & 0 deletions avv.tex
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
\def\Year{\expandafter\YEAR\the\year}
\def\YEAR#1#2#3#4{#1#2#3#4}

\AtEndDocument{
\label{lastpage}
}

\fancyhead{}
\pagestyle{fancy}
\renewcommand{\headrulewidth}{0pt}
Expand Down

0 comments on commit 8c11242

Please sign in to comment.