execute

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2019 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CommandFlags added in v0.5.0

type CommandFlags string

CommandFlags creates custom type for flags in botkube

const (
	ClusterFlag    CommandFlags = "--cluster-name"
	FollowFlag     CommandFlags = "--follow"
	AbbrFollowFlag CommandFlags = "-f"
	WatchFlag      CommandFlags = "--watch"
	AbbrWatchFlag  CommandFlags = "-w"
)

Defines botkube flags

func (CommandFlags) String added in v0.5.0

func (flag CommandFlags) String() string

type DefaultExecutor

type DefaultExecutor struct {
	Message       string
	AllowKubectl  bool
	ClusterName   string
	ChannelName   string
	IsAuthChannel bool
}

DefaultExecutor is a default implementations of Executor

func (*DefaultExecutor) Execute

func (e *DefaultExecutor) Execute() string

Execute executes commands and returns output

type Executor

type Executor interface {
	Execute() string
}

Executor is an interface for processes to execute commands

func NewDefaultExecutor

func NewDefaultExecutor(msg string, allowkubectl bool, clusterName, channelName string, isAuthChannel bool) Executor

NewDefaultExecutor returns new Executor object

type FiltersAction added in v0.8.0

type FiltersAction string

FiltersAction for options in filter commands

const (
	FilterList    FiltersAction = "list"
	FilterEnable  FiltersAction = "enable"
	FilterDisable FiltersAction = "disable"
)

Filter command options

func (FiltersAction) String added in v0.8.0

func (action FiltersAction) String() string

type NotifierAction added in v0.5.0

type NotifierAction string

NotifierAction creates custom type for notifier actions

const (
	Start      NotifierAction = "start"
	Stop       NotifierAction = "stop"
	Status     NotifierAction = "status"
	ShowConfig NotifierAction = "showconfig"
)

Defines constants for notifier actions

func (NotifierAction) String added in v0.5.0

func (action NotifierAction) String() string

Jump to

Keyboard shortcuts

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