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

Method list_branches

core/src/workspace/remote_git.rs:546–556  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

544 }
545
546 async fn list_branches(&self) -> Result<Vec<WorkspaceGitBranch>> {
547 let resp: BranchesResp = self.post_json("branches", &EmptyReq).await?;
548 Ok(resp
549 .branches
550 .into_iter()
551 .map(|b| WorkspaceGitBranch {
552 name: b.name,
553 is_current: b.is_current,
554 })
555 .collect())
556 }
557
558 async fn create_branch(&self, request: WorkspaceGitCreateBranchRequest) -> Result<()> {
559 self.post_unit(

Callers 1

Calls 1

post_jsonMethod · 0.80

Tested by

no test coverage detected