-
Notifications
You must be signed in to change notification settings - Fork 2
52 lines (49 loc) · 1.24 KB
/
doc.yml
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
name: Update documentation
on:
push:
branches: ["main"]
workflow_dispatch:
permissions:
contents: write
id-token: write
pages: write
jobs:
build:
name: Build documentation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.10
uses: actions/setup-python@v1
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install .[doc]
- name: Build with Sphinx
run: cd doc && make html
- name: Upload documentation artifact
uses: actions/upload-artifact@v2
with:
name: documentation
path: ./doc/_build/html
upload:
name: Upload to GitHub pages
runs-on: ubuntu-latest
needs: build
steps:
- name: Download documentation artifact
uses: actions/download-artifact@v2
with:
name: documentation
path: ./html
- name: Setup Pages
uses: actions/configure-pages@v3
- name: Upload artifact
uses: actions/upload-pages-artifact@v2
with:
path: ./html
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2