Use Actions to publish to PyPI

This commit is contained in:
Inada Naoki 2022-05-25 12:10:47 +09:00
parent a34dc945bf
commit caadbf2df5
2 changed files with 12 additions and 1 deletions

View file

@ -42,3 +42,8 @@ jobs:
run: |
MSGPACK_PUREPYTHON=1 pytest -v test
- name: Publish Wheels to TestPyPI
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_API_TOKEN }}

View file

@ -43,9 +43,15 @@ jobs:
CIBW_ARCHS_MACOS: x86_64 universal2 arm64
CIBW_SKIP: pp*
- name: Upload Wheels
- name: Upload Wheels to artifact
uses: actions/upload-artifact@v1
with:
name: Wheels
path: wheelhouse
- name: Publish Wheels to TestPyPI
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages_dir: wheelhouse
password: ${{ secrets.PYPI_API_TOKEN }}