File tree Expand file tree Collapse file tree 1 file changed +14
-20
lines changed Expand file tree Collapse file tree 1 file changed +14
-20
lines changed Original file line number Diff line number Diff line change 1515 tags : release
1616 branches : jac/pypi
1717
18- buildwheels :
18+ jobs :
19+ build-n-publish :
1920 name : Build dist files for PyPi
20- needs : createrelease
2121 runs-on : ubuntu-latest
2222 steps :
2323 - uses : actions/checkout@master
2828 - name : Build dist files
2929 run : |
3030 python -m pip install --upgrade pip
31- pip install -e
31+ pip install -e .[test]
3232 python setup.py sdist --formats=gztar,zip
33-
34- # This action assumes files exist in /dist unless told otherwise
35- # https://packaging.python.org/en/latest/guides/publishing-package-distribution-releases-using-github-actions-ci-cd-workflows/
36- publish :
37- - name : Publish distribution 📦 to Test PyPI
38- if : startsWith(environment, 'test')
39- needs : buildwheels
40- uses : pypa/gh-action-pypi-publish@release/v1 # license BSD-2
41- with :
42- password : ${{ secrets.TEST_PYPI_API_TOKEN }}
43- repository_url : https://test.pypi.org/legacy/
44- - name : Publish distribution 📦 to PyPI
45- if : startsWith(github.ref, 'refs/tags')
46- needs : buildwheels
47- uses : pypa/gh-action-pypi-publish@release/v1 # license BSD-2
48- with :
49- password : ${{ secrets.PYPI_API_TOKEN }}
33+ - name : Publish distribution 📦 to Test PyPI
34+ env :
35+ TEST_PYPI_API_TOKEN : ${{ secrets.TEST_PYPI_API_TOKEN }}
36+ uses : pypa/gh-action-pypi-publish@release/v1 # license BSD-2
37+ with :
38+ password : $TEST_PYPI_API_TOKEN
39+ repository_url : https://test.pypi.org/legacy/
40+ - name : Publish distribution 📦 to PyPI
41+ uses : pypa/gh-action-pypi-publish@release/v1 # license BSD-2
42+ with :
43+ password : ${{ secrets.PYPI_API_TOKEN_WRONG }}
You can’t perform that action at this time.
0 commit comments