Skip to content

Commit 0f51831

Browse files
authored
[TEST] Testing an issue triage bot (#123)
1 parent 15d6322 commit 0f51831

1 file changed

Lines changed: 118 additions & 0 deletions

File tree

Lines changed: 118 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
name: Issue Triage
2+
description: Assign label to new issues without a label
3+
resource: repository
4+
disabled: false
5+
6+
configuration:
7+
resourceManagementConfiguration:
8+
eventResponderTasks:
9+
- description: Check if a Type label is assigned to new issues
10+
triggerOnOwnActions: false
11+
if:
12+
- payloadType: Issues
13+
- isOpen
14+
- not:
15+
or:
16+
- hasLabel:
17+
label: Bug
18+
- hasLabel:
19+
label: Feature
20+
- hasLabel:
21+
label: SupportRequest
22+
then:
23+
- addReply:
24+
reply: "${issueAuthor}, please add a Bug/Feature/SupportRequest label as applicable."
25+
- addLabel:
26+
label: waitingForCustomer
27+
- addLabel:
28+
label: untriaged
29+
- description: Update issue if Type label was assigned # removes waitingForCustomer + untriaged if someone assigns a type label
30+
triggerOnOwnActions: false
31+
if:
32+
- payloadType: Issues
33+
- isOpen
34+
- or:
35+
- labelAdded:
36+
label: Bug
37+
- labelAdded:
38+
label: Feature
39+
- labelAdded:
40+
label: SupportRequest
41+
then:
42+
- if:
43+
- hasLabel:
44+
label: untriaged
45+
then:
46+
- removeLabel:
47+
label: untriaged
48+
- if:
49+
- not:
50+
hasLabel:
51+
label: triaged
52+
then:
53+
- addLabel:
54+
label: triaged
55+
- if:
56+
- hasLabel:
57+
label: waitingForCustomer
58+
then:
59+
- removeLabel:
60+
label: waitingForCustomer
61+
- description: Update issues that had recent activity
62+
triggerOnOwnActions: false
63+
if:
64+
- payloadType: Issues
65+
- isOpen
66+
- isAction:
67+
action: Issue_Comment # create or update (applies to issue description too?)
68+
then:
69+
- if:
70+
- hasLabel:
71+
label: stale
72+
then:
73+
- removeLabel:
74+
label: stale
75+
scheduledSearches:
76+
- description: search for issues that are waitingForCustomer and haven't got a response
77+
frequencies:
78+
- hourly:
79+
hour: 1
80+
filters:
81+
- isOpen
82+
- hasLabel:
83+
label: waitingForCustomer
84+
- noActivitySince:
85+
days: 1
86+
actions:
87+
- addLabel:
88+
label: stale
89+
- description: close issues that are waitingForCustomer + stale for too long
90+
frequencies:
91+
- daily:
92+
time: 20:45
93+
filters:
94+
- isOpen
95+
- hasLabel:
96+
label: waitingForCustomer
97+
- hasLabel:
98+
label: stale
99+
- noActivitySince:
100+
days: 1
101+
actions:
102+
- closeIssue
103+
- addReply:
104+
reply: "${issueAuthor}, this issue has been closed due to inactivity. Please feel free to reopen it if you have further information or questions."
105+
- description: close issues that have not received any activity in 18 months
106+
frequencies:
107+
- daily:
108+
time: 20:45
109+
filters:
110+
- isOpen
111+
- noActivitySince:
112+
days: 1
113+
- hasLabel:
114+
label: triageTest
115+
actions:
116+
- closeIssue
117+
- addReply:
118+
reply: "${issueAuthor}, this issue has been closed due to inactivity. Please feel free to reopen it if you have further information or questions."

0 commit comments

Comments
 (0)