export interface RegisteredRepo { /** Stable short identifier (user-visible). Unique. */ name: string; /** Absolute filesystem path to the repo root. Unique. */ path: string; /** Milliseconds since epoch — when the repo was registered. */ registeredAt: number; /** Milliseconds since epoch — last successful index run; null if never. */ lastIndexedAt: number | null; } export interface RegistryOptions { /** Override on-disk location (primarily for tests). */ dbPath?: string; } /** * Minimal catalogue of repositories. All operations are synchronous * because SQLite is synchronous in `bun:sqlite` and there's no I/O * outside the DB — keeps call sites simple. */ export declare class Registry { private readonly db; private readonly now; constructor(opts?: RegistryOptions, now?: () => number); private migrate; /** * Adds a repository. Throws if either the name or path is already * registered — callers should either `get()` first or catch and * translate into a user-friendly error. */ register(name: string, path: string): RegisteredRepo; /** Removes a repository by name. Returns true if a row was deleted. */ unregister(name: string): boolean; /** Returns registered repos sorted by name for deterministic output. */ list(): RegisteredRepo[]; getByName(name: string): RegisteredRepo | null; getByPath(path: string): RegisteredRepo | null; /** * Resolves a set of selectors (names or paths) to registered repos, * preserving selector order and de-duplicating. `'all'` as a sole * selector expands to `list()`. Unknown selectors raise — better to * fail loud than silently skip repos in a multi-repo search. */ resolve(selectors: readonly string[]): RegisteredRepo[]; /** Records a successful index run. No-op if the repo is unknown. */ touchIndexed(name: string, ts?: number): void; close(): void; } /** Default on-disk location: `~/.forge/registry.db`. */ export declare function defaultRegistryPath(): string; //# sourceMappingURL=registry.d.ts.map