command

package
v0.7.18-alpha Latest Latest
Warning

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

Go to latest
Published: Jan 1, 2022 License: MIT Imports: 7 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
	ConfigFilePath string
	Local          bool // 本地执行
	OptionFunc     map[string]interface{}
}

Item 初始化赋值实体

type OperationItem

type OperationItem struct {
	B          []byte
	Logger     *logrus.Logger
	OptionFunc map[string]interface{}
	UnitTest   bool
	Local      bool // 本地
}

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