Merge pull request #97 from CooperUnion/develop #117
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 | |
| on: | |
| push: | |
| branches: [ main ] | |
| # This is a new, required section for the official deploy action | |
| permissions: | |
| pages: write # to deploy to Pages | |
| id-token: write # to verify the deployment originates from an authentic source | |
| # This new concurrency block ensures that only one deployment runs at a time | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: false | |
| jobs: | |
| # Build job | |
| build: | |
| 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.x | |
| - name: Install dependencies | |
| run: | | |
| pip install -r arch134b_workshops/requirements.txt | |
| - name: Build the book | |
| run: | | |
| jupyter-book build arch134b_workshops | |
| - name: Upload artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| # This is the directory where the built HTML files are located | |
| path: arch134b_workshops/_build/html | |
| # Deploy job | |
| deploy: | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| runs-on: ubuntu-latest | |
| needs: build # This line is crucial - it says "run the build job first" | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |