/** Structured worktree entry from git worktree list --porcelain */ export interface WorktreeEntry { /** Absolute path to worktree root */ path: string; /** HEAD commit hash */ head: string; /** Branch name, null if detached HEAD */ branch: string | null; /** Whether this worktree is locked */ locked: boolean; /** Lock reason if locked */ lockReason?: string; /** Whether this worktree is prunable */ prunable: boolean; } /** Structured execution environment for agent context */ export interface ExecutionEnvironment { host: string; os: string; /** Login shell from $SHELL or platform default — may differ from the tool shell */ loginShell: string; initialCwd: string; effectiveCwd: string; /** Git root of the effective working directory, or null */ gitRoot: string | null; /** Git root of the initial working directory, only set when different from gitRoot */ controllerGitRoot: string | null; gitBranch: string | null; gitWorktree: string | null; worktreeCount: number; isDetachedHead: boolean; } /** * Parse git worktree list --porcelain output into structured entries. * Returns empty array if git is unavailable or the repo has no worktrees. */ export declare function parseWorktreeList(cwd: string): WorktreeEntry[]; /** * Build a concise execution environment summary for the agent prompt. * * Sources: * - os.hostname() for host * - process.platform for OS (linux, darwin, win32) * - process.env.SHELL or platform default for shell * - initialCwd must be captured at session start and passed in * - process.cwd() for effective cwd * - git rev-parse for repo root * - git worktree list for worktree info * * Never includes secrets, full env vars, or sensitive data. */ export declare function buildExecutionEnvironment(initialCwd: string): ExecutionEnvironment; /** * Provides git branch and extension statuses - data not otherwise accessible to extensions. * Token stats, model info available via ctx.sessionManager and ctx.model. */ export declare class FooterDataProvider { private extensionStatuses; private cachedBranch; private gitPaths; private headWatcher; private reftableWatcher; private branchChangeCallbacks; private availableProviderCount; constructor(); /** Current git branch, null if not in repo, "detached" if detached HEAD */ getGitBranch(): string | null; /** Repository directory name, null if not in a git repository */ getGitRepoName(): string | null; /** Extension status texts set via ctx.ui.setStatus() */ getExtensionStatuses(): ReadonlyMap; /** Subscribe to git branch changes. Returns unsubscribe function. */ onBranchChange(callback: () => void): () => void; /** Internal: set extension status */ setExtensionStatus(key: string, text: string | undefined): void; /** Internal: clear extension statuses */ clearExtensionStatuses(): void; /** Number of unique providers with available models (for footer display) */ getAvailableProviderCount(): number; /** Internal: update available provider count */ setAvailableProviderCount(count: number): void; /** Internal: cleanup */ dispose(): void; private notifyBranchChange; private refreshGitBranch; private resolveGitBranch; private setupGitWatcher; } /** Read-only view for extensions - excludes setExtensionStatus, setAvailableProviderCount and dispose */ export type ReadonlyFooterDataProvider = Pick; //# sourceMappingURL=footer-data-provider.d.ts.map