Skip to content

fix: correct mobile layout, stale pins and the pages left behind by t… #17

fix: correct mobile layout, stale pins and the pages left behind by t…

fix: correct mobile layout, stale pins and the pages left behind by t… #17

Workflow file for this run

name: Deploy site
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
permissions:
contents: read
jobs:
# The reference pages describe behaviour that lives in the commit-check
# repository, so they can drift without anything here changing. This job
# reads both and fails when they disagree.
docs-sync:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v7
with:
persist-credentials: false
- uses: actions/setup-python@v7
with:
python-version: '3.x'
# The released package, deliberately unpinned. This site documents the
# version a reader can actually install, so the check is only meaningful
# against that — pinning would let the two drift apart silently until
# somebody bumped the pin.
#
# This used to install from main, because the rule IDs the site documents
# were merged but unreleased and PyPI would have reported a spurious
# mismatch. v2.13.0 shipped them, so the exception is over. If a future
# release is documented here ahead of time, point this back at main for
# as long as that is true, and no longer.
- name: Install the released commit-check
run: |
python -m pip install --upgrade pip
python -m pip install pytest commit-check
- name: Check the docs against the package
run: pytest tests/ -q
build:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v7
with:
persist-credentials: false
- uses: actions/setup-python@v7
with:
python-version: '3.x'
# The social plugin renders the share cards through cairo, which cairosvg
# loads at runtime rather than bundling.
- name: Install cairo
run: sudo apt-get install -y --no-install-recommends libcairo2
- name: Build site
run: pipx run nox -s docs
- name: Upload site as pages artifact
uses: actions/upload-pages-artifact@v5
with:
name: ${{ github.event.repository.name }}_site
path: ${{ github.workspace }}/site
deploy:
if: github.ref == 'refs/heads/main'
runs-on: ubuntu-24.04
needs: [build]
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v5
with:
artifact_name: ${{ github.event.repository.name }}_site