command

package
v1.7.0 Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2021 License: MIT Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetCommands

func GetCommands(slackClient client.SlackClient, cfg config.Config) *bot.Commands

GetCommands returns the list of default command which are available

func NewAddButtonCommand added in v1.3.0

func NewAddButtonCommand(base bot.BaseCommand, cfg config.Server) bot.Command

NewAddButtonCommand is more or less internal command to add a link button to the posted message

func NewAddLinkCommand

func NewAddLinkCommand(base bot.BaseCommand) bot.Command

NewAddLinkCommand is more or less internal command to add a link button to the posted message

func NewCommands added in v1.6.3

func NewCommands(base bot.BaseCommand, macros []config.Command) bot.Command

NewCommands defines custom commands by defining a trigger (regexp) and a list of commands which should be executed it also supports placeholders by {{ .param }} using the regexp group name

func NewDelayCommand

func NewDelayCommand(base bot.BaseCommand) bot.Command

NewDelayCommand delays the command execution by the given time

func NewHelpCommand

func NewHelpCommand(base bot.BaseCommand, commands *bot.Commands) bot.Command

NewHelpCommand provides information about all registered commands with description and examples

func NewRandomCommand

func NewRandomCommand(base bot.BaseCommand) bot.Command

NewRandomCommand will reply a random entry

func NewReactionCommand

func NewReactionCommand(base bot.BaseCommand) bot.Command

NewReactionCommand simply adds a reaction to the current message...used in "commands" and other internal commands

func NewReplyCommand

func NewReplyCommand(base bot.BaseCommand) bot.Command

NewReplyCommand is a command to reply a message in current thread/channel

func NewRetryCommand

func NewRetryCommand(base bot.BaseCommand, cfg *config.Config) bot.Command

NewRetryCommand store the history of the commands of the user sent to the bot in a local storage With "retry" the most recent command of the channel will be repeated

func NewSendMessageCommand

func NewSendMessageCommand(base bot.BaseCommand) bot.Command

NewSendMessageCommand is able to send a message to any user/channel

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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