/**
 * Structured details for a {@link ProcessError}.
 */
export interface ProcessErrorOptions {
    /**
     * The operating-system error code or process exit code.
     */
    code?: string | number | null;
    /**
     * The signal that terminated the process.
     */
    signal?: NodeJS.Signals | null;
    /**
     * Whether the process was killed.
     */
    killed?: boolean;
    /**
     * Captured standard output.
     */
    stdout?: string | Buffer;
    /**
     * Captured standard error.
     */
    stderr?: string | Buffer;
}
/**
 * An error raised while resolving or executing a process.
 *
 * The captured output is non-enumerable so ordinary logging and serialization
 * do not expose it accidentally.
 */
export declare class ProcessError extends Error {
    /**
     * The operating-system error code or process exit code.
     */
    readonly code: string | number | null;
    /**
     * The signal that terminated the process.
     */
    readonly signal: NodeJS.Signals | null;
    /**
     * Whether the process was killed.
     */
    readonly killed: boolean;
    /**
     * Captured standard output, when available.
     */
    readonly stdout: string | Buffer | undefined;
    /**
     * Captured standard error, when available.
     */
    readonly stderr: string | Buffer | undefined;
    /**
     * Creates a process error.
     *
     * @param message - A message that does not contain command arguments or output.
     * @param options - Structured process failure details.
     */
    constructor(message: string, options?: ProcessErrorOptions);
}
/**
 * Checks whether an unknown value is a {@link ProcessError}.
 *
 * @param error - The value to check.
 * @returns Whether the value is a process error.
 */
export declare function isProcessError(error: unknown): error is ProcessError;
/**
 * Wraps a child-process failure in a sanitized {@link ProcessError}.
 *
 * @param error - The original child-process error.
 * @param stdout - Captured standard output.
 * @param stderr - Captured standard error.
 * @returns A sanitized process error.
 */
export declare function createExecutionError(error: Error & {
    code?: string | number | null;
    signal?: NodeJS.Signals | null;
    killed?: boolean;
}, stdout?: string | Buffer, stderr?: string | Buffer): ProcessError;
//# sourceMappingURL=errors.d.ts.map