From afc19c6460bb0b0570b3b52b11fbfb5b16a0dbe6 Mon Sep 17 00:00:00 2001 From: Hsiao-nan Cheung Date: Fri, 10 Dec 2021 00:09:41 +0800 Subject: [PATCH] fix(core): Redirect StandardError in `Invoke-ExternalCommand` --- lib/core.ps1 | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/core.ps1 b/lib/core.ps1 index ea4f010359..5d76b23bdb 100644 --- a/lib/core.ps1 +++ b/lib/core.ps1 @@ -435,6 +435,7 @@ function Invoke-ExternalCommand { } if ($LogPath -and ($FilePath -notmatch '(^|\W)msiexec($|\W)')) { Out-File -FilePath $LogPath -Encoding ASCII -Append -InputObject $Process.StandardOutput.ReadToEnd() + Out-File -FilePath $LogPath -Encoding ASCII -Append -InputObject $Process.StandardError.ReadToEnd() } $Process.WaitForExit() if ($Process.ExitCode -ne 0) {