MCPcopy Create free account
hub / github.com/AI45Lab/Code / remove_worktree

Method remove_worktree

core/src/workspace/local.rs:459–474  ·  view source on GitHub ↗
(
        &self,
        request: WorkspaceGitRemoveWorktreeRequest,
    )

Source from the content-addressed store, hash-verified

457 }
458
459 async fn remove_worktree(
460 &self,
461 request: WorkspaceGitRemoveWorktreeRequest,
462 ) -> Result<WorkspaceGitWorktreeMutation> {
463 let path = PathBuf::from(request.path);
464 let display_path = path.display().to_string();
465 let force = request.force;
466
467 self.run_blocking_git(move |root| crate::git::remove_worktree(&root, &path, force))
468 .await?;
469
470 Ok(WorkspaceGitWorktreeMutation {
471 path: display_path,
472 branch: None,
473 })
474 }
475}
476
477#[async_trait]

Callers

nothing calls this directly

Calls 2

remove_worktreeFunction · 0.85
run_blocking_gitMethod · 0.80

Tested by

no test coverage detected