From 4714fafa0ac8fbac392f2bbdd380c83fe9d82f56 Mon Sep 17 00:00:00 2001 From: Peter Corke Date: Tue, 13 Oct 2026 11:23:28 +1000 Subject: [PATCH] ci: deploy the docs with the Pages actions The repository's Pages setting serves a GitHub Actions deployment, but the docs job pushed to the gh-pages branch, which is not served: the live site was last built in January 2025 and has no 1.0 pages, nor llms.txt. The job now uploads the build as a Pages artifact and deploys it, as ansitable and bdsim do, to the github-pages environment (deployable from main). Co-Authored-By: Claude Sonnet 5.5 --- .github/workflows/ci.yml | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4718bd4d..8af21b81 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -85,6 +85,15 @@ jobs: if: github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && github.ref == 'refs/heads/main') needs: unittest runs-on: ubuntu-latest + # The site is served from a GitHub Pages deployment, not from the gh-pages + # branch, so the artifact is deployed with the Pages actions. + permissions: + contents: read + pages: write + id-token: write + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} steps: - uses: actions/checkout@v7 - name: Set up Python 3.11 @@ -101,9 +110,12 @@ jobs: run: | make -C docs html llms touch docs/build/html/.nojekyll - - name: Deploy docs to gh-pages - uses: peaceiris/actions-gh-pages@v4 + - name: Setup Pages + uses: actions/configure-pages@v6 + - name: Upload artifact + uses: actions/upload-pages-artifact@v5 with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_branch: gh-pages - publish_dir: ./docs/build/html + path: docs/build/html + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v5