Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Info ¶
type Info struct { GitVersion string `json:"gitVersion"` GitCommit string `json:"gitCommit"` BuildDate string `json:"buildDate"` GoVersion string `json:"goVersion"` Compiler string `json:"compiler"` Platform string `json:"platform"` }
Info contains versioning information.
type Version ¶
type Version struct {
*semver.Version
}
Version is an extension of semver.Version
func FromGithubVersion ¶
FromGithubVersion provides a version parsed from github semver which starts with "v". v1.5.2 provides a sem version of 1.5.2
func FromSemVer ¶
func FromSemVer(v *semver.Version) *Version
FromSemVer converts a semver.Version to our Version
func (*Version) CompareMajorMinor ¶
CompareMajorMinor provides Compare results -1, 0, 1 for only the major and minor element of the semver, ignoring the patch or prerelease elements. This is useful if you are looking for minVersion for example 1.15.6 is version 1.15 or higher.
Click to show internal directories.
Click to hide internal directories.