File tree Expand file tree Collapse file tree 2 files changed +16
-6
lines changed
Expand file tree Collapse file tree 2 files changed +16
-6
lines changed Original file line number Diff line number Diff line change 3131$ErrorActionPreference = " Stop"
3232$msgColor = @ {Default = " White" ; Heading = " Cyan" ; Danger = " Red" ; Success = " Green" ; Attention = " Yellow" }
3333$BuildConfiguration = ' Release'
34+ $DefaultCIBuildSuffix = ' ci'
3435
3536function Die ($message ) {
3637 Write-Host " >>> ERROR:`t $message `n " - ForegroundColor $msgColor.Danger
@@ -90,7 +91,6 @@ if($DebugBuild)
9091if ($BuildNumber -eq 0 -and $PullRequestNumber -eq 0 ) { Die " Build Number or Pull Request Number must be supplied" }
9192if (! (Test-Path " version.props" )) { Die " Unable to locate required file: version.props" }
9293$outputPath = " $PSScriptRoot \.nupkgs"
93- $queryBuilderPath = " $PSScriptRoot \QueryBuilder\QueryBuilder.csproj"
9494$stdSwitches = " /p:Configuration=$BuildConfiguration /nologo /verbosity:d /p:BuildNumber=$BuildNumber "
9595
9696if ($SourceLinkEnable )
@@ -99,6 +99,16 @@ if($SourceLinkEnable)
9999}
100100
101101$versionProps = [xml ](Get-Content " version.props" )
102+
103+ if ($Env: APPVEYOR_REPRO_TAG )
104+ {
105+ if ([string ]::IsNullOrWhiteSpace($versionProps.Project.PropertyGroup.VersionSuffix ))
106+ {
107+ $versionProps.Project.PropertyGroup.VersionSuffix = $DefaultCIBuildSuffix
108+ $versionProps.Save (" $PSScriptRoot \version.props" )
109+ }
110+ }
111+
102112$versionPrefix = $versionProps.Project.PropertyGroup.VersionPrefix
103113$versionSuffix = $versionProps.Project.PropertyGroup.VersionSuffix
104114
Original file line number Diff line number Diff line change 11<Project >
2- <PropertyGroup >
3- <VersionPrefix >1.1.7</VersionPrefix >
4- <VersionSuffix ></VersionSuffix >
5- </PropertyGroup >
6- </Project >
2+ <PropertyGroup >
3+ <VersionPrefix >1.1.7</VersionPrefix >
4+ <VersionSuffix ></VersionSuffix >
5+ </PropertyGroup >
6+ </Project >
You can’t perform that action at this time.
0 commit comments