pub fn create_worktree(
repo_root: impl AsRef<Path>,
loop_id: &str,
config: &WorktreeConfig,
) -> Result<Worktree, WorktreeError>Expand description
Create a new worktree for a parallel Ralph loop.
Creates a new branch and worktree at {config.worktree_dir}/{loop_id}.
The branch is created from HEAD of the current branch.
§Arguments
repo_root- Root of the git repositoryloop_id- Unique identifier for the loop (e.g., “ralph-20250124-a3f2”)config- Worktree configuration
§Returns
Information about the created worktree.