version

package
v0.0.0-...-35fa672 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CompareStrings

func CompareStrings(lvs, rvs string) int

0 = equal, 1 = greater, -1 = smaller "1.2.3", "1.2.3" => 0 "1.2.3", "1.1" => -1 "1.2.3", "1.3" => 1 "1.2.3", "1.2.4" => 1 "1.2.3", "1.2.2" => -1 "1.2.3", "1.2.2.2" => -1 "1.2.3", "1.2.3.0.0" => 0 "1.2.3", "1.2.3.2" => 1 "1.2.3", "1.2.3.2.4" => 1

func CompareVersions

func CompareVersions(left, right []int) int

0 = equal, 1 = greater, -1 = smaller "1.2.3", "1.2.3" => 0 "1.2.3", "1.1" => -1 "1.2.3", "1.3" => 1 "1.2.3", "1.2.4" => 1 "1.2.3", "1.2.2" => -1 "1.2.3", "1.2.2.2" => -1 "1.2.3", "1.2.3.0.0" => 0 "1.2.3", "1.2.3.2" => 1 "1.2.3", "1.2.3.2.4" => 1

func MaxVersion

func MaxVersion(left, right []int) []int

func MaxVersionString

func MaxVersionString(lvs, rvs string) []int

func ParseVersionString

func ParseVersionString(vs string) []int

"1.02.3." => []int{1, 2, 3} "1.2..3" => []int{1, 2, 3} "1.00.2" => []int{1, 0, 2}

Types

This section is empty.

Jump to

Keyboard shortcuts

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