Skip to content

Commit 1c34186

Browse files
committed
try new version format
1 parent fb47071 commit 1c34186

File tree

1 file changed

+31
-3
lines changed

1 file changed

+31
-3
lines changed

.github/workflows/nightly-pypi-build.yml

Lines changed: 31 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,38 @@ on:
2525
workflow_dispatch: # Allows manual triggering
2626

2727
jobs:
28+
set-version:
29+
runs-on: ubuntu-latest
30+
outputs:
31+
VERSION: ${{ steps.set-version.outputs.VERSION }}
32+
steps:
33+
- uses: actions/checkout@v4
34+
with:
35+
fetch-depth: 1
36+
37+
- uses: actions/setup-python@v5
38+
with:
39+
python-version: 3.12
40+
41+
- name: Install Poetry
42+
run: make install-poetry
43+
44+
- name: Extract version from Poetry
45+
id: set-version
46+
run: |
47+
CURRENT_VERSION=$(poetry version --short)
48+
VERSION="${CURRENT_VERSION}.dev$(date +%Y%m%d)"
49+
echo "VERSION=$VERSION" >> "$GITHUB_OUTPUT"
50+
51+
- name: Debug version
52+
run: echo "Publishing version ${{ steps.set-version.outputs.VERSION }}"
53+
2854
nightly-build:
29-
uses: ./.github/workflows/pypi-build-artifacts.yml # Reference the PyPI build workflow
55+
needs: set-version
56+
uses: ./.github/workflows/pypi-build-artifacts.yml
3057
with:
31-
VERSION: "0.0.0" # Generate nightly version
32-
RC: "1" # Reset RC for nightly builds
58+
version: ${{ needs.set-version.outputs.VERSION }} # i.e. 0.9.0.dev20250203
59+
rc: "0" # Reset RC for nightly builds
3360

3461
testpypi-publish:
3562
name: Publish to TestPypi
@@ -56,3 +83,4 @@ jobs:
5683
with:
5784
repository-url: https://test.pypi.org/legacy/
5885
skip-existing: true
86+
verbose: true

0 commit comments

Comments
 (0)