-
Notifications
You must be signed in to change notification settings - Fork 414
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
Add support for icon_emoji #477
Comments
Hey mike am a newbie to jenkinsci.Can I have a brief description about this task |
Well I think this is a simple thing really, I would try it my self but I don't have a self-hosted jenkins install where I could test the changes, however this should be very similar to what we do for I'd say that to start with we need to add "set/get Icon_Emoji" like we do for channel and botUser: slack-plugin/src/main/java/jenkins/plugins/slack/workflow/SlackSendStep.java Lines 94 to 106 in 6be0492
then we can have that in |
Oh one thing to note is the icon_emoji is optional, not mandatory |
Thanks @mike-pt .So it's just adding setter and getter for imoji.If its so if you dont mind shall I try this task |
I don't mind at all I can only thank you for taking the time! |
@Akayeshmantha curious if you were able to make some progress on this |
Is anyone currently plan to work on this issue? It is not assigned to anyone. |
Feel free to contribute 😓 |
I've been messing with this a bit, but can't get it to work. I've added a parameter for It gets put into the json just like all of the other parameters, but is ignored. My current guess is that the colon's aren't getting encoded properly. The documentation also says that if the My only other guess is that |
@EricBartusch This depends whether you're using a bot user or a webhook. |
You must use a bot user to use the Custom webhooks is a legacy feature: https://api.slack.com/custom-integrations/incoming-webhooks which mentions it does support I doubt https://my.slack.com/services/new/jenkins-ci supports |
Thanks @Casz, I had spent way to long trying to make that work. I did manage to get it working with a bot user, but I had to remove the line hardcoding slack-plugin/src/main/java/jenkins/plugins/slack/StandardSlackService.java Lines 172 to 176 in 06b17f2
The documentation says when setting it to false, that the username should also be set. In my testing, I haven't done so, and the messages that get sent default to the bot's name, so I don't know how important it is. Also, is there a reason why it was being hardcoded to true in the first place? |
@EricBartusch no reason looking at the PR that added it #258 also |
The Looks like |
adding both username and icon_emoji make sense 👍 |
This was done awhile ago and has been released |
Thanks, linking the PR (#578) here for future reference |
Currently we can not set
icon_emoji
via slackSend, which means all notifications come with the Jenkins icon.It would be nice to be able to change this, particularly cause we could base it on the state of the Job and even use different emoji based on that (like with colors)
The text was updated successfully, but these errors were encountered: