runProcessWithArguments static method
Runs executable with arguments (as a list, so spaces survive), sharing
the terminal's stdio, and returns its exit code.
Implementation
static Future<int> runProcessWithArguments(
String executable,
List<String> arguments, {
String? workingDirectory,
}) async {
final process = await Process.start(
executable,
arguments,
runInShell: true,
workingDirectory: workingDirectory,
mode: ProcessStartMode.inheritStdio,
);
return await process.exitCode;
}