gomodule

package
v0.55.1 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2023 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GoModule

type GoModule struct {
	Spec Spec

	Version version.Version
	// contains filtered or unexported fields
}

GoModule defines a resource of type "gomodule"

func New

func New(spec interface{}) (*GoModule, error)

New returns a reference to a newly initialized Go Module object from a godmodule.Spec or an error if the provided Spec triggers a validation error.

func (*GoModule) Changelog

func (g *GoModule) Changelog() string

Changelog returns the changelog for a specific golang module, or an empty string if it couldn't find one

func (*GoModule) Condition

func (g *GoModule) Condition(source string, scm scm.ScmHandler, resultCondition *result.Condition) error

Condition checks if a go module with a specific version is published

func (*GoModule) Source

func (g *GoModule) Source(workingDir string, resultSource *result.Source) error

Source returns the latest go module version

func (*GoModule) Target

func (g *GoModule) Target(source string, scm scm.ScmHandler, dryRun bool, releaseTarget *result.Target) error

Target is not support for gomodule

type Spec

type Spec struct {
	// Proxy may have the schemes https, http. file is not supported at this time. If a URL has no scheme, https is assumed
	// [S][C] Proxy allows to override GO proxy similarly to GOPROXY environment variable.
	Proxy string `yaml:",omitempty"`
	// [S][C] Module specifies the name of the module
	Module string `yaml:",omitempty" jsonschema:"required"`
	// [C] Defines a specific package version
	Version string `yaml:",omitempty"`
	// [S] VersionFilter provides parameters to specify version pattern and its type like regex, semver, or just latest.
	VersionFilter version.Filter `yaml:",omitempty"`
}

Spec defines a specification for a "gomodule" resource parsed from an updatecli manifest file

Jump to

Keyboard shortcuts

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