-
Notifications
You must be signed in to change notification settings - Fork 2
34 lines (31 loc) · 984 Bytes
/
issue_manager.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
name: Issue Manager
on:
issues:
types:
- labeled
jobs:
on_duplicate:
if: github.event.label.name == 'duplicate'
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- name: Add comment
uses: peter-evans/create-or-update-comment@5f728c3dae25f329afbe34ee4d08eef25569d79f
with:
issue-number: ${{ github.event.issue.number }}
body: |
This issue is a duplicate!
Please make sure to check for existing issues in this repository before submitting an issue.
If you believe this is a mistake, feel free to reply.
- name: Close issue
uses: actions/github-script@v6
with:
script: |
github.rest.issues.update({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
state: "closed",
state_reason: "not_planned"
});