factory

package
v3.16.0 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Factory

type Factory struct {
	Config        *config.Config
	GitRepository *git.Repository
	GraphQLClient graphql.Client
	RestAPIClient *buildkite.Client
	Version       string
	SkipConfirm   bool
	NoInput       bool
	Quiet         bool
}

func New

func New(version string) (*Factory, error)

func (*Factory) SetGlobalFlags added in v3.14.2

func (f *Factory) SetGlobalFlags(cmd *cobra.Command)

SetGlobalFlags reads the global persistent flags and sets them on the factory. This should be called in PreRunE of Cobra commands that need to use global flags. It's safe to call multiple times and will only set flags if they're present.

NOTE: This is only used by legacy Cobra commands. Kong commands receive global flags via cli.GlobalFlags which are set at the root level and work in any position (e.g., bk --yes job cancel <id>).

Jump to

Keyboard shortcuts

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