Skip to content

Commit

Permalink
fix: set variables and flag for message
Browse files Browse the repository at this point in the history
  • Loading branch information
kha7iq committed May 20, 2021
1 parent a4146c8 commit 36a6d8a
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions service/zulip/zulip.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,33 +85,30 @@ You can specify multiple userIds by separating the value with ','.`,
Destination: &zulipOpts.Type,
Name: "type",
Aliases: []string{},
Required: true,
Usage: "The type of message to be sent. private for a private message and stream for a stream message.",
EnvVars: []string{},
EnvVars: []string{"ZULIP_MSG_TYPE"},
},
&cli.StringFlag{
Destination: &zulipOpts.To,
Name: "to",
Aliases: []string{},
Required: true,
Usage: "For stream messages, the name of the stream. For private messages, csv of email addresses",
EnvVars: []string{},
EnvVars: []string{"ZULIP_STREAM_NAME"},
},
&cli.StringFlag{
Destination: &zulipOpts.Topic,
Name: "topic",
Aliases: []string{},
Required: true,
Usage: "The topic of the message. Only required for stream messages (type=\"stream\"), ignored otherwise.",
EnvVars: []string{},
Usage: "The topic of the message. Only required for stream messages 'type=stream', ignored otherwise.",
EnvVars: []string{"ZULIP_TOPIC"},
},
&cli.StringFlag{
Destination: &zulipOpts.Content,
Name: "content",
Name: "msg",
Aliases: []string{},
Required: true,
Usage: "The content of the message.",
EnvVars: []string{},
EnvVars: []string{"ZULIP_MESSAGE"},
},
},
Action: func(ctx *cli.Context) error {
Expand Down

0 comments on commit 36a6d8a

Please sign in to comment.