Skip to content

init(branch): Init todo-list branch and related files #1

init(branch): Init todo-list branch and related files

init(branch): Init todo-list branch and related files #1

name: Convert TODO List
on:
push:
branches:
- todo-list
paths:
- TODO.md
jobs:
convert:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
ref: todo-list
- name: Install Pandoc
run: |
sudo apt-get install -y pandoc texlive-xetex
- name: Convert Markdown to PDF
run: |
pandoc TODO.md -o todo-list.pdf
- name: Move PDF to root directory
run: |
mv todo-list.pdf .
- name: Commit and push PDF
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add todo-list.pdf
git commit -m "Update TODO list PDF"
git push origin todo-list
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}