-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (42 loc) · 1.23 KB
/
test_tutorial.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
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Test tutorial and publish website
on:
- push
jobs:
test_tutorial:
name: Check tutorial
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install Claster requirements
run: |
pip install numpy pandas matplotlib jupyter ipykernel eir-dl
- name: Run papermill for cmd-line execution of notebooks
run: |
pip install papermill
- name: Test Tutorial
run: |
cd scripts
papermill 0_Tutorial.ipynb 0_Tutorial_out.ipynb -p epochs 4
website:
name: Publish notebooks as website
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install dependencies
run: |
pip install sphinx sphinx-book-theme myst-nb
- name: Build website
run: |
cd docs
sphinx-build -n --keep-going -b html ./ ./_build/
- name: Publish workflow as website
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/_build