Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DownloadLatestStableRelease ¶
func DownloadLatestStableRelease(ctx context.Context, target, currentVersion string, printf func(string, ...interface{})) (version string, err error)
DownloadLatestStableRelease downloads the latest stable released version of restic and saves it to target. It returns the version string for the newest version. The function printf is used to print progress information.
Types ¶
type Release ¶
type Release struct { Name string `json:"name"` TagName string `json:"tag_name"` Draft bool `json:"draft"` PreRelease bool `json:"prerelease"` PublishedAt time.Time `json:"published_at"` Assets []Asset `json:"assets"` Version string `json:"-"` // set manually in the code }
Release collects data about a single release on GitHub.
func GitHubLatestRelease ¶
GitHubLatestRelease uses the GitHub API to get information about the latest release of a repository.
Click to show internal directories.
Click to hide internal directories.