MCPcopy Create free account
hub / github.com/cli/cli / appendParagraph

Function appendParagraph

internal/attachments/attach.go:261–270  ·  view source on GitHub ↗

appendParagraph joins two pieces of markdown as separate paragraphs.

(md, addition string)

Source from the content-addressed store, hash-verified

259
260// appendParagraph joins two pieces of markdown as separate paragraphs.
261func appendParagraph(md, addition string) string {
262 if addition == "" {
263 return md
264 }
265 md = strings.TrimRight(md, " \t\r\n")
266 if md == "" {
267 return addition
268 }
269 return md + "\n\n" + addition
270}

Callers 2

TestAppendParagraphFunction · 0.85
appendUnreferencedFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestAppendParagraphFunction · 0.68