Debian Codegraph @

.github/workflows/docs.yml

raw
1 name: Build docs
2
3 on: [push, pull_request]
4
5 permissions:
6 contents: read
7
8 jobs:
9 build:
10 runs-on: ubuntu-latest
11
12 steps:
13 - uses: actions/checkout@v6
14 - name: Set up Python
15 uses: actions/setup-python@v6
16 with:
17 python-version: 3.x
18 cache: pip
19 cache-dependency-path: |
20 docs/requirements.txt
21 pyproject.toml
22 - name: Install uv
23 uses: astral-sh/setup-uv@v7
24 - name: Install Graphviz
25 run: |
26 sudo apt-get update
27 sudo apt-get install graphviz
28 - name: Install Python dependencies
29 run: |
30 uv pip install --system setuptools coverage rstvalidator
31 uv pip install --system -r docs/requirements.txt
32 - name: Build docs
33 run: |
34 python -m rstvalidator long_description.rst
35 python tools/fixup_whats_new_pr.py
36 make -C docs/ html SPHINXOPTS="-W" \
37 PYTHON="coverage run -a" \
38 SPHINXBUILD="coverage run -a -m sphinx.cmd.build"
39 - name: Generate coverage xml
40 run: |
41 coverage combine `find . -name .coverage\*` && coverage xml
42 - name: Upload coverage to Codecov
43 uses: codecov/codecov-action@v5
44 with:
45 name: Docs