forked from nil4/dotnet-transform-xdt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.ps1
19 lines (14 loc) · 1015 Bytes
/
build.ps1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
$ErrorActionPreference = 'Stop'
function step($command) {
Write-Host ([Environment]::NewLine + $command.ToString().Trim()) -ForegroundColor CYAN
& $command
if ($lastexitcode -ne 0) { throw $lastexitcode }
}
$Env:DOTNET_NOLOGO = 'true'
$Env:DOTNET_CLI_TELEMETRY_OPTOUT = 'true'
step { dotnet msbuild dotnet-xdt /t:Restore /p:Configuration=Release /p:As=lib /p:ContinuousIntegrationBuild=true }
step { dotnet msbuild dotnet-xdt /t:Pack /p:Configuration=Release /p:As=lib /p:ContinuousIntegrationBuild=true }
step { dotnet msbuild dotnet-xdt /t:Restore /p:Configuration=Release /p:As=tool /p:ContinuousIntegrationBuild=true }
step { dotnet msbuild dotnet-xdt /t:Pack /p:Configuration=Release /p:As=tool /p:ContinuousIntegrationBuild=true }
step { dotnet msbuild dotnet-xdt /t:Restore /p:Configuration=Release /p:As=exe /p:ContinuousIntegrationBuild=true }
step { dotnet msbuild dotnet-xdt /t:Build /p:Configuration=Release /p:As=exe /p:ContinuousIntegrationBuild=true }