executeCommand static method
Executes commands concurrently in the current directory.
This method executes the specified commands concurrently in the current directory, handling results and errors appropriately.
Parameters:
commands: List of commands to executeconcurrent: Number of concurrent executions (default: 6)stdout: Callback for stdout linesstdoutErr: Callback for stderr linesignorePubWorkspaces: Whether to ignore pub workspaces (default: false)
Example:
// Run multiple Flutter commands concurrently
await ModularHelper.executeCommand(['flutter pub get', 'flutter analyze']);
Implementation
static Future<void> executeCommand(
List<String> commands, {
int concurrent = defaultConcurrent,
void Function(String line)? stdout,
void Function(String line)? stdoutErr,
bool ignorePubWorkspaces = false,
}) async {
await _executeCommandFutures(
commands,
concurrent: concurrent,
stdout: stdout,
stdoutErr: stdoutErr,
);
}