export type RepoScopeDeps = { gitToplevel?: (cwd: string) => Promise; gitWorktreePaths?: (cwd: string) => Promise; }; export type RepoScopeOptions = { /** Explicit repository roots; relative paths resolve against `cwd`. Skips git entirely. */ explicit?: string[]; /** * Worktree layouts, as globs relative to each repository root, for checkouts that `git * worktree list` cannot report (for example a directory of worktrees that were since pruned). * Each match becomes an extra root. */ worktreeGlobs?: string[]; deps?: RepoScopeDeps; }; /** * The roots a run treats as "this repository": the explicit roots when given, otherwise the * current checkout's top level unioned with every `git worktree list` entry, plus any `worktreeGlobs` matches, then * minimized. A git failure (not a repository, no `git`) rejects; callers report it and point at * the explicit roots. Every root is canonicalized once so a symlinked path compares correctly with * a transcript's recorded cwd. */ export declare function resolveRepoRoots(cwd: string, options?: RepoScopeOptions): Promise; /** Path-boundary safe: `/repo-two` never matches root `/repo` on a shared string prefix. */ export declare function isWithinRepoRoots(cwd: string, roots: string[]): Promise;