Skip to content

Commit c431ae7

Browse files
committed
Use only the first 10 chars of the commit hash in the package version
1 parent fbd2345 commit c431ae7

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

.github/workflows/Lucene-Net-Performance-Regression.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,8 @@ jobs:
8282
shell: pwsh
8383
run: |
8484
$commit = "${{ matrix.commit }}"
85-
$packageVersion = "${{ github.event.inputs.base_version }}-${{ steps.calc.outputs.build_number }}-g$commit"
85+
$gitCommit = "$commit".SubString(0, 10)
86+
$packageVersion = "${{ github.event.inputs.base_version }}-${{ steps.calc.outputs.build_number }}-g$gitCommit"
8687
8788
# Compute FileVersion (just the numeric part)
8889
$fileVersion = $packageVersion.Split('-')[0]
@@ -95,7 +96,6 @@ jobs:
9596
}
9697
9798
# Compute InformationalVersion (with git hash)
98-
$gitCommit = "$commit".SubString(0, 10)
9999
if ($LASTEXITCODE -eq 0 -and $gitCommit) {
100100
$informationalVersion = "$packageVersion commit:[$gitCommit]"
101101
} else {

0 commit comments

Comments
 (0)