Updates build to set build version

[#88]
This commit is contained in:
Chris Cheetham 2019-11-22 10:43:45 -05:00
Родитель 35db529045
Коммит b34c5acda5
5 изменённых файлов: 9 добавлений и 9 удалений

Просмотреть файл

@ -56,8 +56,12 @@ jobs:
$env:PackageVersion = $env:PackageVersionOverride
}
Write-Host "build version set to $env:PackageVersion"
$prefix = $env:PackageVersion.Split('-')[0]
$suffix = $env:PackageVersion.Split('-')[1]
Write-Host "##vso[build.updatebuildnumber]$env:PackageVersion"
Write-Host "##vso[task.setvariable variable=PackageVersion;]$env:PackageVersion"
Write-Host "##vso[task.setvariable variable=VersionPrefix;]$prefix"
Write-Host "##vso[task.setvariable variable=VersionSuffix;]$suffix"
env:
PackageVersion: $(PackageVersion)
PackageVersionOverride: $(PackageVersionOverride)
@ -67,7 +71,7 @@ jobs:
inputs:
command: 'pack'
packagesToPack: '$(Solution).sln'
arguments: '--configuration Release /p:Version=$(ProductVersion) /p:TreatWarningsAsErrors=True'
arguments: '--configuration $(buildConfiguration) /p:TreatWarningsAsErrors=True /p:VersionPrefix=$(VersionPrefix) /p:VersionSuffix=$(VersionSuffix)'
versioningScheme: 'byEnvVar'
versionEnvVar: 'PackageVersion'
- task: 'DotNetCoreCLI@2'

Просмотреть файл

@ -1,7 +1,5 @@
<Project>
<PropertyGroup>
<SteeltoeVersion>$(STEELTOE_VERSION)</SteeltoeVersion>
<SteeltoeVersionSuffix>$(STEELTOE_DASH_VERSION_SUFFIX)</SteeltoeVersionSuffix>
<LightBDDXUnit2Version>2.4.3</LightBDDXUnit2Version>
<McMasterExtensionsCommandLineUtilsVersion>2.2.5</McMasterExtensionsCommandLineUtilsVersion>
<MicrosoftExtensionsVersion>2.1.1</MicrosoftExtensionsVersion>

Просмотреть файл

@ -1,7 +1,5 @@
<Project>
<PropertyGroup>
<SteeltoeVersion>$(STEELTOE_VERSION)</SteeltoeVersion>
<SteeltoeVersionSuffix>$(STEELTOE_DASH_VERSION_SUFFIX)</SteeltoeVersionSuffix>
<LightBDDXUnit2Version>2.4.3</LightBDDXUnit2Version>
<McMasterExtensionsCommandLineUtilsVersion>2.2.5</McMasterExtensionsCommandLineUtilsVersion>
<MicrosoftExtensionsVersion>2.1.1</MicrosoftExtensionsVersion>

Просмотреть файл

@ -11,8 +11,8 @@
<PackageProjectUrl>https://steeltoe.io</PackageProjectUrl>
<PackageTags>Docker, CloudFoundry</PackageTags>
<PackageLicense>https://www.apache.org/licenses/LICENSE-2.0</PackageLicense>
<VersionPrefix>$(SteeltoeVersion)</VersionPrefix>
<VersionSuffix>$(SteeltoeVersionSuffix)</VersionSuffix>
<VersionPrefix>$(VersionPrefix)</VersionPrefix>
<VersionSuffix>$(VersionSuffix)</VersionSuffix>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="McMaster.Extensions.CommandLineUtils" Version="$(McMasterExtensionsCommandLineUtilsVersion)" />

Просмотреть файл

@ -9,8 +9,8 @@
<PackageProjectUrl>https://steeltoe.io</PackageProjectUrl>
<PackageTags>Docker, CloudFoundry</PackageTags>
<PackageLicense>https://www.apache.org/licenses/LICENSE-2.0</PackageLicense>
<VersionPrefix>$(SteeltoeVersion)</VersionPrefix>
<VersionSuffix>$(SteeltoeVersionSuffix)</VersionSuffix>
<VersionPrefix>$(VersionPrefix)</VersionPrefix>
<VersionSuffix>$(VersionSuffix)</VersionSuffix>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="McMaster.Extensions.CommandLineUtils" Version="$(McMasterExtensionsCommandLineUtilsVersion)" />