Browse files

Fix Appveyor release tag detection

  • Loading branch information...
roji committed Sep 9, 2018
1 parent 7ad70bf commit 7f925d6cb9f738c18db3ada4f08de2d49e171f95
Showing with 7 additions and 2 deletions.
  1. +7 −2 .build/setup_appveyor.ps1
@@ -23,9 +23,14 @@ iex ".\$env:POSTGIS_EXE /S /D='C:\Program Files\PostgreSQL\10'"
Set-Variable -Name TruncatedSha1 -Value $env:APPVEYOR_REPO_COMMIT.subString(0, 9)
if ($env:APPVEYOR_REPO_TAG -eq 'true' -and $env:APPVEYOR_REPO_TAG_NAME -match '^v\d+\.\d+\.\d+')
if ($env:APPVEYOR_REPO_TAG -eq 'true' -and $env:APPVEYOR_REPO_TAG_NAME -match '^v\d+\.\d+\.\d+(-(\w+))?')
Write-Host "Release tag detected ($env:APPVEYOR_REPO_TAG_NAME), no version suffix is set."
if ($matches[2]) {
Write-Host "Prerelease tag detected ($env:APPVEYOR_REPO_TAG_NAME), version suffix set to $($matches[2])."
Set-AppveyorBuildVariable -Name VersionSuffix -Value $matches[2]
} else {
Write-Host "Release tag detected ($env:APPVEYOR_REPO_TAG_NAME), no version suffix will be set."
Set-AppveyorBuildVariable -Name deploy_github_release -Value true

0 comments on commit 7f925d6

Please sign in to comment.