Skip to content

Commit fcfc216

Browse files
authored
Return correct exit code from build.ps1 (#8582)
Build.cmd failed to return an actual exit code from eng/build.ps1, which resulted in CI steps reported as "passed" despite errors during the execution.
1 parent ecf3678 commit fcfc216

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

build.cmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@ set _args=%*
55
if "%~1"=="-?" set _args=-help
66
if "%~1"=="/?" set _args=-help
77

8-
powershell -ExecutionPolicy ByPass -NoProfile -Command "& '%~dp0eng\build.ps1'" %_args%
9-
exit /b %ERRORLEVEL%
8+
powershell -ExecutionPolicy ByPass -NoProfile -Command "& '%~dp0eng\build.ps1' %_args%; exit $LASTEXITCODE"
9+
exit /b %ERRORLEVEL%

0 commit comments

Comments
 (0)