From 64c9cb755a94c6710de3678500cfebe20f6a9b44 Mon Sep 17 00:00:00 2001 From: Zack Malkmus <112013308+zmalkmus@users.noreply.github.com> Date: Fri, 7 Jun 2024 14:36:07 -0400 Subject: [PATCH] Update pythonapp.yml --- .github/workflows/pythonapp.yml | 35 ++++++++++++++++++++++----------- 1 file changed, 23 insertions(+), 12 deletions(-) diff --git a/.github/workflows/pythonapp.yml b/.github/workflows/pythonapp.yml index 1863358..87f726d 100644 --- a/.github/workflows/pythonapp.yml +++ b/.github/workflows/pythonapp.yml @@ -12,12 +12,8 @@ jobs: uses: actions/setup-python@v5 with: python-version: "3.8" - - name: Install pypa/build - run: >- - python3 -m - pip install - build - --user + - name: Install pypa/build and twine + run: python3 -m pip install build twine - name: Build a binary wheel and a source tarball run: python3 -m build - name: Store the distribution packages @@ -25,7 +21,7 @@ jobs: with: name: python-package-distributions path: dist/ - + test: name: Run test suite needs: @@ -54,8 +50,23 @@ jobs: - test runs-on: ubuntu-latest steps: - - name: Publish Python dist to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - user: __token__ - password: ${{ secrets.PYPI_PASSWORD }} + - name: Checkout code + uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.8" + - name: Install twine + run: pip install twine + - name: Download distribution packages + uses: actions/download-artifact@v4 + with: + name: python-package-distributions + path: dist/ + - name: Check dist/ + run: twine check dist/* + - name: Publish Python dist to PyPI + run: twine upload dist/* + env: + TWINE_USERNAME: __token__ + TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}