Skip to content

Commit

Permalink
Fixing the nuget pacakge versioning for tags
Browse files Browse the repository at this point in the history
  • Loading branch information
soninaren committed Nov 27, 2018

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent fd6cde3 commit 086d0ec
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions build.ps1
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
param (
[string]$buildNumber = "0",
[string]$extensionVersion = "2.0.$buildNumber",
[bool]$includeVersion = $true
[bool]$includeSuffixVersion = $true
)

$currentDir = Split-Path -Parent $MyInvocation.MyCommand.Path
@@ -276,10 +276,13 @@ foreach ($project in $projects)
{
$cmd = "pack", "src\$project\$project.csproj", "-o", "..\..\buildoutput", "--no-build"

if ($includeVersion)
if ($includeSuffixVersion)
{
$cmd += "--version-suffix", "-$buildNumber"
}
else {
$cmd += "-p:PackageVersion=$extensionVersion"
}

& dotnet $cmd
}

0 comments on commit 086d0ec

Please sign in to comment.