File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,9 +2,9 @@ name: Run Python Tests
22
33on :
44 push :
5- branches : [ "master ", "staging"]
5+ branches : [ "main ", "staging"]
66 pull_request :
7- branches : [ "master ", "staging" ]
7+ branches : [ "main ", "staging" ]
88
99permissions :
1010 contents : read
Original file line number Diff line number Diff line change 1+ name : " Publish"
2+
3+ on :
4+ push :
5+ branches : [ "main", "staging"]
6+ pull_request :
7+ branches : [ "main", "staging" ]
8+
9+ jobs :
10+ run :
11+ runs-on : ubuntu-latest
12+ environment :
13+ name : pypi
14+ permissions :
15+ id-token : write
16+ contents : read
17+ steps :
18+ - name : Checkout
19+ uses : actions/checkout@v6
20+ - name : Install uv
21+ uses : astral-sh/setup-uv@v7
22+ - name : Install Python 3.13
23+ run : uv python install 3.13
24+ - name : Build
25+ run : uv build
26+ # Check that basic features work and we didn't miss to include crucial files
27+ - name : Smoke test (wheel)
28+ run : uv run --isolated --no-project --with dist/*.whl pytest
29+ - name : Smoke test (source distribution)
30+ run : uv run --isolated --no-project --with dist/*.tar.gz pytest
31+ - name : Publish
32+ run : uv publish --index testpypi
Original file line number Diff line number Diff line change @@ -60,3 +60,9 @@ dev = [
6060 " mypy>=1.19.1" ,
6161 " pytest>=9.0.2" ,
6262]
63+
64+ [[tool .uv .index ]]
65+ name = " testpypi"
66+ url = " https://test.pypi.org/simple/"
67+ publish-url = " https://test.pypi.org/legacy/"
68+ explicit = true
You can’t perform that action at this time.
0 commit comments