import type { ExecSyncOptions, SpawnOptions } from 'child_process'; declare function initProcessCatchErrorLogger(commandName: string, error: Error | unknown, commandParam?: string): void; /** * Executes a short-lived command synchronously. * The entire command string, including its arguments, must be passed. * * Example: execImmediateCommand('rspack --config ./config/rspack.config.ts'); */ declare function execImmediateCommand(fullCommandString: string, options?: ExecSyncOptions): void; /** * Runs a long-lived streaming command asynchronously. * The command and its arguments must be passed separately. * * Example: runStreamingCommand('rspack', ['serve', '--config', './config/rspack.config.ts']); */ declare function runStreamingCommand(command: string, args: string[], options?: SpawnOptions): import("node:child_process").ChildProcess | undefined; type WaitForFileOption = string | { path: string; pollIntervalMs?: number; timeoutMs?: number; }; /** * Runs a streaming command in sync mode: each subsequent command only starts * once the previous one is considered "ready". * * NOTE: {runStreamingCommand} spawns with {stdio: 'inherit'} so its output streams * directly to the terminal — this means {child.stdout} is always `null` and can NOT * be listened to for readiness text. Use {waitForFile} (polls the filesystem for a * path to exist) as the readiness signal instead. * * Example: runStreamingInSync([{ runCommand: () => runStreamingCommand(), waitForFile: './dist/private/ssr-server.config.mjs' }]); */ declare function runStreamingInSync(streamings: { runCommand: () => ReturnType; waitForFile?: WaitForFileOption; }[]): Promise; export { execImmediateCommand, initProcessCatchErrorLogger, runStreamingCommand, runStreamingInSync, };