CI hardening, accurate worker docs, announcement banner, 404 page #15
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: [ master ] | |
| paths-ignore: | |
| - 'README.md' | |
| - 'CONTRIBUTING.md' | |
| - 'LICENSE' | |
| pull_request: | |
| paths-ignore: | |
| - 'README.md' | |
| - 'CONTRIBUTING.md' | |
| - 'LICENSE' | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| concurrency: | |
| group: pages | |
| cancel-in-progress: false | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Setup Python | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: pip install -r requirements.txt | |
| - name: Build Jupyter Book | |
| run: jupyter-book build . --warningiserror | |
| - name: Check links | |
| # Informational: external links can be flaky, so this never blocks the build. | |
| continue-on-error: true | |
| run: jupyter-book build . --builder linkcheck | |
| - name: Setup Pages | |
| if: github.event_name == 'push' | |
| uses: actions/configure-pages@v6 | |
| - name: Upload artifact | |
| if: github.event_name == 'push' | |
| uses: actions/upload-pages-artifact@v5 | |
| with: | |
| path: _build/html | |
| deploy: | |
| needs: build | |
| if: github.event_name == 'push' && github.ref == 'refs/heads/master' | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v5 |