diff --git a/.github/workflows/static.yml b/.github/workflows/static.yml index dd08a07..36504fe 100644 --- a/.github/workflows/static.yml +++ b/.github/workflows/static.yml @@ -1,11 +1,13 @@ name: Deploy Sphinx to GitHub Pages on: - # Runs on pushes targeting the default branch push: branches: ["main", "master"] - # Allows you to run this workflow manually from the Actions tab + pull_request: + types: + ["opened", "reopened", "synchronize"] + workflow_dispatch: # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages @@ -26,8 +28,6 @@ jobs: steps: - name: Checkout uses: actions/checkout@v4 - - name: Set up Pages - uses: actions/configure-pages@v5 - uses: actions/setup-python@v5 name: Set up Python with: @@ -41,19 +41,23 @@ jobs: uv venv uv sync --all-extras make html + - name: Set up Pages + uses: actions/configure-pages@v5 - name: Upload artifact uses: actions/upload-pages-artifact@v3 with: # Upload entire repository path: 'build/html' - deploy: - runs-on: ubuntu-latest - needs: build - environment: - name: github-pages - url: ${{ steps.deployment.outputs.page_url }} - steps: - - name: Deploy to GitHub Pages - id: deployment - uses: actions/deploy-pages@v4 - + +# deploy: +# runs-on: ubuntu-latest +# needs: build +# environment: +# name: github-pages +# url: ${{ steps.deployment.outputs.page_url }} +# steps: +# - name: Deploy to GitHub Pages +# id: deployment +# if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master' +# uses: actions/deploy-pages@v4 +#