import { type ResolvedConfig } from "../types.js"; export declare const LOCK_STALE_MS = 30000; export declare const LEGACY_LOCK_STALE_MS: number; export type LockName = "project" | "improve" | "backlog" | "report" | "design" | "attempts" | "ledger" | "navigation" | "queue" | "settings"; export declare function locksDir(resolved: ResolvedConfig): string; export declare function lockTarget(resolved: ResolvedConfig, name: LockName): string; export declare function withStateLock(resolved: ResolvedConfig, name: LockName, fn: () => Promise, opts?: { timeoutMs?: number; command?: string; }): Promise; export declare function withProjectDirStateLock(projectDir: string, name: LockName, fn: () => Promise, opts?: { timeoutMs?: number; command?: string; }): Promise; export declare function withExternalStateLock(path: string, command: string, fn: () => Promise, opts?: { timeoutMs?: number; }): Promise; export declare function withProjectLock(resolved: ResolvedConfig, command: string, fn: () => Promise, opts?: { timeoutMs?: number; }): Promise; export declare function assertStateLocksHealthy(): void; export declare function projectLockAvailable(resolved: ResolvedConfig): Promise; export declare function stateLockHeld(resolved: ResolvedConfig, name: LockName): Promise; export declare function externalStateLockHeld(path: string): Promise;