Output StandardError when an error occurs with a command line invocation.

This commit is contained in:
Dean Herbert 2017-03-14 20:23:53 +09:00
parent 1699c9fb1d
commit 864a97fa45
No known key found for this signature in database
GPG Key ID: 46D71BF4958ABB49
1 changed files with 2 additions and 0 deletions

View File

@ -340,6 +340,7 @@ private static bool runCommand(string command, string args)
WorkingDirectory = solutionPath,
CreateNoWindow = true,
RedirectStandardOutput = true,
RedirectStandardError = true,
UseShellExecute = false,
WindowStyle = ProcessWindowStyle.Hidden
};
@ -348,6 +349,7 @@ private static bool runCommand(string command, string args)
if (p == null) return false;
string output = p.StandardOutput.ReadToEnd();
output += p.StandardError.ReadToEnd();
if (p.ExitCode == 0) return true;