Skip to content

Commit a7d4cd7

Browse files
author
Vladimir Vilimaitis
committed
Consolidate PyPI publishing in release workflow
1 parent a23bf88 commit a7d4cd7

2 files changed

Lines changed: 7 additions & 30 deletions

File tree

.github/workflows/publish.yml

Lines changed: 0 additions & 27 deletions
This file was deleted.

.github/workflows/release.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
workflow_dispatch:
55
push:
66
tags:
7+
# Version tags build wheels/sdist, verify artifacts, publish to PyPI, then create a GitHub release.
78
- "v*"
89

910
permissions:
@@ -188,18 +189,21 @@ jobs:
188189
needs: artifact-check
189190
if: startsWith(github.ref, 'refs/tags/')
190191
runs-on: ubuntu-latest
191-
environment: pypi
192+
environment:
193+
name: pypi
194+
url: https://pypi.org/project/polars-janitor/
192195
permissions:
193196
contents: read
194-
id-token: write
197+
id-token: write # Required for PyPI trusted publishing.
195198

196199
steps:
197200
- uses: actions/download-artifact@v4
198201
with:
199202
path: dist
200203
merge-multiple: true
201204

202-
- uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b
205+
- name: Publish distributions to PyPI
206+
uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b
203207
with:
204208
packages-dir: dist
205209

0 commit comments

Comments
 (0)