Documentation
¶
Overview ¶
Package operations provides reusable operations for module manipulation.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BumpOperation ¶
type BumpOperation struct {
// contains filtered or unexported fields
}
BumpOperation performs a version bump on a module.
func NewBumpOperation ¶
func NewBumpOperation(fs core.FileSystem, bumpType BumpType, preRelease, metadata string, preserveMetadata bool) *BumpOperation
NewBumpOperation creates a new bump operation.
func (*BumpOperation) Name ¶
func (op *BumpOperation) Name() string
Name returns the name of this operation.
type PreOperation ¶
type PreOperation struct {
// contains filtered or unexported fields
}
PreOperation sets or increments pre-release labels on a module.
func NewPreOperation ¶
func NewPreOperation(fs core.FileSystem, label string, increment bool) *PreOperation
NewPreOperation creates a new pre-release operation.
func (*PreOperation) Name ¶
func (op *PreOperation) Name() string
Name returns the name of this operation.
type SetOperation ¶
type SetOperation struct {
// contains filtered or unexported fields
}
SetOperation sets the version of a module to a specific value.
func NewSetOperation ¶
func NewSetOperation(fs core.FileSystem, version string) *SetOperation
NewSetOperation creates a new set operation.
func (*SetOperation) Name ¶
func (op *SetOperation) Name() string
Name returns the name of this operation.
type ShowOperation ¶
type ShowOperation struct {
// contains filtered or unexported fields
}
ShowOperation reads and displays the current version of a module.
func NewShowOperation ¶
func NewShowOperation(fs core.FileSystem) *ShowOperation
NewShowOperation creates a new show operation.
func (*ShowOperation) Execute ¶
Execute reads the version from the module. The version is stored in the module's CurrentVersion field.
func (*ShowOperation) Name ¶
func (op *ShowOperation) Name() string
Name returns the name of this operation.
type ValidateOperation ¶
type ValidateOperation struct {
// contains filtered or unexported fields
}
ValidateOperation validates the version file of a module.
func NewValidateOperation ¶
func NewValidateOperation(fs core.FileSystem) *ValidateOperation
NewValidateOperation creates a new validate operation.
func (*ValidateOperation) Execute ¶
Execute validates the version file in the module. The current version is stored in the module's CurrentVersion field on success.
func (*ValidateOperation) Name ¶
func (op *ValidateOperation) Name() string
Name returns the name of this operation.