MCPcopy
hub / github.com/cli/cli / getReadmePath

Function getReadmePath

pkg/cmd/repo/view/http.go:59–65  ·  view source on GitHub ↗
(repo ghrepo.Interface, branch string)

Source from the content-addressed store, hash-verified

57}
58
59func getReadmePath(repo ghrepo.Interface, branch string) string {
60 path := fmt.Sprintf("repos/%s/readme", ghrepo.FullName(repo))
61 if branch != "" {
62 path = fmt.Sprintf("%s?ref=%s", path, branch)
63 }
64 return path
65}

Callers 1

RepositoryReadmeFunction · 0.85

Calls 1

FullNameFunction · 0.92

Tested by

no test coverage detected