parcio: Add pending publications #17
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: [push, pull_request] | |
jobs: | |
latex: | |
name: LaTeX | |
runs-on: ubuntu-22.04 | |
timeout-minutes: 30 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
persist-credentials: false | |
- name: Install dependencies | |
run: | | |
sudo apt update || true | |
sudo apt --yes --no-install-recommends install texlive texlive-fonts-extra texlive-lang-german texlive-latex-extra texlive-plain-generic latexmk | |
sudo apt --yes --no-install-recommends install ghostscript imagemagick | |
- name: Allow PDF conversions | |
# FIXME Ubuntu has blocked PDF conversions in ImageMagick for security reasons | |
run: | | |
sudo sed --in-place '/disable ghostscript format types/,+6d' /etc/ImageMagick-6/policy.xml | |
- name: Configure Pages | |
uses: actions/configure-pages@v2 | |
- name: Build publications | |
run: | | |
latexmk -pdf publications.tex | |
- name: Create thumbnails | |
run: | | |
convert -colorspace sRGB -density 300 -thumbnail 1920x1920 -quality 90 -background white -alpha remove -alpha off 'publications.pdf[0]' publications.png | |
- name: Prepare directory | |
run: | | |
mkdir public | |
cp publications.pdf publications.png public/ | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v1 | |
with: | |
path: public | |
deploy: | |
name: Deploy | |
needs: latex | |
runs-on: ubuntu-22.04 | |
timeout-minutes: 30 | |
if: ${{ github.ref == 'refs/heads/master' }} | |
permissions: | |
pages: write | |
id-token: write | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
steps: | |
- name: Deploy Pages | |
id: deployment | |
uses: actions/deploy-pages@v1 |