diff --git a/.github/workflows/check-and-publish.yml b/.github/workflows/check-and-publish.yml index 998fb13..71b9e7d 100644 --- a/.github/workflows/check-and-publish.yml +++ b/.github/workflows/check-and-publish.yml @@ -96,15 +96,11 @@ jobs: python -m pip install --upgrade pip pip install setuptools wheel twine + - name: Build package + run: python setup.py sdist --verbose + - name: Build and publish - env: - - # Create an account on https://pypi.org/ - # Add your user/password as secrets in the github repository. - # see https://docs.github.com/en/actions/reference/encrypted-secrets - TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} - TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} - - run: | - python setup.py sdist --verbose - twine upload dist/* --verbose + uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29 + with: + user: __token__ + password: ${{ secrets.PYPI_TOKEN }}