Skip to content

Multiple adjastments of most of MD-files in repo #33

Multiple adjastments of most of MD-files in repo

Multiple adjastments of most of MD-files in repo #33

name: MD to PDF
on:
push:
branches: [ master ]
# Paths can be used to only trigger actions when you have edited certain files
paths:
- 'CV/*.md'
- 'CV/*.css'
- '.github/workflows/convert-md-to-pdf.yml'
workflow_dispatch:
jobs:
convert-to-pdf:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Generate PDF from MD
run: curl -v --data-urlencode "markdown=$(cat CV/Andrei_Punko_CV_\(eng\).md)" -d "css=$(cat CV/style.css)" --output CV/pdf/Andrei_Punko_CV_\(eng\).pdf https://md-to-pdf.fly.dev
- name: Commit the PDF (if it changed)
run: |
if [[ `git status --porcelain` ]]; then
git config --global user.name 'Github workflow'
git config --global user.email 'nowhere@gmail.com'
git add -A
git commit -m "Autogenerated CV in PDF"
git push
fi