From 6767a6802f621e220c2bfc144dc3344036231dd4 Mon Sep 17 00:00:00 2001 From: abcdefg30 Date: Sat, 18 Jan 2020 16:12:48 +0100 Subject: [PATCH] Fix make errors when there is no custom solution file --- make.ps1 | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/make.ps1 b/make.ps1 index bafecd2..850f4de 100644 --- a/make.ps1 +++ b/make.ps1 @@ -5,6 +5,11 @@ ############################################################### function All-Command { + If (!(Test-Path "*.sln")) + { + return + } + if ((CheckForDotnet) -eq 1) { return @@ -117,6 +122,12 @@ function Test-Command function Check-Command { + If (!(Test-Path "*.sln")) + { + Write-Host "No custom solution file found. Skipping static code checks." -ForegroundColor Cyan + return + } + Write-Host "Compiling in debug configuration..." -ForegroundColor Cyan dotnet build /p:Configuration=Debug /nologo if ($lastexitcode -ne 0)