-
-
Notifications
You must be signed in to change notification settings - Fork 0
30 lines (30 loc) · 1.09 KB
/
documentation.yaml
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
name: Documentation
on: [ push, workflow_dispatch ]
jobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.8
uses: actions/[email protected]
with:
python-version: "3.8"
- name: Install dependencies
run: pip3 install -r requirements.txt
- name: Install dev-dependencies
run: pip install toml && python -c 'import toml; c = toml.load("pyproject.toml");print("\n".join(c["tool"]["poetry"]["dev-dependencies"]))' | pip install -r /dev/stdin
- name: Build Documentation
run: cd docs && make html && cd ..
- name: Upload Documentation to Artifacts
uses: actions/upload-artifact@v4
with:
name: documentation
path: docs/_build/html
- name: Deploy
uses: peaceiris/actions-gh-pages@v4
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
with:
publish_branch: gh-pages
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/_build/html
force_orphan: true