Fix usage of upload-pages-artifact action #3
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: Build docs | |
| on: push | |
| jobs: | |
| build: | |
| name: Build Docs | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@master | |
| - name: Build docs | |
| uses: actions/setup-python@master | |
| with: | |
| python-version: "3.12" | |
| - run: | | |
| make install-optional | |
| cd docs | |
| make install-deps | |
| make build | |
| - name: Upload static files as artifact | |
| # We only execute this step if the commit is tagged, i.e., this is a release | |
| #if: startsWith(github.ref, 'refs/tags') | |
| id: deployment | |
| uses: actions/upload-pages-artifact@v4 | |
| with: | |
| path: build/html/ | |
| deploy: | |
| name: Deploy docs | |
| needs: build | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| # We only execute this step if the commit is tagged, i.e., this is a release | |
| #if: startsWith(github.ref, 'refs/tags') | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |