-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (49 loc) · 1.48 KB
/
Copy pathdocs.yml
File metadata and controls
59 lines (49 loc) · 1.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
name: Documentation
on:
push:
branches: [main]
pull_request:
branches: [main, develop]
permissions:
contents: read
pages: write
id-token: write
# Keyed by ref so concurrent PR doc builds do not serialize behind each other,
# while repeated pushes to the same branch still supersede one another.
concurrency:
group: pages-${{ github.ref }}
cancel-in-progress: false
jobs:
# Job id is `docs` so it satisfies the required status check of that name.
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v4
with:
version: "latest"
- name: Set up Python
run: uv python install 3.11
- name: Install dependencies
run: uv sync --extra docs
# --strict fails on broken internal links, which is how the dangling
# agent-page links were caught rather than shipped.
- name: Build docs
run: uv run mkdocs build --strict
- name: Upload artifact
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
uses: actions/upload-pages-artifact@v3
with:
path: ./site
deploy:
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: docs
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4