Skip to content

Bump actions/checkout from 4 to 5 #45

Bump actions/checkout from 4 to 5

Bump actions/checkout from 4 to 5 #45

Workflow file for this run

name: Tests
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
tests:
strategy:
matrix:
typst-version: ["0.12", "0.13", "latest"]
# the docs don't need to build with all versions supported by the package;
# the latest one is enough
# include:
# - typst-version: "0.13"
# doc: 1
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Probe runner package cache
uses: awalsh128/cache-apt-pkgs-action@v1
with:
packages: imagemagick cargo
version: 1.0
- name: Install oxipng from crates.io
uses: baptiste0928/cargo-install@v3
with:
crate: oxipng
- name: Install just from crates.io
uses: baptiste0928/cargo-install@v3
with:
crate: just
- name: Install tytanic from crates.io
uses: baptiste0928/cargo-install@v3
with:
crate: tytanic
- name: Setup typst
id: setup-typst
uses: typst-community/setup-typst@v4
with:
typst-version: ${{ matrix.typst-version }}
allow-prereleases: true
- name: Run test suite
run: just test
- name: Archive diffs
uses: actions/upload-artifact@v4
if: always()
with:
# "latest" and an explicitly specified version might be the same, so
# be sure not to create filename conflicts here
name: typst-${{ matrix.typst-version }}-${{ steps.setup-typst.outputs.typst-version }}-diffs
path: |
tests/**/diff/*.png
tests/**/out/*.png
tests/**/ref/*.png
retention-days: 5
- name: Build docs
if: ${{ matrix.doc }}
run: just doc