Add status automation (#17939)
* Add status automation Co-authored-by: chiedo <chiedo@users.noreply.github.com>
This commit is contained in:
23
.github/workflows/post-status-updates-to-slack.yml
vendored
Normal file
23
.github/workflows/post-status-updates-to-slack.yml
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
name: Epic Status Update
|
||||
on:
|
||||
issue_comment:
|
||||
types: [created]
|
||||
jobs:
|
||||
post-status-updates-to-slack:
|
||||
runs-on: ubuntu-latest
|
||||
if: contains(github.event.comment.body, '_created with') && contains(github.event.comment.body, 'typing_ `/status`')
|
||||
steps:
|
||||
- name: Trim HTML comments
|
||||
id: trimmed
|
||||
uses: ashley-taylor/regex-property-action@93a24f845cd20790924208225cc72da8b4c6d46d
|
||||
with:
|
||||
value: ${{github.event.comment.body}}
|
||||
regex: '<!--(.*?)-->'
|
||||
replacement: ''
|
||||
- name: Send Slack notification
|
||||
uses: archive/github-actions-slack@d368c5a4ad757515a9344918f84c490b05777d94
|
||||
id: notify
|
||||
with:
|
||||
slack-channel: 'C01EEKVR0Q7'
|
||||
slack-bot-user-oauth-access-token: ${{ secrets.SLACK_DOCS_BOT_TOKEN }}
|
||||
slack-text: \n><${{ github.event.comment.html_url}}|*${{github.event.issue.title}}*>\nstatus update posted by ${{github.event.comment.user.login}}\n\n${{ steps.trimmed.outputs.value }}
|
||||
Reference in New Issue
Block a user