MCPcopy Create free account
hub / github.com/c4milo/github-release / CreateRelease

Function CreateRelease

main.go:186–196  ·  view source on GitHub ↗

CreateRelease creates a Github Release, attaching the given files as release assets If a release already exist, up in Github, this function will attempt to attach the given files to it.

(tag, branch, desc string, filepaths []string)

Source from the content-addressed store, hash-verified

184// CreateRelease creates a Github Release, attaching the given files as release assets
185// If a release already exist, up in Github, this function will attempt to attach the given files to it.
186func CreateRelease(tag, branch, desc string, filepaths []string) {
187 release := Release{
188 TagName: tag,
189 Name: tag,
190 Prerelease: false,
191 Draft: false,
192 Branch: branch,
193 Body: desc,
194 }
195 publishRelease(release, filepaths)
196}
197
198func publishRelease(release Release, filepaths []string) {
199 endpoint := fmt.Sprintf("%s/releases", githubAPIEndpoint)

Callers

nothing calls this directly

Calls 1

publishReleaseFunction · 0.85

Tested by

no test coverage detected