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: Generate PDF from Markdown | ||
on: | ||
push: | ||
branches: | ||
- main | ||
jobs: | ||
run_commands: | ||
runs-on: s0-notes | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v2 # This step checks out your repository code | ||
- name: Convert & Store | ||
run: | | ||
Check failure on line 16 in .github/workflows/generate-pdf.yaml GitHub Actions / Generate PDF from MarkdownInvalid workflow file
|
||
export fileName="$(echo "${{ github.event.head_commit.message }}" | sed 's/update: //; s/\.md$//')" | ||
export fileNameMD="$(echo "${{ github.event.head_commit.message }}" | sed 's/update: //')" | ||
export fileNamePDF="$(echo "${{ github.event.head_commit.message }}" | sed 's/update: //; s/\.md$//').pdf" | ||
pandoc "./topics/${{fileNameMD}}" -o "./assets/pdf/$}}fileNamePDF}}" | ||
- name: Commit PDF | ||
run: | | ||
git add "./assets/pdf/${{fileNamePDF}}" | ||
git commit -m "pdf: ${{fileName}}" | ||
git push origin main |