aboutsummaryrefslogtreecommitdiff
path: root/script/build.ps1
diff options
context:
space:
mode:
Diffstat (limited to 'script/build.ps1')
-rw-r--r--script/build.ps112
1 files changed, 9 insertions, 3 deletions
diff --git a/script/build.ps1 b/script/build.ps1
index d236421c..13f6831d 100644
--- a/script/build.ps1
+++ b/script/build.ps1
@@ -1,4 +1,5 @@
-function CheckLastExitCode {
+function CheckLastExitCode
+{
if ($LASTEXITCODE -ne 0)
{
exit $LASTEXITCODE
@@ -11,5 +12,10 @@ vcpkg.exe install folly:x64-windows fmt:x64-windows
vcpkg.exe integrate install
& CheckLastExitCode
-& "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\MSBuild.exe" CruUI.sln /target:Rebuild /p:Platform=x64 /p:Configuration=Debug
-& CheckLastExitCode
+& "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\MSBuild.exe" CruUI.sln /target:Build /p:Platform=x64 /p:Configuration=Debug
+
+if ($LASTEXITCODE -ne 0)
+{
+ & "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\MSBuild.exe" CruUI.sln /target:Rebuild /p:Platform=x64 /p:Configuration=Debug
+ & CheckLastExitCode
+}