-
Notifications
You must be signed in to change notification settings - Fork 50
/
Copy pathon_issue_opened.yml
32 lines (26 loc) · 1001 Bytes
/
on_issue_opened.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
name: On issue opened
on:
issues:
types: [opened]
jobs:
respond-to-issue:
runs-on: ubuntu-latest
steps:
- name: Post Automated Response
uses: actions/github-script@v6
with:
script: |
const issueNumber = context.payload.issue.number;
// Automated response message
const message = `
Please note that GitHub issues are meant for developer support.
- If this is a **user support request**, please contact us on [help@adalite.io](help@adalite.io).
- ⚠️ Be cautious of **scammers** pretending to be official support. Do not trust responses from anybody other than members of this repository.
`;
// Post the comment to the issue
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issueNumber,
body: message,
});