Skip to content

Commit

Permalink
chore: conditional publish
Browse files Browse the repository at this point in the history
  • Loading branch information
shortcuts committed Dec 25, 2024
1 parent 98a6eb8 commit 5b0bc62
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,10 +109,8 @@ jobs:
- build
if: |
always() &&
startsWith(github.event.head_commit.message, 'chore: release') &&
!contains(needs.*.result, 'cancelled') &&
!contains(needs.*.result, 'failure') &&
github.ref == 'refs/heads/master'
!contains(needs.*.result, 'failure')
steps:
- uses: actions/checkout@v4

Expand All @@ -132,4 +130,7 @@ jobs:
run: python -m build

- name: Publish algoliasearch package to PyPI
if: |
github.ref == 'refs/heads/master' &&
startsWith(github.event.head_commit.message, 'chore: release')
uses: pypa/gh-action-pypi-publish@release/v1

0 comments on commit 5b0bc62

Please sign in to comment.