MCPcopy
hub / github.com/go-git/go-git / assembleCommit

Function assembleCommit

tests/objectverify/commit_test.go:154–163  ·  view source on GitHub ↗
(headers []string, message string)

Source from the content-addressed store, hash-verified

152}
153
154func assembleCommit(headers []string, message string) []byte {
155 var buf bytes.Buffer
156 for _, h := range headers {
157 buf.WriteString(h)
158 buf.WriteByte('\n')
159 }
160 buf.WriteByte('\n')
161 buf.WriteString(message)
162 return buf.Bytes()
163}
164
165// combineErr returns the first non-nil of decode, verify.
166// Decode failure is treated the same way as a verify failure.

Callers 1

Calls 1

BytesMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…