import type { Session } from '../../../session/session.ts'; import type { BuiltinCall, ExecuteStringFn, Result } from '../types.ts'; /** Parse a GNU timeout duration (float plus optional s/m/h/d). */ export declare function parseDuration(raw: string): number | null; /** * Run `timeout DURATION COMMAND [ARG...]`, killing at the deadline. * * The inner line is built with shellJoin so already-expanded words * survive re-parsing as one token each (GNU timeout execs the command * without a shell). On overrun the exit code is 124 like GNU; the * inner run's result is abandoned. The inner stdout is drained inside * the race so a lazy pipeline cannot run past the deadline. Signal * options (-s, -k, --preserve-status) are parsed but rejected: the * inner run is a promise, not a process, so there is nothing to * signal. */ export declare function handleTimeout(executeFn: ExecuteStringFn, args: readonly string[], session: Session): Promise; /** The `timeout` arm. */ export declare function timeoutBuiltin(call: BuiltinCall): Promise; //# sourceMappingURL=timeout.d.ts.map