build: Update Pandoc and TinyTeX installation in workflow #14
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: update README files | |
on: | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
docs: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write # Required for pushing changes to the repository | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install asdf & tools | |
uses: asdf-vm/actions/setup@v3 | |
- name: Install Pandoc & TinyTeX | |
run: | | |
asdf plugin add pandoc | |
asdf install pandoc latest | |
asdf global pandoc latest | |
pandoc --version | |
asdf plugin add tinytex | |
asdf install tinytex latest | |
asdf global tinytex latest | |
- name: Install Pandoc Filters | |
run: make docs-install | |
- uses: actions/setup-node@v4 | |
- name: Install Mermaid-CLI | |
run: | | |
mkdir ~/.npm-global | |
npm config set prefix '~/.npm-global' | |
export PATH=~/.npm-global/bin:$PATH | |
npm install -g @mermaid-js/mermaid-cli | |
- name: Generate README | |
run: make docs | |
- name: Commit and Push Changes | |
run: | | |
git config --local user.email "${{ github.actor }}@users.noreply.github.com" | |
git config --local user.name "${{ github.actor }}" | |
git add README.md README.pdf | |
git diff --cached --quiet || git commit -m "Update README files" | |
git push origin main |