diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index f983c43..ae16cbf 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -7,8 +7,12 @@ on: jobs: deploy: runs-on: ubuntu-latest + environment: + name: pypi + url: https://pypi.org/p/repominify permissions: id-token: write + contents: read steps: - uses: actions/checkout@v3 with: @@ -31,6 +35,10 @@ jobs: python -m build - name: Publish to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - password: ${{ secrets.PYPI_TOKEN }} \ No newline at end of file + env: + TWINE_USERNAME: __token__ + TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }} + TWINE_REPOSITORY: pypi + run: | + echo "Using token starting with: ${TWINE_PASSWORD:0:7}..." + python -m twine upload --verbose dist/* \ No newline at end of file