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

Function blameHunkFromC

blame.go:154–166  ·  view source on GitHub ↗
(hunk *C.git_blame_hunk)

Source from the content-addressed store, hash-verified

152}
153
154func blameHunkFromC(hunk *C.git_blame_hunk) BlameHunk {
155 return BlameHunk{
156 LinesInHunk: uint16(hunk.lines_in_hunk),
157 FinalCommitId: newOidFromC(&hunk.final_commit_id),
158 FinalStartLineNumber: uint16(hunk.final_start_line_number),
159 FinalSignature: newSignatureFromC(hunk.final_signature),
160 OrigCommitId: newOidFromC(&hunk.orig_commit_id),
161 OrigPath: C.GoString(hunk.orig_path),
162 OrigStartLineNumber: uint16(hunk.orig_start_line_number),
163 OrigSignature: newSignatureFromC(hunk.orig_signature),
164 Boundary: hunk.boundary == 1,
165 }
166}

Callers 2

HunkByIndexMethod · 0.85
HunkByLineMethod · 0.85

Calls 2

newOidFromCFunction · 0.85
newSignatureFromCFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…