version

package
v0.6.3 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2023 License: BlueOak-1.0.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NormalizeString

func NormalizeString(str string) string

NormalizeString returns the passed string stripped of all characters which are not valid according to the semantic versioning guidelines for pre-release and build metadata strings. In particular they MUST only contain characters in semanticAlphabet.

func Parse

func Parse(version string) string

Parse returns the application version as a properly formed string per the semantic versioning 2.0.0 spec (https://semver.org/).

func ParseSemVer

func ParseSemVer(s string) (major, minor, patch uint32, preRel, build string, err error)

ParseSemVer parses various semver components from the provided string.

Types

This section is empty.

Jump to

Keyboard shortcuts

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