Files
renovate/tools/utils/exec.ts
T
Michael Kriese b35d7c9cad chore(tools): use async execa (#41712)
* chore(tools): use async execa

* chore: fix lint errors
2026-03-10 16:55:44 +00:00

20 lines
392 B
TypeScript

import type { ExecaReturnValue, Options } from 'execa';
import { execa } from 'execa';
const maxBuffer = 20 * 1024 * 1024;
/**
* Execute a command asynchronously using execa
*/
export async function exec(
cmd: string,
args: string[] = [],
opts: Options = {},
): Promise<ExecaReturnValue> {
return await execa(cmd, args, {
...opts,
maxBuffer,
encoding: 'utf8',
});
}