cmd

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Apr 20, 2020 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Root

type Root struct {
	*opts.Root

	Run      *RunCmd      `command:"run" description:"For running the bot"`
	Validate *ValidateCmd `command:"validate" description:"For validating configuration"`
	Simulate *SimulateCmd `command:"simulate" description:"For simulating an incoming message"`
}

type RunCmd

type RunCmd struct {
	*opts.Root `no-flags:"true"`
}

func (*RunCmd) Execute

func (c *RunCmd) Execute(_ []string) error

type SimulateArgs added in v0.8.0

type SimulateArgs struct {
	Origin  string `positional-arg-name:"ORIGIN-ID" description:"Channel or DM ID sending the request" required:"true"`
	Message string `positional-arg-name:"MESSAGE" description:"Message sent"`
}

type SimulateCmd added in v0.8.0

type SimulateCmd struct {
	*opts.Root `no-flags:"true"`

	Timestamp string       `long:"timestamp" description:"Timestamp of the message (default: now; format: 2006-01-02T15:04:05Z07:00)"`
	Args      SimulateArgs `positional-args:"true"`
}

func (*SimulateCmd) Execute added in v0.8.0

func (c *SimulateCmd) Execute(_ []string) error

type ValidateCmd

type ValidateCmd struct {
	*opts.Root `no-flags:"true"`
}

func (*ValidateCmd) Execute

func (c *ValidateCmd) Execute(_ []string) error

Jump to

Keyboard shortcuts

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