Skip to content

Commit 2341e29

Browse files
committed
ci(docs): add GitHub Pages workflow for automated documentation deployment
1 parent 0bc6644 commit 2341e29

1 file changed

Lines changed: 56 additions & 0 deletions

File tree

.github/workflows/docs.yml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: Docs
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
paths:
8+
- "docs/**"
9+
- "mkdocs.yml"
10+
- ".github/workflows/docs.yml"
11+
12+
permissions:
13+
pages: write
14+
id-token: write
15+
16+
concurrency:
17+
group: pages
18+
cancel-in-progress: false
19+
20+
jobs:
21+
build:
22+
runs-on: ubuntu-latest
23+
steps:
24+
- uses: actions/checkout@v6
25+
26+
- name: Install uv
27+
uses: astral-sh/setup-uv@v7
28+
with:
29+
enable-cache: true
30+
31+
- name: Set up Python
32+
uses: actions/setup-python@v6
33+
with:
34+
python-version: "3.12"
35+
36+
- name: Install dependencies
37+
run: uv sync --group docs
38+
39+
- name: Build docs
40+
run: uv run mkdocs build --strict
41+
42+
- name: Upload artifact
43+
uses: actions/upload-pages-artifact@v4
44+
with:
45+
path: site
46+
47+
deploy:
48+
needs: build
49+
runs-on: ubuntu-latest
50+
environment:
51+
name: github-pages
52+
url: ${{ steps.deployment.outputs.page_url }}
53+
steps:
54+
- name: Deploy to GitHub Pages
55+
id: deployment
56+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)