Skip to content

Commit def1c06

Browse files
authored
ci: derive prerelease NuGet version dynamically from project version
1 parent 42f32f1 commit def1c06

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

.github/workflows/prerelease.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,9 @@ jobs:
1919

2020
- name: Determine prerelease version
2121
run: |
22+
BASE_VERSION=$(grep -oPm1 "(?<=<Version>)[^<]+" src/Directory.Build.props)
2223
COMMIT_SHA=$(git rev-parse --short HEAD)
23-
echo "PRERELEASE_VERSION=11.0.0-${COMMIT_SHA}" >> $GITHUB_ENV
24+
echo "PRERELEASE_VERSION=${BASE_VERSION}-${COMMIT_SHA}" >> $GITHUB_ENV
2425
2526
- name: Setup .NET
2627
uses: actions/setup-dotnet@v1

0 commit comments

Comments
 (0)