import { type Ora } from 'ora'; import type { RunResult } from '../types.js'; interface RunOptions { env?: NodeJS.ProcessEnv; [key: string]: unknown; } interface RunCaptureOptions extends RunOptions { onLine?: (line: string) => void; } /** * Run a command and capture stdout/stderr. * Throws on non-zero exit code. */ export declare function run(cmd: string, args?: string[], opts?: RunOptions): Promise; /** * Run a command and capture output, returning null on failure instead of throwing. */ export declare function runSafe(cmd: string, args?: string[], opts?: RunOptions): Promise; /** * Run a command with inherited stdio (interactive). * Returns exit code. */ export declare function runInteractive(cmd: string, args?: string[], opts?: RunOptions): Promise; /** * Run a command, capturing stdout line by line. * Calls onLine(line) for each stdout line. * Returns { stdout, stderr }. */ export declare function runCapture(cmd: string, args?: string[], opts?: RunCaptureOptions): Promise; /** * Run a command with a spinner. Shows success/fail on completion. */ export declare function runWithSpinner(text: string, fn: (spinner: Ora) => Promise): Promise; /** * Spawn a process, write stdinData to its stdin, and capture stdout. * Useful for commands that read from stdin. */ export declare function spawnWithStdin(cmd: string, args: string[], stdinData: string, opts?: RunOptions): Promise; /** * Check if a command exists in PATH. */ export declare function commandExists(cmd: string): Promise; export {}; //# sourceMappingURL=exec.d.ts.map