-
Notifications
You must be signed in to change notification settings - Fork 36
26 lines (26 loc) · 1.03 KB
/
issuetracker.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
name: issue-announce
on:
issues:
types: [opened]
permissions:
issues: read
jobs:
build:
runs-on: ubuntu-latest
env:
ISSUE_TITLE: "${{ github.event.issue.title }}"
steps:
- name: Git Issue Details
run: |
export issue_title=$(echo "$ISSUE_TITLE" | sed -e "s/'//g" -e 's/"//g')
echo "Issue creator: ${{ github.event.issue.user.login }}"
echo "Issue title: $ISSUE_TITLE"
echo "Issue number: ${{ github.event.issue.number }}"
echo "Issue url: ${{ github.event.issue.html_url }}"
echo "Using issue_title: $issue_title"
- name: Google Chat Notification
run: |
export issue_title=$(echo "$ISSUE_TITLE" | sed -e "s/'//g" -e 's/"//g')
curl --location --request POST '${{ secrets.WEBHOOK }}' \
--header 'Content-Type: application/json; charset=UTF-8' \
--data "{'text': '[${{ github.event.issue.number }}] ${{ github.event.issue.html_url }} $issue_title (${{ github.event.issue.user.login }})'}"