Skip to content

Commit

Permalink
feat: Use PyPI Trusted Publisher
Browse files Browse the repository at this point in the history
  • Loading branch information
abhinand-c committed Dec 9, 2023
1 parent 5c4a5b7 commit f138a57
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,9 @@ jobs:
publish:
needs: build
runs-on: ubuntu-latest

permissions:
# IMPORTANT: this permission is mandatory for trusted publishing
id-token: write
steps:
- uses: actions/checkout@v3
- name: Set up Python
Expand All @@ -49,7 +51,11 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install poetry
- name: Build & Release package
- name: Build package
run: |
poetry build
- name: Build package
run: |
poetry config pypi-token.pypi ${{ secrets.PYPI_API_TOKEN }}
poetry publish --build
poetry build
- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1

0 comments on commit f138a57

Please sign in to comment.