2021-01-28 15:00:45 +01:00
|
|
|
name: issues
|
|
|
|
|
2021-01-31 22:01:41 +01:00
|
|
|
on:
|
|
|
|
issues:
|
|
|
|
types: [opened, reopened, closed]
|
2021-01-28 15:00:45 +01:00
|
|
|
|
|
|
|
jobs:
|
2021-06-08 15:37:23 +02:00
|
|
|
notify:
|
2021-01-28 15:00:45 +01:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2021-02-01 14:25:02 +01:00
|
|
|
- name: "notify: new"
|
2021-02-01 16:28:20 +01:00
|
|
|
if: github.event.issue.state == 'open'
|
2022-04-16 21:53:17 +02:00
|
|
|
uses: calamares/actions/matrix-notify@v4
|
2021-01-28 15:00:45 +01:00
|
|
|
with:
|
2021-05-25 16:25:30 +02:00
|
|
|
token: ${{ secrets.MATRIX_TOKEN }}
|
|
|
|
room: ${{ secrets.MATRIX_ROOM }}
|
2021-02-03 11:57:24 +01:00
|
|
|
message: "OPENED ${{ github.event.issue.html_url }} by ${{ github.actor }} ${{ github.event.issue.title }}"
|
2021-02-01 14:25:02 +01:00
|
|
|
- name: "notify: closed"
|
2021-02-01 16:28:20 +01:00
|
|
|
if: github.event.issue.state != 'open'
|
2022-04-16 21:53:17 +02:00
|
|
|
uses: calamares/actions/matrix-notify@v4
|
2021-01-31 22:01:41 +01:00
|
|
|
with:
|
2021-05-25 16:25:30 +02:00
|
|
|
token: ${{ secrets.MATRIX_TOKEN }}
|
|
|
|
room: ${{ secrets.MATRIX_ROOM }}
|
2021-02-03 11:57:24 +01:00
|
|
|
message: "CLOSED ${{ github.event.issue.html_url }} by ${{ github.actor }} ${{ github.event.issue.title }}"
|
2021-06-08 15:37:23 +02:00
|
|
|
- name: "remove in-progress label"
|
|
|
|
if: github.event.issue.state != 'open'
|
|
|
|
run: |
|
|
|
|
curl -X DELETE \
|
|
|
|
-H 'Accept: application/vnd.github.v3+json' \
|
|
|
|
-H 'Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' \
|
2021-06-08 16:49:06 +02:00
|
|
|
"https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/labels/hacking%3A%20in-progress"
|
2021-06-08 15:37:23 +02:00
|
|
|
|