MCPcopy
hub / github.com/cli/cli / String

Method String

pkg/cmd/pr/shared/find_refs_resolution.go:70–75  ·  view source on GitHub ↗

A QualifiedHeadRef without an owner returns , while a QualifiedHeadRef with an owner returns : .

()

Source from the content-addressed store, hash-verified

68// A QualifiedHeadRef without an owner returns <branch>, while a QualifiedHeadRef
69// with an owner returns <owner>:<branch>.
70func (r QualifiedHeadRef) String() string {
71 if owner, present := r.owner.Value(); present {
72 return fmt.Sprintf("%s:%s", owner, r.branchName)
73 }
74 return r.branchName
75}
76
77func (r QualifiedHeadRef) BranchName() string {
78 return r.branchName

Callers 15

TestRunClose_UserFunction · 0.45
TestRunClose_OrgFunction · 0.45
TestRunClose_MeFunction · 0.45
TestRunClose_ReopenFunction · 0.45
TestRunClose_JSONFunction · 0.45
TestRunLink_RepoFunction · 0.45
TestRunLink_TeamFunction · 0.45
copyArgsFunction · 0.45
TestRunCopy_UserFunction · 0.45
TestRunCopy_OrgFunction · 0.45
TestRunCopy_MeFunction · 0.45
TestRunCopy_JSONFunction · 0.45

Calls 1

ValueMethod · 0.80

Tested by 15

TestRunClose_UserFunction · 0.36
TestRunClose_OrgFunction · 0.36
TestRunClose_MeFunction · 0.36
TestRunClose_ReopenFunction · 0.36
TestRunClose_JSONFunction · 0.36
TestRunLink_RepoFunction · 0.36
TestRunLink_TeamFunction · 0.36
TestRunCopy_UserFunction · 0.36
TestRunCopy_OrgFunction · 0.36
TestRunCopy_MeFunction · 0.36
TestRunCopy_JSONFunction · 0.36
TestRunMarkTemplate_OrgFunction · 0.36