You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
822 B

5 years ago
package main
import "samhofi.us/x/keybase"
5 years ago
// Command outlines a command
type Command struct {
5 years ago
Cmd []string // Any aliases that trigger this command
Description string // A short description of the command
Help string // The full help text explaining how to use the command
Exec func([]string) // A function that takes the command (arg[0]) and any arguments (arg[1:]) as input
5 years ago
}
// TypeCommand outlines a command that reacts on message type
type TypeCommand struct {
Cmd []string // Message types that trigger this command
Name string // The name of this command
Description string // A short description of the command
5 years ago
Exec func(keybase.ChatAPI) // A function that takes a raw chat message as input
}