-
Notifications
You must be signed in to change notification settings - Fork 18
33 lines (30 loc) · 941 Bytes
/
docs.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
31
32
33
name: Generate Pages
on:
push:
branches:
- update-docs
permissions:
id-token: write
contents: write
pages: write
jobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Install uv
uses: astral-sh/setup-uv@v5
- name: Turn script into notebook
run: |
uv run --extra docs python -m ipykernel install --name daisy_env --user
uv run --extra docs jupytext --to notebook --execute ./docs/source/notebooks/tutorial.py --output ./docs/source/notebooks/tutorial.ipynb
rm ./docs/source/notebooks/tutorial.py
- name: Build
run: uv run --extra docs sphinx-build docs/source/ docs/build/html -b html
- name: Set permissions
run: chmod -R a+rX ./docs/build/html
- name: Update gh branch
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/build/html