Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsPluginReferenceOrIdentity ¶ added in v1.8.0
IsPluginReferenceOrIdentity returns true if the argument matches a plugin reference (with version) or a plugin identity (without version).
func ValidatePluginIdentity ¶ added in v1.12.0
func ValidatePluginIdentity(pluginIdentity PluginIdentity) error
func ValidatePluginVersion ¶ added in v1.12.0
func ValidateRemote ¶ added in v1.12.0
Types ¶
type PluginIdentity ¶
type PluginIdentity interface { Remote() string Owner() string Plugin() string // IdentityString is the string remote/owner/plugin. IdentityString() string // contains filtered or unexported methods }
PluginIdentity is a plugin identity.
It just contains remote, owner, plugin.
func NewPluginIdentity ¶
func NewPluginIdentity( remote string, owner string, plugin string, ) (PluginIdentity, error)
NewPluginIdentity returns a new PluginIdentity.
func ParsePluginIdentityOptionalVersion ¶ added in v1.22.0
func ParsePluginIdentityOptionalVersion(rawReference string) (PluginIdentity, string, error)
ParsePluginIdentityOptionalVersion returns the PluginIdentity and version for the given string. If the string does not contain a version, the version is assumed to be an empty string. This parses the path in the form remote/owner/plugin:version.
func PluginIdentityForString ¶
func PluginIdentityForString(path string) (PluginIdentity, error)
PluginIdentityForString returns a new PluginIdentity for the given string.
This parses the path in the form remote/owner/plugin.
type PluginReference ¶
type PluginReference interface { PluginIdentity // ReferenceString is the string representation of identity:version:revision. ReferenceString() string // Version is the plugin's semantic version. Version() string // Revision is the plugin's revision number. // // The accepted range for this value is 0 - math.MaxInt32. Revision() int // contains filtered or unexported methods }
PluginReference uniquely references a plugin (including version and revision information).
It can be used to identify dependencies on other plugins.
func NewPluginReference ¶
func NewPluginReference( identity PluginIdentity, version string, revision int, ) (PluginReference, error)
NewPluginReference returns a new PluginReference.
func PluginReferenceForString ¶
func PluginReferenceForString(reference string, revision int) (PluginReference, error)
PluginReferenceForString returns a new PluginReference for the given string.
This parses the path in the form remote/owner/plugin:version.