-
Notifications
You must be signed in to change notification settings - Fork 12
44 lines (41 loc) · 1.67 KB
/
matrix-bot.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: Matrix bot
on:
pull_request_target:
types: [opened, closed]
jobs:
new-pr:
if: github.event.action == 'opened' && github.repository == 'future-proof-iot/RIOT-rs'
runs-on: ubuntu-latest
continue-on-error: true
steps:
- name: send message
uses: s3krit/matrix-message-action@v0.0.3
with:
room_id: ${{ secrets.MATRIX_ROOM_ID }}
access_token: ${{ secrets.MATRIX_ACCESS_TOKEN }}
message: "New PR: [${{ github.event.pull_request.title }}](${{ github.event.pull_request.html_url }})"
server: "matrix.org"
merged-pr:
if: github.event.action == 'closed' && github.event.pull_request.merged == true && github.repository == 'future-proof-iot/RIOT-rs'
runs-on: ubuntu-latest
continue-on-error: true
steps:
- name: send message
uses: s3krit/matrix-message-action@v0.0.3
with:
room_id: ${{ secrets.MATRIX_ROOM_ID }}
access_token: ${{ secrets.MATRIX_ACCESS_TOKEN }}
message: "PR merged: [${{ github.event.pull_request.title }}](${{ github.event.pull_request.html_url }})"
server: "matrix.org"
abandoned-pr:
if: github.event.action == 'closed' && github.event.pull_request.merged == false && github.repository == 'future-proof-iot/RIOT-rs'
runs-on: ubuntu-latest
continue-on-error: true
steps:
- name: send message
uses: s3krit/matrix-message-action@v0.0.3
with:
room_id: ${{ secrets.MATRIX_ROOM_ID }}
access_token: ${{ secrets.MATRIX_ACCESS_TOKEN }}
message: "PR closed without merging: [${{ github.event.pull_request.title }}](${{ github.event.pull_request.html_url }})"
server: "matrix.org"