ref

package
v0.4.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 12, 2020 License: Apache-2.0 Imports: 7 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateRefString added in v0.2.0

func CreateRefString(owner string, repo string, path string, ref string) string

func DetermineGitHubRefType

func DetermineGitHubRefType(owner string, repo string, unknownRef string) (*PossiblyStableTag, *Branch, bool, error)

DetermineGitHubRefType will use the GitHub API to determine if a passed ref is a commit, branch or tag

func IsSHAInRepo

func IsSHAInRepo(owner string, repo string, commitSHA string) (bool, error)

func ListTagsInRepo added in v0.2.0

func ListTagsInRepo(owner string, repo string) ([]string, error)

func RefToParts

func RefToParts(ref string) (string, string, string, string, error)

RefToParts takes a uses reference and splits into owner, repo, path and ref

Types

type Branch

type Branch struct {
	BranchName string
	CommitSHA  string
}

type PossiblyStableTag

type PossiblyStableTag struct {
	TagName   string
	CommitSHA string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL