-
Notifications
You must be signed in to change notification settings - Fork 2
37 lines (36 loc) · 1.2 KB
/
docs.yml
File metadata and controls
37 lines (36 loc) · 1.2 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
name: docs
on:
push:
branches:
- main
jobs:
docs:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@fa2e9d605c4eeb9fcad4c99c224cee0c6c7f3594 # v2.16.0
with:
egress-policy: audit
- name: Install Build Tools
run: |
curl -sSL https://install.python-poetry.org | python
echo $HOME/.poetry/bin >> $GITHUB_PATH
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.10"
- name: Install Python Requirements
run: |
poetry install
- name: Build Docs
run: |
poetry run sphinx-apidoc -H "API Reference" -o docs/api_reference recline
poetry run sphinx-build -b html docs build/html
- name: Publish Docs
uses: JamesIves/github-pages-deploy-action@d92aa235d04922e8f08b40ce78cc5442fcfbfa2f # v4.8.0
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH: gh-pages
FOLDER: build/html