Skip to content

ci: find file instead of using a temp buffer #5

ci: find file instead of using a temp buffer

ci: find file instead of using a temp buffer #5

Workflow file for this run

name: Update repository
on: [push, workflow_dispatch]
jobs:
find-talks:
name: Find all talks
runs-on: ubuntu-latest
outputs:
pdfs: ${{ steps.find-pdfs.outputs.matrix }}
orgs: ${{ steps.find-orgs.outputs.matrix }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Find all PDF talks
id: find-pdfs
run: |
find . -name 'index.pdf' \
| xargs dirname \
| xargs basename -a \
| jq -R \
| jq -cs '{ "talk": . }' \
> matrix.json
echo "matrix=$(cat matrix.json)" >> $GITHUB_OUTPUT
- name: Find all Org-mode talks
id: find-orgs
run: |
find . -name 'index.org' \
| xargs dirname \
| xargs basename -a \
| jq -R \
| jq -cs '{ "talk": . }' \
> matrix.json
echo "matrix=$(cat matrix.json)" >> $GITHUB_OUTPUT
build-pdfs:
name: Build PDF talks
needs:
- find-talks
strategy:
matrix: ${{ fromJson(needs.find-talks.outputs.pdfs) }}
uses: ./.github/workflows/build-pdf.yml
with:
name: ${{ matrix.talk }}
build-orgs:
name: Build Org-mode talks
needs:
- find-talks
strategy:
matrix: ${{ fromJson(needs.find-talks.outputs.orgs) }}
uses: ./.github/workflows/build-org.yml
with:
name: ${{ matrix.talk }}