import { WorktreeConfig } from './config.js'; /** * Options for generating a worktree path */ export interface PathGenerationOptions { /** Work item ID (e.g., issue number) */ workId: string; /** Organization name (auto-detected if not provided) */ organization?: string; /** Project name (auto-detected if not provided) */ project?: string; /** Custom path to use instead of generated path */ customPath?: string; /** Worktree configuration (loaded if not provided) */ config?: WorktreeConfig; } /** * Generate a worktree path from configuration * * Path generation logic: * 1. If customPath is provided, use it directly * 2. Load configuration (or use provided config) * 3. Resolve the worktree base location (relative to cwd or absolute) * 4. Generate the worktree name using the pathPattern with substitutions * 5. Return resolved absolute path * * @param cwd Current working directory (git repository root) * @param options Path generation options * @returns Absolute path to worktree directory * * @example * ```typescript * // Auto-detect organization and project * const worktreePath = await generateWorktreePath('/path/to/repo', { workId: '258' }); * // Returns: /path/to/repo/.claude/worktrees/work-id-258 * * // Custom path * const worktreePath = await generateWorktreePath('/path/to/repo', { * workId: '258', * customPath: '/custom/path' * }); * // Returns: /custom/path * ``` */ export declare function generateWorktreePath(cwd: string, options: PathGenerationOptions): Promise; /** * Find all existing worktrees for a repository * * @param cwd Current working directory (git repository root) * @returns Array of worktree paths */ export declare function listWorktrees(cwd: string): Promise; //# sourceMappingURL=path-generator.d.ts.map