Skip to content
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

feat: Allow excluding the Github Actor from the message #112

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ondrosh
Copy link

@ondrosh ondrosh commented Oct 13, 2021

Issue

There is currently no way to exclude the Github Actor from being in the message.

Solution

According to the Slack API documentation, the author_link and author_icon values only work if author_name is present.

With omitempty specified on the author_name within the Attachment structure, allowing SLACK_MSG_AUTHOR to be an empty string will result in this field being unset which will allow users to choose if they want to exclude the Github Actor from being in the message.

Changes

  • Update main.sh to use = instead of :- on setting the GITHUB_ACTOR which avoids empty strings being substituted
  • Update README.md with details on how to avoid including the Github Actor in the message

@shvixxl
Copy link

shvixxl commented Nov 10, 2021

Actually, I have successfully excluded it from the message by using ' ' as a value for SLACK_MSG_AUTHOR

@alexanderkranga
Copy link

Thanks @lazy-octopus-kebab , this works as a workaround:

env:
  SLACK_MSG_AUTHOR: ' '

But merging this PR would definitely help us too!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants