Skip to content

Commit 8455181

Browse files
mpcabdclaude
andcommitted
Add GitHub Actions release workflow for PyPI publishing
Uses OIDC trusted publishing (no API token needed). Runs the full test matrix first, then builds and publishes on success. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 6d09e6b commit 8455181

1 file changed

Lines changed: 33 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Release
2+
3+
on:
4+
release:
5+
types: [published]
6+
7+
jobs:
8+
test:
9+
runs-on: ubuntu-latest
10+
strategy:
11+
fail-fast: true
12+
matrix:
13+
python-version: ["3.10", "3.11", "3.12", "3.13"]
14+
steps:
15+
- uses: actions/checkout@v4
16+
- uses: astral-sh/setup-uv@v5
17+
with:
18+
enable-cache: true
19+
- run: uv python install ${{ matrix.python-version }}
20+
- run: uv sync --group dev
21+
- run: uv run pytest
22+
23+
publish:
24+
needs: test
25+
runs-on: ubuntu-latest
26+
environment: pypi
27+
permissions:
28+
id-token: write
29+
steps:
30+
- uses: actions/checkout@v4
31+
- uses: astral-sh/setup-uv@v5
32+
- run: uv build
33+
- uses: pypa/gh-action-pypi-publish@release/v1

0 commit comments

Comments
 (0)