/** * Log File Reader * * Safely reads per-run log files (stdout, stderr, context) from .tx/runs/ directories. * Includes path traversal protection and tail support for large files. */ import { Effect } from "effect"; /** * Check if a resolved path is under the project's .tx/runs/ directory. * Uses prefix match (startsWith) not substring match (includes) to prevent * bypasses where /.tx/runs/ appears elsewhere in the path. */ export declare const isAllowedRunPath: (filePath: string) => boolean; /** * Read a log file with optional tail support. * Validates the path is under .tx/runs/ to prevent path traversal. * * @param filePath - Absolute path to the log file * @param tailLines - If > 0, return only the last N lines * @returns The file content and whether it was truncated */ export declare const readLogFile: (filePath: string, tailLines?: number) => Effect.Effect<{ content: string; truncated: boolean; }, Error>; //# sourceMappingURL=log-reader.d.ts.map