ci: Only run pypi actions from the main repo
These will fail when run from forks because the necessary credentials aren't available.
This commit is contained in:
parent
1849ef6c48
commit
f5a1d5c7e2
|
@ -68,7 +68,7 @@ jobs:
|
||||||
name: Upload to PyPI (test)
|
name: Upload to PyPI (test)
|
||||||
needs: [build_wheels, build_sdist]
|
needs: [build_wheels, build_sdist]
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-22.04
|
||||||
if: github.event_name == 'push' && startsWith(github.ref_name, 'build-workflow')
|
if: github.repository == 'tornadoweb/tornado' && github.event_name == 'push' && startsWith(github.ref_name, 'build-workflow')
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
|
@ -86,7 +86,7 @@ jobs:
|
||||||
name: Upload to PyPI (prod)
|
name: Upload to PyPI (prod)
|
||||||
needs: [build_wheels, build_sdist]
|
needs: [build_wheels, build_sdist]
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-22.04
|
||||||
if: github.event_name == 'push' && github.ref_type == 'tag' && startsWith(github.ref_name, 'v')
|
if: github.repository == 'tornadoweb/tornado' && github.event_name == 'push' && github.ref_type == 'tag' && startsWith(github.ref_name, 'v')
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
|
|
Loading…
Reference in New Issue