Skip to content

Commit f443fc9

Browse files
authored
Updated PyPI publish workflow (#2)
Signed-off-by: Eric Reinecke <[email protected]>
1 parent be463b5 commit f443fc9

File tree

1 file changed

+13
-11
lines changed

1 file changed

+13
-11
lines changed

.github/workflows/deploy_package.yaml

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,22 +9,24 @@ jobs:
99
deploy:
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/checkout@v2
12+
- uses: actions/checkout@v3
1313
- name: Set up Python
14-
uses: actions/setup-python@v2
14+
uses: actions/setup-python@v4
1515
with:
1616
python-version: '3.x'
1717
- name: Install dependencies
1818
run: |
19-
python -m pip install --upgrade pip build twine
20-
- name: Build and publish
21-
env:
22-
TWINE_USERNAME: __token__
23-
# You need to add a token to your repo's secrets
24-
# Make sure you match the name of your secret to the token name below.
25-
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
19+
python -m pip install build
20+
- name: Build dist package
2621
run: |
2722
python -m build
23+
- name: Upload Built Artifacts
24+
uses: actions/upload-artifact@v3
25+
with:
26+
name: dist
27+
path: |
28+
./dist/*.whl
29+
./dist/*.gz
30+
- name: Publish package distributions to PyPI
31+
uses: pypa/gh-action-pypi-publish@release/v1
2832

29-
# Make sure everything works on testpypi before releasing on pypi
30-
twine upload --repository pypi dist/*

0 commit comments

Comments
 (0)