-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild_and_tests.ps1
26 lines (18 loc) · 917 Bytes
/
build_and_tests.ps1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
param (
[string]$Configuration = "Debug"
)
$homeDirectory = $Env:HOME
if (!$homeDirectory) {
$homeDirectory = $Env:UserProfile
}
Write-Host $homeDirectory
$nugetPackageCacheDirectory = Join-Path -Path $homeDirectory -ChildPath ".nuget"
$nugetPackageCacheDirectory = Join-Path -Path $nugetPackageCacheDirectory -ChildPath "packages"
$nugetPackageCacheDirectory = Join-Path -Path $nugetPackageCacheDirectory -ChildPath "MSBuild.AdditionalTasks"
Write-Host $nugetPackageCacheDirectory
if ((Test-Path $nugetPackageCacheDirectory)) {
Get-ChildItem -Path $nugetPackageCacheDirectory -Recurse -Hidden | Remove-Item -Force
Remove-Item -Path $nugetPackageCacheDirectory -Force -Recurse
}
& dotnet build ./src/MSBuild.AdditionalTasks.sln /binaryLogger:msbuild.binlog /nodeReuse:false -c $Configuration
& dotnet build ./tests/Tests.sln /binaryLogger:msbuild.tests.binlog /nodeReuse:false -c $Configuration