Documentation
¶
Overview ¶
Package releaseinfo exposes the build's normalized release identity.
Index ¶
Constants ¶
View Source
const DevelopmentVersion = "dev"
Variables ¶
View Source
var ( // Version is replaced for release builds with: // -ldflags "-X github.com/baldaworks/knowl/internal/releaseinfo.Version=vX.Y.Z". Version = DevelopmentVersion ErrDevelopmentBuild = errors.New("development build has no release identity") ErrInvalidVersion = errors.New("invalid release version") )
Functions ¶
This section is empty.
Types ¶
type Identity ¶
type Identity struct {
Version string `json:"version"`
Tag string `json:"tag,omitempty"`
Release bool `json:"release"`
}
Identity is the normalized version information emitted by the CLI.
func CurrentRelease ¶
CurrentRelease returns the embedded identity only for a valid release build.
Click to show internal directories.
Click to hide internal directories.