Method RunShellCommandAndWaitResult
RunShellCommandAndWaitResult(string, string?, bool)
Executes a shell command and waits for the result.
public static string? RunShellCommandAndWaitResult(string command, string? arguments = null, bool multiLineResult = false)
Parameters
commandstringThe shell command to execute.
argumentsstringOptional arguments to pass to the command.
multiLineResultboolIf
true, the method returns the full output of the command. Iffalse, only the first line of the output is returned.
Returns
- string
The output of the command if successful; otherwise,
null.