runtime

package
v0.187.0 Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const NodeRuntime = "nodejs"

Variables

This section is empty.

Functions

This section is empty.

Types

type Runtime

type Runtime struct {
	Name        string
	Alias       []string
	Version     string
	EOLDate     time.Time
	RemovalDate time.Time
	Default     bool
	Extra       map[string]string
}

Runtime represents runtime details on the VM.

func Find

func Find(runtimes []Runtime, name, version string) (Runtime, error)

Find selects the appropriate runtime from a list of runtimes. It supports full SemVer matching, alias resolution, and fuzzy matching for major or major.minor versions. `version` is expected to always start with "v".

func GetDefault

func GetDefault(runtimes []Runtime, name string) (Runtime, error)

GetDefault returns the default version for the specified runtime.

func (*Runtime) Validate

func (r *Runtime) Validate(runtimes []Runtime) error

Jump to

Keyboard shortcuts

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