Skip to content

Commit 264087f

Browse files
committed
Update appveyor build scripts
1 parent 8d976f7 commit 264087f

File tree

2 files changed

+6
-17
lines changed

2 files changed

+6
-17
lines changed

.appveyor.yml

Lines changed: 6 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -22,28 +22,18 @@ clone_depth: 1
2222

2323
init:
2424
- ps: |
25-
if ($env:APPVEYOR_REPO_TAG_NAME) {
26-
$headers = @{
25+
If ($Env:APPVEYOR_REPO_TAG_NAME -match "-"){
26+
$headers = @{
2727
"Authorization" = "Bearer $env:GITHUB_TOKEN"
2828
"Content-type" = "application/json"
2929
}
3030
$releases = Invoke-RestMethod -Uri "https://api.github.com/repos/$env:APPVEYOR_REPO_NAME/releases" -Headers $headers -Method GET
3131
$env:releaseDescription = ($releases | Where-Object {$_.name -eq "$env:APPVEYOR_REPO_TAG_NAME"}).body
32-
if ($env:APPVEYOR_REPO_TAG_NAME -like "-") {
33-
$env:isPrerelease = "true"
34-
} else {
35-
$env:isPrerelease = "false"
36-
}
37-
32+
Set-AppveyorBuildVariable -Name "IsPreRelease" -Value True
33+
}
34+
Else{
35+
Set-AppveyorBuildVariable -Name "IsPreRelease" -Value False
3836
}
39-
40-
- ps: |
41-
If ($Env:APPVEYOR_REPO_TAG_NAME -match "-"){
42-
Set-AppveyorBuildVariable -Name "IsPreRelease" -Value True
43-
}
44-
Else{
45-
Set-AppveyorBuildVariable -Name "IsPreRelease" -Value False
46-
}
4737
4838
environment:
4939
global:
@@ -131,7 +121,6 @@ deploy:
131121
prerelease: $(IsPreRelease)
132122
artifact: Zip, NuGet
133123
auth_token: $(GITHUB_TOKEN)
134-
artifact: /.*\.nupkg/
135124
draft: true
136125
force_update: true
137126
on:
File renamed without changes.

0 commit comments

Comments
 (0)