Skip to content

Commit

Permalink
chore: fixing cd.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
mdtanker committed Nov 23, 2023
1 parent d63dd4c commit 6fcf6d9
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ jobs:
url: https://pypi.org/p/invert4geom
permissions:
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
if: github.ref == 'refs/heads/main'
if:
github.ref == 'refs/heads/main' && needs.semantic-release.released ==
'true'
steps:
- name: Upload package to Test PyPI
with:
Expand All @@ -62,7 +64,9 @@ jobs:
url: https://pypi.org/p/invert4geom
permissions:
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
if: github.ref == 'refs/heads/main'
if:
github.ref == 'refs/heads/main' && needs.semantic-release.released ==
'true'
steps:
- name: Upload package to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
Expand All @@ -74,7 +78,9 @@ jobs:
permissions:
id-token: write
contents: write
if: needs.semantic-release.released == 'true'
if:
github.ref == 'refs/heads/main' && needs.semantic-release.released ==
'true'
needs: [semantic-release]
steps:
- uses: python-semantic-release/upload-to-gh-release@main
Expand Down

0 comments on commit 6fcf6d9

Please sign in to comment.