export interface DiffStats { filesChanged: number; linesAdded: number; linesDeleted: number; fileStats: Record; } export declare class GitIntegration { private git; private rootDir; constructor(rootDir?: string); isGitRepo(): Promise; getCurrentCommit(): Promise; getUnstagedDiff(filePath?: string): Promise; getStagedDiff(filePath?: string): Promise; /** * Get stats for a specific file based on its current state on disk vs HEAD * This includes both staged and unstaged changes. */ getFileStats(filePath: string): Promise<{ added: number; deleted: number; changeType: 'added' | 'modified' | 'deleted'; }>; /** * Parse a unified diff string to count lines (fallback if numstat isn't enough) */ parseDiff(diff: string): { added: number; deleted: number; }; /** * Get current branch name */ getCurrentBranch(): Promise; /** * Create and checkout a new branch */ createAndCheckoutBranch(branchName: string): Promise; /** * Checkout an existing branch */ checkoutBranch(branchName: string): Promise; /** * Check if branch exists */ branchExists(branchName: string): Promise; /** * Delete a branch */ deleteBranch(branchName: string, force?: boolean): Promise; }