Skip to content

Commit b7df2b8

Browse files
committed
workflow to publish verda package to PyPI, with Trusted publishing
1 parent d015bf2 commit b7df2b8

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

.github/workflows/publish.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: "Publish verda to PyPI"
2+
3+
# TODO(shamrin) switch to tags or releases
4+
on:
5+
pull_request:
6+
7+
jobs:
8+
deploy:
9+
runs-on: ubuntu-24.04
10+
11+
environment:
12+
name: pypi
13+
14+
permissions:
15+
id-token: write
16+
contents: read
17+
18+
steps:
19+
- uses: actions/checkout@v5
20+
21+
- name: Install uv
22+
uses: astral-sh/setup-uv@v7
23+
with:
24+
version: "0.9.11"
25+
26+
- name: Set up Python
27+
run: uv python install
28+
29+
- name: Build
30+
run: uv build
31+
32+
# check that basic features work and we didn't miss to include crucial files
33+
- name: Smoke test (wheel)
34+
run: uv run --isolated --no-project --with dist/*.whl tests/unit_tests/test_client.py
35+
36+
- name: Smoke test (source distribution)
37+
run: uv run --isolated --no-project --with dist/*.tar.gz tests/unit_tests/test_client.py
38+
39+
# we use Trusted publishing, no keys necessary: https://docs.astral.sh/uv/guides/integration/github/#publishing-to-pypi
40+
- name: Publish
41+
run: uv publish
42+

0 commit comments

Comments
 (0)