From 1acdd86e27de16703fdb1c77f50ed8fd71bd3ad7 Mon Sep 17 00:00:00 2001 From: Alex Barney Date: Sat, 27 Mar 2021 21:18:58 -0700 Subject: [PATCH] Build: Fix clearing the last exit code --- build.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.ps1 b/build.ps1 index 60bc1df8..922a8030 100644 --- a/build.ps1 +++ b/build.ps1 @@ -30,7 +30,7 @@ $env:DOTNET_MULTILEVEL_LOOKUP = 0 ########################################################################### function ExecSafe([scriptblock] $cmd) { - $LASTEXITCODE = 0 + $global:LASTEXITCODE = 0 & $cmd if ($LASTEXITCODE) { exit $LASTEXITCODE } }