MCPcopy Index your code
hub / github.com/cli/cli / fileContentResponse

Function fileContentResponse

pkg/cmd/repo/read-file/read_file_test.go:686–688  ·  view source on GitHub ↗

fileContentResponse builds a Contents API object response for a regular file with base64-encoded inline content.

(name, content string)

Source from the content-addressed store, hash-verified

684// fileContentResponse builds a Contents API object response for a regular file
685// with base64-encoded inline content.
686func fileContentResponse(name, content string) map[string]interface{} {
687 return fileContentResponseBytes(name, []byte(content))
688}
689
690func fileContentResponseBytes(name string, content []byte) map[string]interface{} {
691 return map[string]interface{}{

Callers 1

Test_readFileRunFunction · 0.85

Calls 1

fileContentResponseBytesFunction · 0.85

Tested by

no test coverage detected