Skip to content

Commit 81c2180

Browse files
committed
beta versions
1 parent 5f12318 commit 81c2180

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

.github/workflows/main.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,14 @@ jobs:
2222
- uses: actions/setup-python@v5
2323
with:
2424
python-version: "3.12"
25-
25+
- name: Install dependencies
26+
id: set-version
27+
run: |
28+
VERSION=$(grep version pyproject.toml | cut -d= -f2 | tr -d '[:blank:]' | tr -d '"')
29+
[ $GITHUB_EVENT_NAME == 'push' ] && VERSION+=b && VERSION+=$(($(git tag -l "*$VERSION*" | cut -db -f2 | sort -n | tail -1)+1))
30+
[ $GITHUB_EVENT_NAME == 'release' ] && VERSION=${{ github.event.release.tag_name }} && VERSION=${VERSION/v/}
31+
echo VERSION = $VERSION
32+
sed -ie "s/version = .*/version = $VERSION/" pyproject.toml
2633
- name: Build release distributions
2734
run: |
2835
# NOTE: put your own distribution build steps here.

0 commit comments

Comments
 (0)