Skip to content

Commit 448c3cb

Browse files
Add Consensus workflow for issue/pr comments (#2)
1 parent 3908e11 commit 448c3cb

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed

.github/workflows/command.yml

+41
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Consensus
2+
3+
on:
4+
issue_comment:
5+
types: [created]
6+
7+
jobs:
8+
consensus:
9+
if: ${{ (github.event.comment.author_association == 'COLLABORATOR' || github.event.comment.author_association == 'OWNER') && contains(github.event.comment.body, '/consensus') }}
10+
uses: withstudiocms/automations/.github/workflows/discord-msg.yml@main
11+
secrets:
12+
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK_CONSENSUS }}
13+
with:
14+
DISCORD_MESSAGE_EMBEDS: |
15+
[
16+
{
17+
"id": 661098315,
18+
"description": "<@&1309280037635231764> Please review the proposal and provide your feedback. If you agree, please react with a 👍. If you disagree, please react with a 👎.",
19+
"fields": [
20+
{
21+
"id": 259239853,
22+
"name": "Title",
23+
"value": "${{ github.event.issue.title }}",
24+
"inline": false
25+
},
26+
{
27+
"id": 888373040,
28+
"name": "Link",
29+
"value": "[Proposal](${{ github.event.issue.html_url }})",
30+
"inline": false
31+
},
32+
],
33+
"author": {
34+
"name": "withStudioCMS Roadmap",
35+
"icon_url": "https://github.com/astrolicious/studiocms/blob/main/www/assets/logo-discord.png?raw=true",
36+
"url": "https://github.com/withstudiocms/roadmap"
37+
},
38+
"title": "🚀 A proposal Consensus has been requested!",
39+
"color": 16561408
40+
}
41+
]

0 commit comments

Comments
 (0)