Skip to content

Commit

Permalink
Merge pull request #1933 from minrk/trusted
Browse files Browse the repository at this point in the history
trusted-publisher only runs on linux
  • Loading branch information
minrk authored Feb 17, 2024
2 parents 15ea96b + 2fa2f37 commit 3af356b
Showing 1 changed file with 14 additions and 13 deletions.
27 changes: 14 additions & 13 deletions .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,6 @@ env:

jobs:
sdist:
permissions:
id-token: write
# environment: release
runs-on: ubuntu-22.04

steps:
Expand Down Expand Up @@ -58,14 +55,7 @@ jobs:
run:
pytest -v tools/test_sdist.py

- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
if: startsWith(github.ref, 'refs/tags/')

wheel:
permissions:
id-token: write
# environment: release
runs-on: ${{ matrix.os || 'ubuntu-22.04' }}
name: wheel-${{ matrix.name }}

Expand Down Expand Up @@ -174,8 +164,19 @@ jobs:
path: "wheelhouse/*"
if-no-files-found: error

upload-pypi:
permissions:
id-token: write
environment: release
runs-on: ubuntu-22.04
if: startsWith(github.ref, 'refs/tags/')
needs:
- sdist
- wheel
steps:
- uses: actions/download-artifact@v4
with:
path: dist
merge-multiple: true
- name: Publish wheels to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
if: startsWith(github.ref, 'refs/tags/')
with:
packages-dir: wheelhouse/

0 comments on commit 3af356b

Please sign in to comment.