Skip to content

Commit 7f8bcf7

Browse files
committed
Add GitHub Actions workflows for MkDocs build validation and GitHub Pages deploy
- add a CI workflow to build the MkDocs site on pull requests and pushes to main/hot-fix - install Python 3.10 and project dev dependencies in CI using the repo pyproject configuration - validate sanitize output with tools/sanitize.py --check before site build - validate generated visual docs are up to date with tools/docs/build_visual_docs.py --check - run pytest before building docs to keep the docs pipeline aligned with repo quality gates - build the MkDocs site with strict mode enabled and upload the generated site directory as a workflow artifact - add a separate GitHub Pages deployment workflow for pushes to main and manual runs - configure official GitHub Pages actions permissions and deployment environment - publish the built site from the generated site directory to GitHub Pages using the actions-based Pages flow - 2026-02-22 17:28:32
1 parent ef7c366 commit 7f8bcf7

3 files changed

Lines changed: 117 additions & 0 deletions

File tree

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
name: MkDocs Pages Deploy
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
concurrency:
15+
group: "pages"
16+
cancel-in-progress: true
17+
18+
jobs:
19+
build:
20+
runs-on: ubuntu-latest
21+
22+
steps:
23+
- name: Checkout repository
24+
uses: actions/checkout@v4
25+
26+
- name: Set up Python
27+
uses: actions/setup-python@v5
28+
with:
29+
python-version: "3.10"
30+
31+
- name: Install dependencies
32+
run: |
33+
python -m pip install --upgrade pip setuptools wheel
34+
python -m pip install -e ".[dev]"
35+
36+
- name: Validate visual sanitization
37+
run: python tools/sanitize.py --check
38+
39+
- name: Validate generated visual docs
40+
run: python tools/docs/build_visual_docs.py --check
41+
42+
- name: Run tests
43+
run: python -m pytest -q
44+
45+
- name: Build MkDocs site
46+
run: mkdocs build --strict
47+
48+
- name: Configure GitHub Pages
49+
uses: actions/configure-pages@v5
50+
51+
- name: Upload Pages artifact
52+
uses: actions/upload-pages-artifact@v3
53+
with:
54+
path: site/
55+
56+
deploy:
57+
environment:
58+
name: github-pages
59+
url: ${{ steps.deployment.outputs.page_url }}
60+
runs-on: ubuntu-latest
61+
needs: build
62+
63+
steps:
64+
- name: Deploy to GitHub Pages
65+
id: deployment
66+
uses: actions/deploy-pages@v4
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: MkDocs Site Build
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- hot-fix
8+
pull_request:
9+
10+
permissions:
11+
contents: read
12+
13+
jobs:
14+
build-mkdocs-site:
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- name: Checkout repository
19+
uses: actions/checkout@v4
20+
21+
- name: Set up Python
22+
uses: actions/setup-python@v5
23+
with:
24+
python-version: "3.10"
25+
26+
- name: Install dependencies
27+
run: |
28+
python -m pip install --upgrade pip setuptools wheel
29+
python -m pip install -e ".[dev]"
30+
31+
- name: Validate visual sanitization
32+
run: python tools/sanitize.py --check
33+
34+
- name: Validate generated visual docs
35+
run: python tools/docs/build_visual_docs.py --check
36+
37+
- name: Run tests
38+
run: python -m pytest -q
39+
40+
- name: Build MkDocs site
41+
run: mkdocs build --strict
42+
43+
- name: Upload site artifact
44+
uses: actions/upload-artifact@v4
45+
with:
46+
name: mkdocs-site
47+
path: site/
48+
if-no-files-found: error

CODING_AGENTS.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,7 @@
2323
- When the user asks for a commit message, provide plain text for direct paste into the terminal or UI text box.
2424
- Do not wrap commit message suggestions in quotes (`"`), backticks (`` ` ``), or code fences unless the user explicitly asks for that format.
2525
- Prefer detailed commit messages that describe the current change set clearly.
26+
- Do not default to a one-line commit message when the change set is broad; provide a title plus concise bullet points.
2627
- Avoid redundant wording and avoid repeating the exact prior commit message suggestion unless the diff is unchanged and the user explicitly asks to reuse it.
28+
- If the user asks for "in a text box", return plain text only (no markdown fence).
29+
- If the user asks for "in a markdown text box", return the commit message inside a fenced code block with `text`.

0 commit comments

Comments
 (0)