MCPcopy Create free account
hub / github.com/github/gh-aw / sourceRepoLabel

Function sourceRepoLabel

pkg/cli/helpers.go:103–108  ·  view source on GitHub ↗

sourceRepoLabel returns the source repo string for display in error messages. When the repo string is empty (file has no source field or is not a markdown file), a human-readable placeholder is returned so the error message is not confusing.

(repo string)

Source from the content-addressed store, hash-verified

101// When the repo string is empty (file has no source field or is not a markdown file),
102// a human-readable placeholder is returned so the error message is not confusing.
103func sourceRepoLabel(repo string) string {
104 if repo == "" {
105 return "(no source field)"
106 }
107 return repo
108}

Calls

no outgoing calls

Tested by 2