Skip to content

Commit 69f95fd

Browse files
authored
Added configuration to enable tracking and monitoring of GitHub issues (SharePoint#10183)
* Added configuration to enable tracking and monitoring of GitHub issues * Update resourceManagement.yml
1 parent cdc4f77 commit 69f95fd

File tree

1 file changed

+115
-0
lines changed

1 file changed

+115
-0
lines changed
Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,115 @@
1+
id: bot-issue-management
2+
name: Issue Management
3+
description: Enable tracking & monitoring of issues
4+
resource: repository
5+
disabled: false
6+
configuration:
7+
resourceManagementConfiguration:
8+
scheduledSearches:
9+
- description: Close answered issues after 3 days of inactivity
10+
frequencies:
11+
- hourly: { hour: 0 }
12+
filters:
13+
- isIssue
14+
- isOpen
15+
- hasLabel: { label: status:answered }
16+
- noActivitySince: { days: 3 }
17+
actions:
18+
- addReply:
19+
reply: >
20+
Closing this issue as "answered". If you encounter a similar issue(s), please open up a new issue. See our wiki for more details: [Issue-List: Our approach to closed issues](https://github.com/SharePoint/sp-dev-docs/wiki/Issue-List#our-approach-to-closed-issues)
21+
- closeIssue
22+
- lockIssue:
23+
reason: resolved
24+
25+
- description: Close stale issues with no recent author activity after 7 days
26+
frequencies:
27+
- hourly: { hour: 6 }
28+
filters:
29+
- isIssue
30+
- isOpen
31+
- hasLabel: { label: 'Needs: Author Feedback' }
32+
- hasLabel: { label: no-recent-activity }
33+
- noActivitySince: { days: 7 }
34+
actions:
35+
- addReply:
36+
reply: >
37+
Closing issue due to no response from the original author. Please refer to our wiki for more details, including how to remediate this action if you feel this was done prematurely or in error: [No response from the original issue author](https://github.com/SharePoint/sp-dev-docs/wiki/Issue-List#no-response-from-the-original-issue-author)
38+
- closeIssue
39+
- lockIssue
40+
41+
- description: Mark issues as no recent activity after 7 days
42+
frequencies:
43+
- hourly: { hour: 6 }
44+
filters:
45+
- isIssue
46+
- isOpen
47+
- hasLabel: { label: 'Needs: Author Feedback' }
48+
- noActivitySince: { days: 7 }
49+
actions:
50+
- addLabel: { label: no-recent-activity }
51+
- addReply:
52+
reply: >
53+
This issue has been automatically marked as stale because it has marked as requiring author feedback but has not had any activity for **7 days**. It will be closed if no further activity occurs **within the next 7 days of this comment**. Please see our wiki for more information: [Issue List Labels: Needs Author Feedback](https://github.com/SharePoint/sp-dev-docs/wiki/Issue-List-Labels#needs-author-feedback) & [Issue List: No response from the original issue author](https://github.com/SharePoint/sp-dev-docs/wiki/Issue-List#no-response-from-the-original-issue-author)
54+
55+
- description: Lock issues inactive 7 days after closing
56+
frequencies:
57+
- hourly: { hour: 6 }
58+
filters:
59+
- isIssue
60+
- isClosed
61+
- noActivitySince: { days: 7 }
62+
- isUnlocked
63+
actions:
64+
- addReply:
65+
reply: >
66+
Issues that have been closed & had no follow-up activity for at least 7 days are automatically locked. Please refer to our wiki for more details, including how to remediate this action if you feel this was done prematurely or in error: [Issue List: Our approach to locked issues](https://github.com/SharePoint/sp-dev-docs/wiki/Issue-List#our-approach-to-locked-issues)
67+
- lockIssue:
68+
reason: resolved
69+
70+
eventResponderTasks:
71+
- if:
72+
- payloadType: Issues
73+
- isAction: { action: opened }
74+
- not:
75+
isAssignedToSomeone: true
76+
then:
77+
- addReply:
78+
reply: >
79+
Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.
80+
- addLabel:
81+
label: 'Needs: Triage :mag:'
82+
83+
- if:
84+
- payloadType: Issue_Comment
85+
- isActivitySender: { issueAuthor: true }
86+
- hasLabel: { label: 'Needs: Author Feedback' }
87+
- isOpen
88+
then:
89+
- addLabel:
90+
label: 'Needs: Attention :wave:'
91+
92+
- if:
93+
- payloadType: Issues
94+
- isActivitySender: { issueAuthor: true }
95+
- not:
96+
isAction: { action: closed }
97+
- hasLabel: { label: 'Needs: Author Feedback' }
98+
then:
99+
- removeLabel: { label: 'Needs: Author Feedback' }
100+
101+
- if:
102+
- payloadType: Issues
103+
- not:
104+
isActivitySender: { user: microsoft-github-policy-service }
105+
- not:
106+
isAction: { action: closed }
107+
- hasLabel: { label: no-recent-activity }
108+
then:
109+
- removeLabel: { label: no-recent-activity }
110+
111+
- if:
112+
- payloadType: Issue_Comment
113+
- hasLabel: { label: no-recent-activity }
114+
then:
115+
- removeLabel: { label: no-recent-activity }

0 commit comments

Comments
 (0)