This commit is contained in:
James Newton-King
2016-09-11 00:26:52 +12:00
parent 68d160f3c6
commit a297e6758e
+5 -3
View File
@@ -22,7 +22,8 @@
$workingDir = "$baseDir\$workingName"
$workingSourceDir = "$workingDir\Src"
$builds = @(
@{Name = "Newtonsoft.Json.Dotnet"; TestsName = "Newtonsoft.Json.Tests.Dotnet"; BuildFunction = "NetCliBuild"; TestsFunction = "NetCliTests"; Constants="dotnet"; FinalDir="netstandard1.0"; NuGetDir = "netstandard1.0"; Framework=$null},
@{Name = "Newtonsoft.Json.Dotnet"; TestsName = "Newtonsoft.Json.Tests.Dotnet"; BuildFunction = "NetCliBuild"; TestsFunction = "NetCliTests"; Constants="NETSTANDARD1_0"; FinalDir="netstandard1.0"; NuGetDir = "netstandard1.0"; Framework=$null},
@{Name = "Newtonsoft.Json.Dotnet"; TestsName = "Newtonsoft.Json.Tests.Dotnet"; BuildFunction = "NetCliBuild"; TestsFunction = "NetCliTests"; Constants="NETSTANDARD1_1"; FinalDir="netstandard1.1"; NuGetDir = "netstandard1.1"; Framework=$null},
@{Name = "Newtonsoft.Json"; TestsName = "Newtonsoft.Json.Tests"; BuildFunction = "MSBuildBuild"; TestsFunction = "NUnitTests"; Constants=""; FinalDir="Net45"; NuGetDir = "net45"; Framework="net-4.0"},
@{Name = "Newtonsoft.Json.Portable"; TestsName = "Newtonsoft.Json.Tests.Portable"; BuildFunction = "MSBuildBuild"; TestsFunction = "NUnitTests"; Constants="PORTABLE"; FinalDir="Portable"; NuGetDir = "portable-net45+wp80+win8+wpa81"; Framework="net-4.0"},
@{Name = "Newtonsoft.Json.Portable40"; TestsName = "Newtonsoft.Json.Tests.Portable40"; BuildFunction = "MSBuildBuild"; TestsFunction = "NUnitTests"; Constants="PORTABLE40"; FinalDir="Portable40"; NuGetDir = "portable-net40+sl5+wp80+win8+wpa81"; Framework="net-4.0"},
@@ -203,6 +204,7 @@ function MSBuildBuild($build)
function NetCliBuild($build)
{
$name = $build.Name
$framework = $build.NuGetDir
$projectPath = "$workingSourceDir\Newtonsoft.Json\project.json"
exec { .\Tools\Dotnet\dotnet-install.ps1 -Version $netCliVersion | Out-Default }
@@ -212,8 +214,8 @@ function NetCliBuild($build)
Write-Host
exec { dotnet restore $projectPath | Out-Default }
Write-Host -ForegroundColor Green "Building $projectPath"
exec { dotnet build $projectPath -f netstandard1.0 -c Release -o bin\Release\netstandard1.0 | Out-Default }
Write-Host -ForegroundColor Green "Building $projectPath $framework"
exec { dotnet build $projectPath -f $framework -c Release -o bin\Release\$framework | Out-Default }
}
function NetCliTests($build)