cmdutil

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Sep 4, 2019 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfigureRunnableAndCommandWithTargeting

func ConfigureRunnableAndCommandWithTargeting(runnable Runnable, cmd *cobra.Command)

func GenericRun

func GenericRun(o Runnable, cmd *cobra.Command, args []string)

Types

type ComponentTargetingOptions

type ComponentTargetingOptions struct {
	ComponentPath  string
	ComponentName  string
	DescriptorPath string
	// contains filtered or unexported fields
}

func NewTargetingOptions

func NewTargetingOptions() *ComponentTargetingOptions

func (*ComponentTargetingOptions) AttachFlagTo

func (o *ComponentTargetingOptions) AttachFlagTo(cmd *cobra.Command)

func (*ComponentTargetingOptions) Complete

func (o *ComponentTargetingOptions) Complete(name string, cmd *cobra.Command, args []string) error

func (*ComponentTargetingOptions) Run

func (*ComponentTargetingOptions) Validate

func (o *ComponentTargetingOptions) Validate() error

type Runnable

type Runnable interface {
	Complete(name string, cmd *cobra.Command, args []string) error
	Validate() error
	Run() error
}

Jump to

Keyboard shortcuts

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