From 1142a3a00ec28dfba22f33f399759ab8c21de16f Mon Sep 17 00:00:00 2001 From: Jeremy L <5149279+lymereJ@users.noreply.github.com> Date: Mon, 4 Dec 2023 14:34:44 -0800 Subject: [PATCH] Update publish.yml --- .github/workflows/publish.yml | 32 +++++++++++++++++++------------- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 9cfb491..bfcdb88 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,20 +1,26 @@ -name: Publish to PyPI.org +name: Upload Python Package on: release: types: [published] permissions: - id-token: write + contents: read jobs: - pypi: + deploy: runs-on: ubuntu-latest steps: - - name: Checkout - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - run: python3 -m pip install --upgrade build && python3 -m build - - name: Publish package - uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29 - with: - user: __token__ - password: ${{ secrets.PYPI_API_TOKEN }} + - uses: actions/checkout@v3 + - name: Set up Python + uses: actions/setup-python@v3 + with: + python-version: '3.x' + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install build + - name: Build package + run: python -m build + - name: Publish package + uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29 + with: + user: __token__ + password: ${{ secrets.PYPI_API_TOKEN }}