Skip to content
Snippets Groups Projects
Commit ef16995a authored by Wassim KABALAN's avatar Wassim KABALAN
Browse files

publish to pypi on release

parent 9e2a24d6
No related branches found
No related tags found
No related merge requests found
......@@ -6,9 +6,9 @@ on:
push:
branches:
- main
# release:
# types:
# - published
release:
types:
- published
jobs:
build_wheels:
......@@ -52,9 +52,9 @@ jobs:
environment: pypi
permissions:
id-token: write
# if: github.event_name == 'release' && github.event.action == 'published'
if: github.event_name == 'release' && github.event.action == 'published'
# or, alternatively, upload to PyPI on every tag starting with 'v' (remove on: release above to use this)
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
# if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
steps:
- uses: actions/download-artifact@v4
with:
......@@ -66,3 +66,4 @@ jobs:
- uses: pypa/gh-action-pypi-publish@release/v1
#with:
# repository-url: https://test.pypi.org/legacy/
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment