uxHelpers

package
v1.0.55 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2025 License: MIT Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckZeropsProcessWithProcessOutputCallback added in v1.0.38

func CheckZeropsProcessWithProcessOutputCallback(callback ProcessCallback) gn.Option[checkZeropsProcessSetup]

func PrintOrgSelector

func PrintOrgSelector(
	ctx context.Context,
	restApiClient *zeropsRestApiClient.Handler,
	opts ...OrgSelectorOption,
) (entity.Org, error)

func PrintProjectList

func PrintProjectList(
	ctx context.Context,
	restApiClient *zeropsRestApiClient.Handler,
	out io.Writer,
) error

func PrintProjectSelector

func PrintProjectSelector(
	ctx context.Context,
	restApiClient *zeropsRestApiClient.Handler,
	opts ...ProjectSelectorOption,
) (optional.Null[entity.Project], error)

func PrintServiceList

func PrintServiceList(
	ctx context.Context,
	restApiClient *zeropsRestApiClient.Handler,
	out io.Writer,
	project entity.Project,
) error

func PrintServiceSelector

func PrintServiceSelector(
	ctx context.Context,
	restApiClient *zeropsRestApiClient.Handler,
	project entity.Project,
	opts ...ServiceSelectorOption,
) (optional.Null[entity.Service], error)

func PrintSetupList added in v1.0.46

func PrintSetupList(
	out io.Writer,
	setups []string,
) error

func PrintSetupSelector added in v1.0.46

func PrintSetupSelector(
	ctx context.Context,
	setups []string,
) (string, error)

func ProcessCheckWithSpinner

func ProcessCheckWithSpinner(
	ctx context.Context,
	uxBlocks *uxBlock.Blocks,
	processList []Process,
) error

func YesNoPrompt added in v1.0.8

func YesNoPrompt(
	ctx context.Context,
	question string,
	opts ...prompt.Option,
) (bool, error)

Types

type OrgSelectorOption added in v1.0.46

type OrgSelectorOption = gn.Option[orgSelectorConfig]

func WithOrgPickOnlyOneItem added in v1.0.46

func WithOrgPickOnlyOneItem(b bool) OrgSelectorOption

type Process

type Process struct {
	F                   ProcessFunc
	RunningMessage      string
	ErrorMessageMessage string
	SuccessMessage      string
	// contains filtered or unexported fields
}

func (*Process) LogView added in v1.0.38

func (p *Process) LogView(opts ...logView.Option) io.Writer

type ProcessCallback added in v1.0.38

type ProcessCallback func(ctx context.Context, process *Process, apiProcess output.Process) error

type ProcessFunc added in v1.0.38

type ProcessFunc func(ctx context.Context, process *Process) error

func CheckZeropsProcess

func CheckZeropsProcess(
	processId uuid.ProcessId,
	restApiClient *zeropsRestApiClient.Handler,
	options ...gn.Option[checkZeropsProcessSetup],
) ProcessFunc

type ProjectSelectorOption added in v1.0.46

type ProjectSelectorOption = gn.Option[projectSelectorConfig]

func WithCreateNewProject added in v1.0.46

func WithCreateNewProject(b bool) ProjectSelectorOption

func WithPreselectedProjectId added in v1.0.49

func WithPreselectedProjectId(projectId string) ProjectSelectorOption

type ServiceSelectorOption added in v1.0.46

type ServiceSelectorOption = gn.Option[serviceSelectorConfig]

func WithCreateNewService added in v1.0.46

func WithCreateNewService(b bool) ServiceSelectorOption

Jump to

Keyboard shortcuts

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