File tree Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Original file line number Diff line number Diff line change 1- name : Publish Python distribution to PyPI and TestPyPI
1+ name : Publish to PyPI
22
3- on : push
3+ on :
4+ release :
5+ types : [published]
46
57jobs :
68 build-n-publish :
7- name : Build and Publish Python distribution to PyPI and TestPyPI
9+ name : Build and Publish to PyPI
810 runs-on : ubuntu-latest
11+ if : startsWith(github.ref, 'refs/tags')
912 steps :
1013 - uses : actions/checkout@master
1114 - name : Set up Python 3.10
1821 - name : Build a binary wheel and a source tarball
1922 run : >-
2023 python -m build --sdist --wheel --outdir dist/
21- - name : Publish Distribution to Test PyPI
22- uses : pypa/gh-action-pypi-publish@release/v1
23- with :
24- password : ${{ secrets.TESTPYPI_API_TOKEN }}
25- repository_url : https://test.pypi.org/legacy/
2624 - name : Publish Distribution to PyPI
27- if : startsWith(github.ref, 'refs/tags')
2825 uses : pypa/gh-action-pypi-publish@release/v1
2926 with :
3027 password : ${{ secrets.PYPI_API_TOKEN }}
You can’t perform that action at this time.
0 commit comments