From fdea992bbe79d8b3484418a1c1aeae04a1598b59 Mon Sep 17 00:00:00 2001 From: p1c2u Date: Sun, 11 Feb 2024 12:47:08 +0000 Subject: [PATCH] Publish python package to pypi with trusted publishers --- .github/workflows/python-publish.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index e6bf50dc..ce6df4e1 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -12,6 +12,8 @@ on: jobs: publish: runs-on: ubuntu-latest + permissions: + id-token: write steps: - uses: actions/checkout@v4 @@ -27,7 +29,6 @@ jobs: run: poetry build - name: Publish - env: - POETRY_HTTP_BASIC_PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }} - POETRY_HTTP_BASIC_PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }} - run: poetry publish + uses: pypa/gh-action-pypi-publish@release/v1 + with: + packages-dir: dist/