From a7a16f4ed62a59408f399836bd729e619eb99edb Mon Sep 17 00:00:00 2001 From: "Gavin M. Roy" Date: Fri, 3 Apr 2026 14:42:26 -0400 Subject: [PATCH] Add docs build to CI and GitHub Pages deploy workflow - Add docs job to testing.yaml that runs mkdocs build --strict - Remove paths-ignore so docs-only PRs still get CI - Add docs.yaml workflow to deploy to GitHub Pages on push to main (when docs/ or rejected/ change), on release, or manually Co-Authored-By: Claude Opus 4.6 (1M context) --- .github/workflows/docs.yaml | 59 ++++++++++++++++++++++++++++++++++ .github/workflows/testing.yaml | 25 +++++++++++--- 2 files changed, 80 insertions(+), 4 deletions(-) create mode 100644 .github/workflows/docs.yaml diff --git a/.github/workflows/docs.yaml b/.github/workflows/docs.yaml new file mode 100644 index 0000000..708804b --- /dev/null +++ b/.github/workflows/docs.yaml @@ -0,0 +1,59 @@ +name: Deploy Docs + +on: + push: + branches: [main] + paths: + - 'docs/**' + - 'mkdocs.yml' + - 'rejected/**' + release: + types: [published] + workflow_dispatch: + +permissions: + contents: read + pages: write + id-token: write + +concurrency: + group: pages + cancel-in-progress: false + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v5 + + - name: Install uv + uses: astral-sh/setup-uv@v6 + with: + python-version: "3.13" + + - name: Install dependencies + run: uv sync --all-groups + env: + UV_CONFIG_FILE: /dev/null + + - name: Build docs + run: uv run mkdocs build --strict + env: + UV_CONFIG_FILE: /dev/null + + - name: Upload artifact + uses: actions/upload-pages-artifact@v3 + with: + path: site + + deploy: + needs: build + runs-on: ubuntu-latest + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v4 diff --git a/.github/workflows/testing.yaml b/.github/workflows/testing.yaml index a705960..cc51d7b 100644 --- a/.github/workflows/testing.yaml +++ b/.github/workflows/testing.yaml @@ -3,13 +3,30 @@ on: pull_request: push: branches: [main] - paths-ignore: - - 'docs/**' - - '*.md' - - '*.rst' tags-ignore: ["*"] jobs: + docs: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v5 + + - name: Install uv + uses: astral-sh/setup-uv@v6 + with: + python-version: "3.13" + + - name: Install dependencies + run: uv sync --all-groups + env: + UV_CONFIG_FILE: /dev/null + + - name: Build docs + run: uv run mkdocs build --strict + env: + UV_CONFIG_FILE: /dev/null + test: runs-on: ubuntu-latest strategy: