Skip to content

Commit

Permalink
update release pipeline to use oidc issued tokens
Browse files Browse the repository at this point in the history
  • Loading branch information
cedric05 authored Feb 6, 2024
1 parent f3bef75 commit 2963c3e
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ env:
jobs:
deploy:
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/dothttp-req
permissions:
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
steps:
- uses: actions/checkout@v2
- name: Set up Python
Expand All @@ -35,13 +40,11 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
- name: Build and publish
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
- name: Build
run: |
cd dothttp
python setup.py sdist bdist_wheel
python setup.py sdist sdist
ls -alh dist
twine upload dist/*
- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1

0 comments on commit 2963c3e

Please sign in to comment.