mirror of
https://github.com/rtic-rs/rtic.git
synced 2024-11-23 20:22:51 +01:00
Added matrix bot
This commit is contained in:
parent
f24e9264b1
commit
2e5e7698b6
1 changed files with 44 additions and 0 deletions
44
.github/workflows/matrix-bot.yml
vendored
Normal file
44
.github/workflows/matrix-bot.yml
vendored
Normal file
|
@ -0,0 +1,44 @@
|
||||||
|
name: Matrix bot
|
||||||
|
on:
|
||||||
|
pull_request_target:
|
||||||
|
types: [opened, closed]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
new-pr:
|
||||||
|
if: github.event.action == 'opened' && github.repository == 'rtic-rs/cortex-m-rtic'
|
||||||
|
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 == 'rtic-rs/cortex-m-rtic'
|
||||||
|
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 == 'rtic-rs/cortex-m-rtic'
|
||||||
|
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"
|
Loading…
Reference in a new issue