From ed439d5bbdf265a9b1b7e146969a52bdd3280bca Mon Sep 17 00:00:00 2001 From: Juliya Smith Date: Fri, 6 Sep 2024 17:49:27 -0500 Subject: [PATCH] fix: action trigger --- action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/action.yml b/action.yml index b91b1b4..7cf9e60 100644 --- a/action.yml +++ b/action.yml @@ -39,7 +39,7 @@ runs: shell: bash - name: Commit and publish documentation changes to gh-pages branch - if: ${{ github.event_name }} != "pull_request" + if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' || github.event_name == 'release' }} run: | sphinx-ape publish . --skip-push git config --local user.email "action@github.com" @@ -49,7 +49,7 @@ runs: shell: bash - name: Push changes - if: ${{ github.event_name != 'pull_request' }} + if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' || github.event_name == 'release' }} uses: ad-m/github-push-action@master with: branch: gh-pages