generated from brevdev/seed
-
Notifications
You must be signed in to change notification settings - Fork 9
/
textceo.go
45 lines (38 loc) · 1.55 KB
/
textceo.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package textceo
import (
"github.com/brevdev/brev-cli/pkg/cmd/completions"
"github.com/brevdev/brev-cli/pkg/entity"
"github.com/brevdev/brev-cli/pkg/store"
"github.com/brevdev/brev-cli/pkg/terminal"
"github.com/spf13/cobra"
)
var (
startLong = "Send a text message to our CEO, Nader"
startExample = "brev text-ceo -m 'Hi Nader, why is Microsoft a scorpion?'"
)
type TextCEOStore interface {
completions.CompletionStore
ResetWorkspace(workspaceID string) (*entity.Workspace, error)
GetAllWorkspaces(options *store.GetWorkspacesOptions) ([]entity.Workspace, error)
GetWorkspaces(organizationID string, options *store.GetWorkspacesOptions) ([]entity.Workspace, error)
GetActiveOrganizationOrDefault() (*entity.Organization, error)
GetCurrentUser() (*entity.User, error)
GetWorkspace(id string) (*entity.Workspace, error)
GetWorkspaceMetaData(workspaceID string) (*entity.WorkspaceMetaData, error)
}
func NewCmdTextCEO(t *terminal.Terminal, _ TextCEOStore) *cobra.Command {
cmd := &cobra.Command{
Annotations: map[string]string{"housekeeping": ""},
Use: "test",
DisableFlagsInUseLine: true,
Short: "Send a text message to our CEO, Nader",
Long: startLong,
Example: startExample,
Run: func(cmd *cobra.Command, args []string) {
t.Vprint("\ntest cmd\n")
},
}
// cmd.Flags().StringVarP(&message, "message", "m", "", "message to send Brev's CEO, Nader")
// cmd.Flags().StringVarP(&message, "phone", "p", "", "(Optional) leave a number for Nader to follow up")
return cmd
}