[DNM] GH action to execute tutorials #1
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Execute Tutorial Notebooks | |
on: | |
push: | |
paths: | |
- 'docs/tutorials/**.ipynb' | |
- .github/workflows/tutorials.yml | |
pull_request: | |
branches: | |
- main | |
- test-tutorials | |
workflow_dispatch: | |
jobs: | |
test-notebooks: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
- name: Set up virtual environment | |
run: | | |
python -m venv env | |
source env/bin/activate | |
python -m pip install --upgrade pip | |
pip install docs/tutorials/requirements.txt | |
shell: bash | |
- name: Execute tutorial notebooks | |
run: | | |
jupyter execute docs/tutorials/*.ipynb | |
shell: bash |