{"modulePath":"github.com/concourse/github-release-resource","version":"v1.14.3","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package resource\n\n## Functions\n\n```go\nfunc Fatal(doing string, err error)\n```\n\n```go\nfunc Sayf(message string, args ...interface{})\n```\n\n```go\nfunc SortByTimestamp(releases []*github.RepositoryRelease)\n```\n\n```go\nfunc SortByVersion(releases []*github.RepositoryRelease, versionParser *versionParser)\n```\n\n## Types\n\n```go\ntype CheckCommand struct {\n\t// contains filtered or unexported fields\n}\n```\n\n```go\nfunc NewCheckCommand(github GitHub) *CheckCommand\n```\n\n```go\nfunc (c *CheckCommand) Run(request CheckRequest) ([]Version, error)\n```\n\n```go\ntype CheckRequest struct {\n\tSource  Source  `json:\"source\"`\n\tVersion Version `json:\"version\"`\n}\n```\n\n```go\nfunc NewCheckRequest() CheckRequest\n```\n\n```go\ntype FlexInt64 int64\n```\nFlexInt64 unmarshals from both JSON numbers and strings. Concourse credential managers often interpolate all values as strings.\n\n```go\nfunc (f FlexInt64) Int64() int64\n```\n\n```go\nfunc (f *FlexInt64) UnmarshalJSON(data []byte) error\n```\n\n```go\ntype GitHub interface {\n\tListReleases() ([]*github.RepositoryRelease, error)\n\tGetReleaseByTag(tag string) (*github.RepositoryRelease, error)\n\tGetRelease(id int) (*github.RepositoryRelease, error)\n\tCreateRelease(release github.RepositoryRelease) (*github.RepositoryRelease, error)\n\tUpdateRelease(release github.RepositoryRelease) (*github.RepositoryRelease, error)\n\n\tListReleaseAssets(release github.RepositoryRelease) ([]*github.ReleaseAsset, error)\n\tUploadReleaseAsset(release github.RepositoryRelease, name string, file *os.File) error\n\tDeleteReleaseAsset(asset github.ReleaseAsset) error\n\tDownloadReleaseAsset(asset github.ReleaseAsset) (io.ReadCloser, error)\n\n\tGetTarballLink(tag string) (*url.URL, error)\n\tGetZipballLink(tag string) (*url.URL, error)\n\tResolveTagToCommitSHA(tag string) (string, error)\n}\n```\n\n```go\ntype GitHubClient struct {\n\t// contains filtered or unexported fields\n}\n```\n\n```go\nfunc NewGitHubClient(source Source) (*GitHubClient, error)\n```\n\n```go\nfunc (g *GitHubClient) CreateRelease(release github.RepositoryRelease) (*github.RepositoryRelease, error)\n```\n\n```go\nfunc (g *GitHubClient) DeleteReleaseAsset(asset github.ReleaseAsset) error\n```\n\n```go\nfunc (g *GitHubClient) DownloadReleaseAsset(asset github.ReleaseAsset) (io.ReadCloser, error)\n```\n\n```go\nfunc (g *GitHubClient) GetRelease(id int) (*github.RepositoryRelease, error)\n```\n\n```go\nfunc (g *GitHubClient) GetReleaseByTag(tag string) (*github.RepositoryRelease, error)\n```\n\n```go\nfunc (g *GitHubClient) GetTarballLink(tag string) (*url.URL, error)\n```\n\n```go\nfunc (g *GitHubClient) GetZipballLink(tag string) (*url.URL, error)\n```\n\n```go\nfunc (g *GitHubClient) ListReleaseAssets(release github.RepositoryRelease) ([]*github.ReleaseAsset, error)\n```\n\n```go\nfunc (g *GitHubClient) ListReleases() ([]*github.RepositoryRelease, error)\n```\n\n```go\nfunc (g *GitHubClient) ResolveTagToCommitSHA(tagName string) (string, error)\n```\n\n```go\nfunc (g *GitHubClient) UpdateRelease(release github.RepositoryRelease) (*github.RepositoryRelease, error)\n```\n\n```go\nfunc (g *GitHubClient) UploadReleaseAsset(release github.RepositoryRelease, name string, file *os.File) error\n```\n\n```go\ntype InCommand struct {\n\t// contains filtered or unexported fields\n}\n```\n\n```go\nfunc NewInCommand(github GitHub, writer io.Writer) *InCommand\n```\n\n```go\nfunc (c *InCommand) Run(destDir string, request InRequest) (InResponse, error)\n```\n\n```go\ntype InParams struct {\n\tGlobs                []string `json:\"globs\"`\n\tIncludeSourceTarball bool     `json:\"include_source_tarball\"`\n\tIncludeSourceZip     bool     `json:\"include_source_zip\"`\n}\n```\n\n```go\ntype InRequest struct {\n\tSource  Source   `json:\"source\"`\n\tVersion *Version `json:\"version\"`\n\tParams  InParams `json:\"params\"`\n}\n```\n\n```go\nfunc NewInRequest() InRequest\n```\n\n```go\ntype InResponse struct {\n\tVersion  Version        `json:\"version\"`\n\tMetadata []MetadataPair `json:\"metadata\"`\n}\n```\n\n```go\ntype MetadataPair struct {\n\tName     string `json:\"name\"`\n\tValue    string `json:\"value\"`\n\tURL      string `json:\"url\"`\n\tMarkdown bool   `json:\"markdown\"`\n}\n```\n\n```go\ntype OutCommand struct {\n\t// contains filtered or unexported fields\n}\n```\n\n```go\nfunc NewOutCommand(github GitHub, writer io.Writer) *OutCommand\n```\n\n```go\nfunc (c *OutCommand) Run(sourceDir string, request OutRequest) (OutResponse, error)\n```\n\n```go\ntype OutParams struct {\n\tNamePath             string `json:\"name\"`\n\tBodyPath             string `json:\"body\"`\n\tTagPath              string `json:\"tag\"`\n\tCommitishPath        string `json:\"commitish\"`\n\tTagPrefix            string `json:\"tag_prefix\"`\n\tGenerateReleaseNotes bool   `json:\"generate_release_notes\"`\n\n\tGlobs []string `json:\"globs\"`\n}\n```\n\n```go\ntype OutRequest struct {\n\tSource Source    `json:\"source\"`\n\tParams OutParams `json:\"params\"`\n}\n```\n\n```go\nfunc NewOutRequest() OutRequest\n```\n\n```go\ntype OutResponse struct {\n\tVersion  Version        `json:\"version\"`\n\tMetadata []MetadataPair `json:\"metadata\"`\n}\n```\n\n```go\ntype ReleaseObject struct {\n\tCreatedAt    githubv4.DateTime `graphql:\"createdAt\"`\n\tPublishedAt  githubv4.DateTime `graphql:\"publishedAt\"`\n\tID           string            `graphql:\"id\"`\n\tDatabaseId   githubv4.Int      `graphql:\"databaseId\"`\n\tIsDraft      bool              `graphql:\"isDraft\"`\n\tIsPrerelease bool              `graphql:\"isPrerelease\"`\n\tName         string            `graphql:\"name\"`\n\tTagName      string            `graphql:\"tagName\"`\n\tURL          string            `graphql:\"url\"`\n}\n```\nReleaseObject represent the graphql release object [https://developer.github.com/v4/object/release](https://developer.github.com/v4/object/release)\n\n```go\ntype Source struct {\n\tOwner      string `json:\"owner\"`\n\tRepository string `json:\"repository\"`\n\n\t// Deprecated; use Owner instead\n\tUser string `json:\"user\"`\n\n\tGitHubAPIURL     string    `json:\"github_api_url\"`\n\tGitHubV4APIURL   string    `json:\"github_v4_api_url\"`\n\tGitHubUploadsURL string    `json:\"github_uploads_url\"`\n\tAccessToken      string    `json:\"access_token\"`\n\tAppID            FlexInt64 `json:\"app_id\"`\n\tPrivateKey       string    `json:\"private_key\"`\n\tDrafts           bool      `json:\"drafts\"`\n\tPreRelease       bool      `json:\"pre_release\"`\n\tRelease          bool      `json:\"release\"`\n\tInsecure         bool      `json:\"insecure\"`\n\tAssetDir         bool      `json:\"asset_dir\"`\n\n\tTagFilter        string `json:\"tag_filter\"`\n\tOrderBy          string `json:\"order_by\"`\n\tSemverConstraint string `json:\"semver_constraint\"`\n}\n```\n\n```go\ntype Version struct {\n\tTag       string    `json:\"tag,omitempty\"`\n\tID        string    `json:\"id\"`\n\tTimestamp time.Time `json:\"timestamp\"`\n}\n```\n\n","path":"github.com/concourse/github-release-resource","name":"resource","synopsis":"","isRedistributable":true}
