import type { styleText } from 'node:util'; import stream from 'stream'; import { type Options, type ResultPromise } from 'execa'; import type { PackageManager } from './packageManager.js'; type StyleColor = Parameters[0]; export type Exec = (command: string, ...args: string[]) => ResultPromise; interface ExecConcurrentlyCommand { command: string; name: string; prefixColor?: StyleColor; } interface ExecConcurrentlyOptions { /** * The maximum number of processes that can execute concurrently. * * Defaults to the CPU core count. */ maxProcesses?: number; /** * A set length to pad names to. * * Defaults to the length of the longest command name. */ nameLength?: number; /** * The stream that logging output will be written to. * * Defaults to `process.stdout`. */ outputStream?: stream.Writable; } type ExecOptions = T & StreamStdioOptions; type StreamStdioOptions = { streamStdio?: true | PackageManager; }; export declare const createExec: (opts: ExecOptions) => Exec; export declare const exec: Exec; export declare const execConcurrently: (commands: ExecConcurrentlyCommand[], { maxProcesses, nameLength, outputStream }?: ExecConcurrentlyOptions) => Promise; export declare const ensureCommands: (...names: string[]) => Promise; export declare const hasCommand: (name: string) => Promise; export {};