github.phpd.cn/goreleaser/goreleaser@v0.92.0/internal/client/client.go (about) 1 // Package client contains the client implementations for several providers. 2 package client 3 4 import ( 5 "bytes" 6 "os" 7 8 "github.com/goreleaser/goreleaser/pkg/config" 9 "github.com/goreleaser/goreleaser/pkg/context" 10 ) 11 12 // Info of the repository 13 type Info struct { 14 Description string 15 Homepage string 16 URL string 17 } 18 19 // Client interface 20 type Client interface { 21 CreateRelease(ctx *context.Context, body string) (releaseID int64, err error) 22 CreateFile(ctx *context.Context, commitAuthor config.CommitAuthor, repo config.Repo, content bytes.Buffer, path, message string) (err error) 23 Upload(ctx *context.Context, releaseID int64, name string, file *os.File) (err error) 24 }