-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
59 lines (50 loc) · 1.56 KB
/
build-doc.yml
File metadata and controls
59 lines (50 loc) · 1.56 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: Build Documentation
on:
push:
branches:
- migrate-to-gh-actions
pull_request:
branches:
- migrate-to-gh-actions
jobs:
build-doc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
python-version: "3.9"
- name: Install system dependencies
run: sudo apt-get update && sudo apt-get install rename
- name: Install doc dependencies
run: |
cd doc
uv venv
uv pip install -r requirements.txt
- name: Install plotly in editable mode
if: github.ref_name != 'doc-prod'
run: |
cd doc
uv pip install -e ..
- name: List installed packages
run: |
cd doc
uv pip list
- name: Build HTML docs
env:
MAPBOX_TOKEN: ${{ secrets.MAPBOX_TOKEN }}
run: |
cd doc
source .venv/bin/activate
echo "${MAPBOX_TOKEN}" > python/.mapbox_token
make -kj8 || make -kj8
curl https://raw.githubusercontent.com/plotly/graphing-library-docs/master/front-matter-ci.py > front-matter-ci.py
curl https://raw.githubusercontent.com/plotly/graphing-library-docs/master/check-or-enforce-order.py > check-or-enforce-order.py
python front-matter-ci.py build/html
python check-or-enforce-order.py build/html
- name: Upload docs artifact
uses: actions/upload-artifact@v4
with:
name: doc-build
path: doc/build/html/