Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnumerateBumpableModules ¶
EnumerateBumpableModules returns a list of Go modules that can be bumped in the github.com/fluxcd/pkg repository. This includes all modules that are taggable, as well as specific modules that are not tagged but should still be considered for version bumps.
func EnumerateTaggableModules ¶
EnumerateTaggableModules traverses the current directory and returns the paths of directories containing Go modules that are taggable for release.
Types ¶
type ModuleBump ¶
type ModuleBump struct {
// contains filtered or unexported fields
}
ModuleBump represents a module version bump operation and helps applying the bump to target modules in the repository.
func NewModuleBump ¶
func NewModuleBump(module, oldVersion, newVersion string) (*ModuleBump, error)
NewModuleBump creates a ModuleBump for the given module with the old and new versions.
func NewModuleBumpForNewModule ¶
func NewModuleBumpForNewModule(module string) (*ModuleBump, error)
NewModuleBumpForNewModule creates a ModuleBump for a new module with an initial version.
func (*ModuleBump) DryRunApply ¶
DryRunApply replaces the module version in the given target module without writing changes.
func (*ModuleBump) String ¶
func (m *ModuleBump) String() string
String implements the fmt.Stringer interface for *ModuleBump.
type ModuleBumps ¶
type ModuleBumps struct {
// contains filtered or unexported fields
}
ModuleBumps represents a collection of module bumps that need to be applied to the repository.
func ComputeModuleBumps ¶
func ComputeModuleBumps(ctx context.Context) (*ModuleBumps, error)
ComputeModuleBumps looks at the current Git repository and computes the necessary module bumps based on the latest tags and changes in the codebase. It returns the modules that need to be bumped and their tags in the correct push order.
func (*ModuleBumps) ApplyInternalBumps ¶
func (m *ModuleBumps) ApplyInternalBumps(ctx context.Context) error
ApplyInternalBumps applies the module bumps to the file system.
func (*ModuleBumps) MustBumpInternalModules ¶
func (m *ModuleBumps) MustBumpInternalModules() bool
MustBumpInternalModules returns true if there are any module bumps that need to be applied to the current repository.
func (*ModuleBumps) MustPushTags ¶
func (m *ModuleBumps) MustPushTags() bool
MustPushTags tells whether the tags need to be pushed to the remote repository.
func (*ModuleBumps) PrintBumps ¶
func (m *ModuleBumps) PrintBumps()
PrintBumps prints the module bumps result in a human-readable format.
func (*ModuleBumps) PrintTags ¶
func (m *ModuleBumps) PrintTags()
PrintTags prints the tags that will be pushed to the remote repository.