File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2020
2121 steps :
2222 - uses : actions/checkout@v6
23- - uses : jdx/mise-action@v4
23+ - uses : astral-sh/setup-uv@v8.2.0
2424
2525 - name : Validate release is stable
2626 env :
3333 fi
3434 VERSION="${TAG#v}"
3535 if echo "$VERSION" | grep -Eq '(^|[.-])[ab]([0-9]|$)|(^|[.-])rc[0-9]'; then
36- echo "Pre-release versions (a/b/rc) are not published to PyPI: $VERSION"
36+ echo "Pre-release versions are not published to PyPI: $VERSION"
3737 exit 1
3838 fi
3939 PYPROJECT_VERSION=$(python -c "import tomllib; print(tomllib.load(open('pyproject.toml','rb'))['project']['version'])")
4242 exit 1
4343 fi
4444
45- - name : Publish to PyPI
46- env :
47- UV_PUBLISH_TRUSTED_PUBLISHING : " always"
48- run : mise run publish pypi
45+ - name : Build and Publish to PyPI
46+ run : |
47+ uv build --wheel --clear
48+ VERSION=$(python -c "import tomllib; print(tomllib.load(open('pyproject.toml','rb'))['project']['version'])")
49+ WHEEL=$(find dist -maxdepth 1 -name "*-${VERSION}-*.whl" -print | head -n 1)
50+ uv publish --trusted-publishing always "$WHEEL"
You can’t perform that action at this time.
0 commit comments