cmd

package
v4.3.1 Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Main

Main scaffolds a file that defines the controller manager entry point

func (*Main) SetTemplateDefaults

func (f *Main) SetTemplateDefaults() error

SetTemplateDefaults implements file.Template

type MainUpdater

type MainUpdater struct {
	machinery.RepositoryMixin
	machinery.MultiGroupMixin
	machinery.ResourceMixin

	// Flags to indicate which parts need to be included when updating the file
	WireResource, WireController, WireWebhook bool

	// Deprecated - The flag should be removed from go/v5
	// IsLegacyPath indicates if webhooks should be scaffolded under the API.
	// Webhooks are now decoupled from APIs based on controller-runtime updates and community feedback.
	// This flag ensures backward compatibility by allowing scaffolding in the legacy/deprecated path.
	IsLegacyPath bool
}

MainUpdater updates cmd/main.go to run Controllers

func (*MainUpdater) GetCodeFragments

func (f *MainUpdater) GetCodeFragments() machinery.CodeFragmentsMap

GetCodeFragments implements file.Inserter

func (*MainUpdater) GetIfExistsAction

func (*MainUpdater) GetIfExistsAction() machinery.IfExistsAction

GetIfExistsAction implements file.Builder

func (*MainUpdater) GetMarkers

func (f *MainUpdater) GetMarkers() []machinery.Marker

GetMarkers implements file.Inserter

func (*MainUpdater) GetPath

func (*MainUpdater) GetPath() string

GetPath implements file.Builder

Jump to

Keyboard shortcuts

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