/** * Fallback Utilities * Provides graceful degradation when external binaries are unavailable */ /** * Check if a binary is available * @param binary - The binary name to check. * @returns True if the binary is available in PATH. */ export declare function isBinaryAvailable(binary: string): boolean; /** * Native file listing fallback when fd is unavailable * @param dir - The directory to list files from. * @param options - Options for filtering. * @param options.glob - Glob pattern to match files. * @param options.depth - Maximum directory depth to traverse. * @param options.type - File type filter: 'file', 'directory', or 'any'. * @returns An array of relative file paths. */ export declare function listFilesNative(dir: string, options?: { glob?: string; depth?: number; type?: 'file' | 'directory' | 'any'; }): Promise; /** * Native grep fallback when ripgrep is unavailable * @param dir - The directory to search in. * @param pattern - The search pattern. * @param options - Search options. * @param options.isRegex - Whether the pattern is a regex. * @param options.caseSensitive - Whether the search is case-sensitive. * @returns An array of matching results with file, line number, and text. */ export declare function grepNative(dir: string, pattern: string, options?: { isRegex?: boolean; caseSensitive?: boolean; }): Promise<{ file: string; line: number; text: string; }[]>; /** * Get appropriate search function based on binary availability * @returns The search strategy to use. */ export declare function getSearchStrategy(): 'ripgrep' | 'native'; /** * Get appropriate file listing strategy * @returns The file listing strategy to use. */ export declare function getListStrategy(): 'fd' | 'native'; //# sourceMappingURL=fallback.d.ts.map