Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .github/workflows/publish-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,14 @@ jobs:
with:
python-version: "3.12"

- name: Pin version from tag on release builds
if: startsWith(github.ref, 'refs/tags/')
run: |
VERSION="${GITHUB_REF_NAME#v}"
echo "Using tagged version: $VERSION"
echo "SETUPTOOLS_SCM_PRETEND_VERSION=$VERSION" >> "$GITHUB_ENV"
shell: bash

- name: Ensure clean tree before build
run: |
git diff --quiet || (git status --short && git diff && exit 1)
Expand Down
Loading