Skip to content

Commit 06546b5

Browse files
zarroboogsAniLeo
authored andcommitted
windows artifact versioning changes, plus a small syntax fix
1 parent ca9c167 commit 06546b5

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed

appveyor.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,19 @@ cache:
1616

1717
install:
1818
- ps: | # set env vars for versioning
19-
$commDate = $env:APPVEYOR_REPO_COMMIT_TIMESTAMP.Substring(0,10)
20-
$commHash = $env:APPVEYOR_REPO_COMMIT.Substring(0,8)
2119
$commTag = $(git describe --tags $(git rev-list --tags --max-count=1))
20+
$commCount = $(git rev-list --count HEAD)
21+
$commHash = $env:APPVEYOR_REPO_COMMIT.Substring(0,8)
22+
23+
if ($env:APPVEYOR_PULL_REQUEST_NUMBER) {
24+
$env:BUILD = "{0}-{1}" -f $commTag, $commHash
25+
}
26+
else {
27+
$env:BUILD = "{0}-{1}-{2}" -f $commTag, $commCount, $commHash
28+
}
2229
2330
$env:AVVER = "{0}-{1}" -f $commTag.TrimStart("v"), $env:APPVEYOR_BUILD_NUMBER
24-
$env:RPCS3 = "rpcs3-{0}-{1}-{2}_win64.7z" -f $commTag, $commDate, $commHash
31+
$env:RPCS3 = "rpcs3-{0}_win64.7z" -f $env:BUILD
2532
2633
- ps: | # used for experimental build warnings for pr builds
2734
$env:BRANCH = "{0}/{1}/#{2}" -f $env:APPVEYOR_REPO_NAME, `
@@ -80,7 +87,7 @@ after_build:
8087
C:\OpenSSL-Win64\bin\ssleay32.dll
8188
8289
- ps: | # generate sha256 hashes
83-
(get-filehash $env:RPCS3 -algorithm SHA256).Hash > "$env:RPCS3.sha256"
90+
(get-filehash $env:RPCS3 -algorithm SHA256).Hash > ("{0}.sha256" -f $env:RPCS3)
8491
(get-filehash openssl_win64.7z -algorithm SHA256).Hash > "openssl_win64.7z.sha256"
8592
8693
test: off

0 commit comments

Comments
 (0)