From 4fa7276898fb9c43aa5047a1635f4608d8ca4fab Mon Sep 17 00:00:00 2001 From: robogg133 Date: Mon, 3 Nov 2025 11:40:10 -0300 Subject: [PATCH] workflow arrumado --- .gitea/workflows/md-to-pdf.yml | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/.gitea/workflows/md-to-pdf.yml b/.gitea/workflows/md-to-pdf.yml index ee6ab89..09832bc 100644 --- a/.gitea/workflows/md-to-pdf.yml +++ b/.gitea/workflows/md-to-pdf.yml @@ -1,7 +1,7 @@ name: Convert Specific MD to PDF on: push: - branches: [main, master] + branches: [main] paths: ["RoteiroPitch.md"] workflow_dispatch: @@ -12,17 +12,23 @@ jobs: - name: Checkout code uses: actions/checkout@v4 - - name: Install Pandoc + - name: Install Pandoc and LaTeX run: | sudo apt-get update - sudo apt-get install -y pandoc texlive-latex-base texlive-fonts-recommended texlive-latex-extra + sudo apt-get install -y pandoc + sudo apt-get install -y texlive-latex-base texlive-fonts-recommended texlive-latex-extra + + - name: List files (para debug) + run: ls -la - name: Convert specific file run: | - pandoc "Roteiro pitch.md" -o "Roteiro pitch.pdf" --pdf-engine=xelatex -V geometry:margin=1in + pandoc "RoteiroPitch.md" -o "RoteiroPitch.pdf" --pdf-engine=xelatex -V geometry:margin=1in - - name: Upload PDF as artifact - uses: actions/upload-artifact@v4 - with: - name: generated-pdf - path: "*.pdf" + - name: Commit PDF to repository + run: | + git config --local user.email "actions@gitea.com" + git config --local user.name "Gitea Actions" + git add "RoteiroPitch.pdf" + git diff --staged --quiet || git commit -m "Auto-generate PDF from Markdown" + git push