Skip to content

Commit 0ca7006

Browse files
authored
Update pythonpublish.yml
1 parent e16cb9d commit 0ca7006

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

.github/workflows/pythonpublish.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
# This workflows will upload a Python Package using pypa/gh-action-pypi-publish@master when a release is created
22
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
33

4-
name: Publish Python 🐍 distributions 📦 to PyPI
4+
name: Publish Python 🐍 distributions 📦 to PyPI and TestPyPI
55

66
on:
77
release:
88
types: [created]
99

1010
jobs:
1111
build-n-publish:
12-
name: Build and publish Python 🐍 distributions 📦 to PyPI
12+
name: Build and publish Python 🐍 distributions 📦 to PyPI and TestPyPI
1313
runs-on: ubuntu-18.04
1414
steps:
1515
- uses: actions/checkout@master
16-
- name: Set up Python 3.x
16+
- name: Set up Python 3.7
1717
uses: actions/setup-python@v1
1818
with:
1919
python-version: 3.x
@@ -24,11 +24,15 @@ jobs:
2424
- name: Build a binary wheel and a source tarball
2525
run: |
2626
python setup.py sdist bdist_wheel
27+
- name: Publish distribution 📦 to Test PyPI
28+
uses: pypa/gh-action-pypi-publish@master
29+
with:
30+
user: __token__
31+
password: ${{ secrets.test_pypi_password }}
32+
repository_url: https://test.pypi.org/legacy/
2733
- name: Publish distribution 📦 to PyPI
2834
if: startsWith(github.event.ref, 'refs/tags')
2935
uses: pypa/gh-action-pypi-publish@master
3036
with:
3137
user: __token__
3238
password: ${{ secrets.pypi_password }}
33-
34-

0 commit comments

Comments
 (0)