import { type HookHostProfile } from "./host-profile.js"; export interface HookConfigDiscoveryOptions { readonly projectDir?: string; readonly platform?: string; readonly homeDir?: string; readonly appDataDir?: string; readonly profile?: HookHostProfile; readonly exists?: (filePath: string) => boolean; readonly readFile?: (filePath: string) => string; readonly realpath?: (filePath: string) => string; readonly resolveGitWorktreeRoot?: (cwd: string) => string | undefined; } export interface HookConfigPaths { readonly global?: string; readonly project?: string; } export type HookConfigSourceScope = "global" | "project"; export interface DiscoveredHookConfigPath { readonly scope: HookConfigSourceScope; readonly filePath: string; } export interface HookConfigWatchPaths { readonly paths: readonly string[]; } export interface ProjectHookResolution { readonly cwd: string; readonly anchorDir: string; readonly canonicalCwd: string; readonly canonicalAnchorDir: string; readonly worktreeRoot?: string; readonly discoveredProjectRoot?: string; readonly trustFilePath: string; readonly projectConfigPath?: string; readonly trusted: boolean; } /** * Resolve the primary global and project config paths for the active host. * Pi keeps its existing `.pi` locations. OMP uses its active agent directory * for global config and checks native `.omp` project locations before * trust-gated legacy Pi project fallbacks. */ export declare function resolveHookConfigPaths(options?: HookConfigDiscoveryOptions): HookConfigPaths; /** * Discover at most one global and one project config file. Global comes * before project so the project file can override the global one. * * Project hook files are gated by the active host's trust list. A legacy * `.pi` fallback discovered while OMP is active still requires OMP trust. */ export declare function discoverHookConfigEntries(options?: HookConfigDiscoveryOptions): DiscoveredHookConfigPath[]; export declare function discoverHookConfigPaths(options?: HookConfigDiscoveryOptions): string[]; /** * Resolve the complete, stable set of filesystem paths that can affect hook * discovery for one host profile and cwd. Callers can stat this set between * events and defer the synchronous project/git discovery work until one of * the paths changes. */ export declare function resolveHookConfigWatchPaths(options?: HookConfigDiscoveryOptions): HookConfigWatchPaths; export declare function resolveProjectHookResolution(options?: HookConfigDiscoveryOptions): ProjectHookResolution | undefined; export declare function __resetTrustListCacheForTests(): void; export declare function resolveTrustedProjectsFilePath(options?: Pick): string;