semver

package
v0.4.13 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Basic semver parsing.

Index

Constants

View Source
const (
	VerSep = "."
)

Variables

This section is empty.

Functions

func PadVer

func PadVer(ver1 []string, s int) []string

func PadVers

func PadVers(ver1 []string, ver2 []string) ([]string, []string)

v1, v2.1 => v1.0, v2.1; v2, v1.2 => v2.0, v1.2

func Sort added in v0.4.10

func Sort[T any](l []T, f func(T) string)

Check if ver1 is after ver2.

func SplitVer

func SplitVer(ver string) []string

func VerAfter

func VerAfter(ver1 string, ver2 string) bool

Check if ver1 is after ver2.

func VerAfterEq

func VerAfterEq(ver1 string, ver2 string) bool

Check if ver1 is after or eq to ver2.

func VerEq

func VerEq(ver1 string, ver2 string) bool

Check if ver1 is eq to ver2.

Types

This section is empty.

Jump to

Keyboard shortcuts

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