internal

package
v0.0.0-...-d6af17e Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2026 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnumerateBumpableModules

func EnumerateBumpableModules(taggable []string) []string

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

func EnumerateTaggableModules() ([]string, error)

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) Apply

func (m *ModuleBump) Apply(ctx context.Context, targetModule string) (bool, error)

Apply replaces the module version in the given target module.

func (*ModuleBump) DryRunApply

func (m *ModuleBump) DryRunApply(ctx context.Context, targetModule string) (bool, error)

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.

func (*ModuleBumps) PushTags

func (m *ModuleBumps) PushTags(ctx context.Context) error

PushTags pushes the tags to the remote repository.

Jump to

Keyboard shortcuts

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