-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adding new feature to treehouses message discord
#2138
base: master
Are you sure you want to change the base?
Conversation
else | ||
log_comment_and_exit1 "ERROR: message not delivered" | ||
fi | ||
;; | ||
*) | ||
log_help_and_exit1 "Error: This command does not exist" message |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Error message could be updated to explicitly list all the Discord commands that exist.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm still in the rough draft stages >.<
@@ -509,6 +509,42 @@ function message { | |||
echo "you have successfully authorized and your access token is $access_token " | |||
fi | |||
;; | |||
webhook) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could echo error message if webhook and/or apitoken isn't provided:
e.g.
Error: Please add a webhook URL.
|
||
echo "Your webhook url is $webhook_url" | ||
;; | ||
send) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should account for empty messages. Empty messages generate this error:
line 542: {"message":: command not found
ERROR: message not delivered
New feature:
webhook
pulls info from the Discord API.send
sends a message to your selected discord channel.Can add multiple channels.