export declare class LockTimeoutError extends Error { readonly code = "LOCK_TIMEOUT"; readonly lockPath: string; constructor(lockPath: string, attempts: number); } /** * Run `fn` while holding an exclusive lock on a sidecar file at * `.lock`. The lock is released in `finally` (close fd + * unlink lock file). Throws LockTimeoutError after MAX_LOCK_RETRIES. */ export declare function withFileLockSync(filePath: string, fn: () => T): T;