versionutil

package
v1.2.3 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2025 License: Apache-2.0 Imports: 2 Imported by: 2 modules, 4 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GreaterEqual added in v1.0.0

func GreaterEqual(limaVersion, oldVersion string) bool

GreaterEqual return true if limaVersion >= oldVersion.

func GreaterThan

func GreaterThan(limaVersion, oldVersion string) bool

GreaterThan returns true if the Lima version used to create an instance is greater than a specific older version. Always returns false if the Lima version is the empty string. Unparsable lima versions (like SHA1 commit ids) are treated as the latest version and return true. limaVersion is a `github describe` string, not a semantic version. So "0.19.1-16-gf3dc6ed.m" will be considered greater than "0.19.1".

func Parse

func Parse(version string) (*semver.Version, error)

Parse parses a Lima version string by removing the leading "v" character and stripping everything from the first "-" forward (which are `git describe` artifacts and not semver pre-release markers) or cutting ".m" suffix from exact version. So "v0.19.1-16-gf3dc6ed.m" will be parsed as "0.19.1".

Types

This section is empty.

Jump to

Keyboard shortcuts

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