Skip to content

Commit 2ddfc67

Browse files
committed
Switched to trusted publishing
1 parent 3e6eb26 commit 2ddfc67

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

.github/workflows/build.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,9 @@ jobs:
9292

9393
python:
9494
runs-on: ubuntu-latest
95+
environment: pypi
96+
permissions:
97+
id-token: write
9598
steps:
9699

97100
- name: Checkout repository
@@ -113,11 +116,7 @@ jobs:
113116
run: python -m build
114117

115118
- name: Publish Python package
116-
if: github.event_name == 'release'
117-
env:
118-
PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }}
119-
PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
120-
run: twine upload --disable-progress-bar -u ${PYPI_USERNAME} -p ${PYPI_PASSWORD} dist/*
119+
uses: pypa/gh-action-pypi-publish@release/v1
121120

122121
docker:
123122
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)