MCPcopy Create free account
hub / github.com/libgit2/git2go / String

Method String

refspec.go:82–92  ·  view source on GitHub ↗

String returns the refspec's string representation

()

Source from the content-addressed store, hash-verified

80
81// String returns the refspec's string representation
82func (s *Refspec) String() string {
83 var ret string
84 cstr := C.git_refspec_string(s.ptr)
85
86 if cstr != nil {
87 ret = C.GoString(cstr)
88 }
89
90 runtime.KeepAlive(s)
91 return ret
92}
93
94// SrcMatches checks if a refspec's source descriptor matches a reference
95func (s *Refspec) SrcMatches(refname string) bool {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected