Skip to content

Commit

Permalink
Build script change so the .exe gets it's version number set
Browse files Browse the repository at this point in the history
  • Loading branch information
kees2125 committed Sep 13, 2019
1 parent 824348c commit 45cb56b
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions build.ps1
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
function New-Package($version) {
New-SharedAssemblyInfo $version
dotnet pack --output ../../built --configuration Release /p:PackageVersion="$($version.FullSemVer)" /p:NoPackageAnalysis=true
}

Expand All @@ -21,16 +20,18 @@ using System.Runtime.InteropServices;
}


$version = git-flow-version | ConvertFrom-Json
Write-Host "calculated version:"
$version | Format-List

Remove-Item built -Force -Recurse -ErrorAction SilentlyContinue
Remove-Item doc/index.md -Force -Recurse -ErrorAction SilentlyContinue
Remove-Item doc/_site -Force -Recurse -ErrorAction SilentlyContinue
Remove-Item doc/obj -Force -Recurse -ErrorAction SilentlyContinue
dotnet clean
dotnet restore
New-SharedAssemblyInfo $version
dotnet build --configuration Release .\src\Tring.WinExe\Tring.WinExe.csproj /p:OutputPath="..\..\built"
dotnet test /p:CollectCoverage=true /p:Exclude=[xunit.*]* /p:CoverletOutput='../../built/Tring.xml' /p:CoverletOutputFormat=cobertura

$version = git-flow-version | ConvertFrom-Json
Write-Host "calculated version:"
$version | Format-List
New-Package $version

0 comments on commit 45cb56b

Please sign in to comment.