versioncheck

package
v1.8.1 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2020 License: Apache-2.0 Imports: 4 Imported by: 25

Documentation

Overview

Package versioncheck provides utility wrappers for go-version, allowing the constraints to be used as global variables.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Compile

func Compile(constraint string) (go_version.Range, error)

Compile trivially wraps go-version.NewConstraint, returning the constraint and error

func MustCompile

func MustCompile(constraint string) go_version.Range

MustCompile wraps go-version.NewConstraint, panicing when an error is returns (this occurs when the constraint cannot be parsed). It is intended to be use similar to re.MustCompile, to ensure unparseable constraints are caught in testing.

func MustVersion

func MustVersion(version string) go_version.Version

MustVersion wraps go-version.NewVersion, panicing when an error is returns (this occurs when the version cannot be parsed).

func Version

func Version(version string) (go_version.Version, error)

Version wraps go-version.NewVersion, panicing when an error is returns (this occurs when the version cannot be parsed).

Types

This section is empty.

Jump to

Keyboard shortcuts

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