From 38a53e2ae115ea829a14ce2587b4389621783608 Mon Sep 17 00:00:00 2001 From: Jeff Handley Date: Tue, 6 Jun 2023 08:15:13 -0700 Subject: [PATCH] [fabricbot] Do not add needs-further-triage to issues still marked as untriaged (#87160) --- .github/fabricbot.json | 70 +++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 69 insertions(+), 1 deletion(-) diff --git a/.github/fabricbot.json b/.github/fabricbot.json index 5268b89..0d44054 100644 --- a/.github/fabricbot.json +++ b/.github/fabricbot.json @@ -2595,7 +2595,7 @@ "subCapability": "IssueCommentResponder", "version": "1.0", "config": { - "taskName": "Replace `needs-author-action` label with `needs-further-triage` label when the author comments on an issue", + "taskName": "Replace `needs-author-action` label with `needs-further-triage` label when the author comments on an issue that is not still untriaged", "actions": [ { "name": "addLabel", @@ -2638,6 +2638,74 @@ } }, { + "operator": "not", + "operands": [ + { + "name": "hasLabel", + "parameters": { + "label": "untriaged" + } + } + ] + }, + { + "name": "isOpen", + "parameters": {} + } + ] + } + } + }, + { + "taskSource": "fabricbot-config", + "taskType": "trigger", + "capabilityId": "IssueResponder", + "subCapability": "IssueCommentResponder", + "version": "1.0", + "config": { + "taskName": "Remove `needs-author-action` label when the author comments on an `untriaged` issue", + "actions": [ + { + "name": "removeLabel", + "parameters": { + "label": "needs-author-action" + } + } + ], + "eventType": "issue", + "eventNames": [ + "issue_comment" + ], + "conditions": { + "operator": "and", + "operands": [ + { + "name": "isAction", + "parameters": { + "action": "created" + } + }, + { + "name": "isActivitySender", + "parameters": { + "user": { + "type": "author" + } + } + }, + { + "name": "hasLabel", + "parameters": { + "label": "needs-author-action" + } + }, + { + "name": "hasLabel", + "parameters": { + "label": "untriaged" + } + }, + { "name": "isOpen", "parameters": {} } -- 2.7.4