Be more verbose when processes spawned from tasks fail. (#54144)
authorJo Shields <directhex@apebox.org>
Tue, 15 Jun 2021 03:00:03 +0000 (23:00 -0400)
committerGitHub <noreply@github.com>
Tue, 15 Jun 2021 03:00:03 +0000 (23:00 -0400)
commit301774db363bb308f3ac4cd8f90d1563ea19105c
tree037ebb8ebc7bc6364ffae4a1d17b88b20a2b9baa
parentf7d48720a82920a4786e99b08c4687950c827896
Be more verbose when processes spawned from tasks fail. (#54144)

Right now, when a process fails (e.g. cmake or xcodebuild), all of the STDERR captured during that process run is dumped in the exception.

However, if silent is true, no STDOUT is captured at all, and we lose potentially vital debugging information contained within.

This PR merges the stdout and stderr capture, and instead of not capturing anything when silent is true, it always captures and only returns nothing when silent is true.

This should greatly ease debugging of failed tasks.
src/tasks/Common/Utils.cs