command

package
v0.8.3 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultLogger *logrus.Logger

Functions

This section is empty.

Types

type Item

type Item struct {
	Cmd            *cobra.Command
	DefaultConfig  []byte
	Fnc            func(item OperationItem) RunErr
	SkipConfirm    bool
	ConfigFilePath string
	LocalRun       bool // 本地执行
	OptionFunc     map[string]interface{}
}

Item 初始化赋值实体

type OperationItem

type OperationItem struct {
	B           []byte
	Logger      *logrus.Logger
	OptionFunc  map[string]interface{}
	Interface   interface{}
	UnitTest    bool
	SkipConfirm bool
	Mock        bool
	LocalRun    bool // 本地
	SSHTimeout  time.Duration
}

OperationItem 操作实体

type RunErr

type RunErr struct {
	Msg string
	Err error
}

RunErr 执行error异常

func SetExecutorDefault

func SetExecutorDefault(item Item) (runErr RunErr)

SetExecutorDefault executor赋值

func (RunErr) Error

func (err RunErr) Error() string

Jump to

Keyboard shortcuts

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