Add GitHub Actions deploy workflow for Jupyter Book #1
This file contains hidden or 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: Deploy Jupyter Book to GitHub Pages | |
| on: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| deploy: | |
| 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.10' | |
| - name: 📦 Install dependencies | |
| run: | | |
| pip install -U pip | |
| pip install jupyter-book ghp-import | |
| - name: 🏗️ Build the Jupyter Book | |
| run: | | |
| jupyter-book build . | |
| - name: 🚀 Deploy to GitHub Pages | |
| run: | | |
| ghp-import -n -p -f _build/html |