Skip to content

Commit

Permalink
Update GH CLI to 1.3.0
Browse files Browse the repository at this point in the history
Signed-off-by: Alex Ellis (OpenFaaS Ltd) <alexellis2@gmail.com>
  • Loading branch information
alexellis committed Nov 30, 2020
1 parent 9c1e258 commit f0c0949
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions pkg/get/get.go
Expand Up @@ -63,7 +63,7 @@ func GetBinaryName(tool *Tool, os, arch, version string) (string, error) {
return "", errors.New("BinaryTemplate is not set")
}

// Download fetches the download URL for a release of a tool
// GetDownloadURL fetches the download URL for a release of a tool
// for a given os, architecture and version
func GetDownloadURL(tool *Tool, os, arch, version string) (string, error) {
ver := tool.Version
Expand All @@ -87,10 +87,6 @@ func (tool Tool) GetURL(os, arch, version string) (string, error) {
return getByDownloadTemplate(tool, os, arch, version)
}

func (t Tool) Latest() bool {
return len(t.Version) == 0
}

func getURLByGithubTemplate(tool Tool, os, arch, version string) (string, error) {
if len(version) == 0 {
releases := fmt.Sprintf("https://github.com/%s/%s/releases/latest", tool.Owner, tool.Name)
Expand Down

0 comments on commit f0c0949

Please sign in to comment.