diff --git a/.github/workflows/deps.yml b/.github/workflows/deps.yml index 24b3a6301..707247b78 100644 --- a/.github/workflows/deps.yml +++ b/.github/workflows/deps.yml @@ -30,7 +30,7 @@ jobs: run: git diff --exit-code --compact-summary id: no_change - name: create branch - if: ${{ steps.no_change.conclusion == 'failure' }} + if: ${{ failure() && steps.no_change.conclusion == 'failure' }} run: | git config user.name 'github-actions[bot]' git config user.email 'github-actions[bot]@users.noreply.github.com' @@ -40,7 +40,7 @@ jobs: git commit -m "spack updates" git push -f --set-upstream origin github-bot/update_spackages - name: create pull request - if: ${{ steps.no_change.conclusion == 'failure' }} + if: ${{ failure() && steps.no_change.conclusion == 'failure' }} run: gh pr create -B main -H github-bot/update_spackages --title 'Update spackages' --body 'Created by Github action' env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}