Skip to content

Commit

Permalink
GitVersion
Browse files Browse the repository at this point in the history
- Use GitVersion to stamp version numbers into assemblies.

https://github.com/GitTools/GitVersion

Use GitVersioning variables to set NuGet package version properties.

Use Mainline versioning policy in GitVersion v4.0.0+.

- Bump next version to 1.2.x for easier reference.

`GitVersionTask` package version=`4.0.1-beta1-47`
  • Loading branch information
jthelin committed Nov 21, 2018
1 parent 22020e5 commit aef0901
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 5 deletions.
8 changes: 5 additions & 3 deletions GitVersion.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
assembly-versioning-scheme: Major
mode: ContinuousDelivery
next-version: 1.1.8
mode: Mainline
increment: Patch
next-version: 1.2.0
branches:
master:
tag: pre
tag: alpha
prevent-increment-of-merged-branch-version: true
1 change: 1 addition & 0 deletions ServerHost.sln
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Build", "Build", "{64DBC33D
Build.cmd = Build.cmd
Build.sh = Build.sh
Clean.cmd = Clean.cmd
GitVersion.yml = GitVersion.yml
nuget-restore.cmd = nuget-restore.cmd
Test.cmd = Test.cmd
Test.runsettings = Test.runsettings
Expand Down
8 changes: 6 additions & 2 deletions ServerHost/ServerHost.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

<PropertyGroup>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Version>1.1.17</Version>
<Version>$(NuGetVersion)</Version>
<Authors>Jorgen Thelin</Authors>
<Copyright>Copyright © Jorgen Thelin 2015-2018</Copyright>
<Description>ServerHost - A .NET Server Hosting utility library, including in-process server host testing.</Description>
Expand All @@ -23,7 +23,7 @@
<PackageTags>DotNet Server Host Testing AppDomain</PackageTags>
<RepositoryType>git</RepositoryType>
<RepositoryUrl>https://github.com/jthelin/ServerHost.git</RepositoryUrl>
<AssemblyVersion>1.1.0.0</AssemblyVersion>
<AssemblyVersion>$(AssemblySemVer)</AssemblyVersion>
</PropertyGroup>

<PropertyGroup Condition="'$(TRAVIS)' == 'true'">
Expand Down Expand Up @@ -51,6 +51,10 @@
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="log4net" Version="2.0.8" />
<PackageReference Include="GitVersionTask" Version="4.0.1-beta1-47">
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
</ItemGroup>

<ItemGroup Condition=" '$(Configuration)' == 'Release' ">
Expand Down

0 comments on commit aef0901

Please sign in to comment.