use commit count as revision number

This commit is contained in:
Krzysztof Wicher 2016-01-11 15:41:37 -08:00 committed by Bryan Thornbury
parent 797e436547
commit f88c9a88f2
2 changed files with 3 additions and 5 deletions

View file

@ -8,10 +8,9 @@ $MajorVersion = 1
$MinorVersion = 0
$PatchVersion = 0
#TODO @krwq is working on this
$CommitCountVersion = 0
$CommitCountVersion = (git rev-list --count HEAD).PadLeft(6, "0")
# Zero Padded Suffix for use with Nuget
$VersionSuffix = "$ReleaseSuffix-{0:D6}" -f $CommitCountVersion
$VersionSuffix = "$ReleaseSuffix-$CommitCountVersion"
$env:DOTNET_BUILD_VERSION = "$MajorVersion.$MinorVersion.$PatchVersion.$CommitCountVersion"

View file

@ -9,7 +9,6 @@ export MAJOR_VERSION=1
export MINOR_VERSION=0
export PATCH_VERSION=0
#TODO @krwq is working on this
export COMMIT_COUNT_VERSION=0
export COMMIT_COUNT_VERSION=$(printf "%06d" $(git rev-list --count HEAD))
export DOTNET_BUILD_VERSION=$MAJOR_VERSION.$MINOR_VERSION.$PATCH_VERSION.$COMMIT_COUNT_VERSION