-
Notifications
You must be signed in to change notification settings - Fork 226
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add generated policy to remove needs-triage when an area is added (#3366
) Generate the Microsoft policy service files to automatically to: - add/remove `needs-triage` automatically when there is no area or an area is added - add the area on PRs resolve #3340
- Loading branch information
1 parent
8424b2e
commit eac8011
Showing
17 changed files
with
889 additions
and
210 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,139 @@ | ||
# This file is generated by the sync-labels script DO NOT EDIT manually | ||
id: issues.triage | ||
name: New Issue Assign labels | ||
description: Assign labels to new issues | ||
resource: repository | ||
disabled: false | ||
configuration: | ||
resourceManagementConfiguration: | ||
eventResponderTasks: | ||
- description: Adds `needs-area` label for new unassigned issues | ||
if: | ||
- payloadType: Issues | ||
- isAction: | ||
action: Opened | ||
- not: | ||
and: | ||
- isAssignedToSomeone | ||
then: | ||
- addLabel: | ||
label: needs-area | ||
- description: Remove `needs-area` label when an area label is added | ||
if: | ||
- payloadType: Issues | ||
- hasLabel: | ||
label: needs-area | ||
- isOpen | ||
- or: | ||
- labelAdded: | ||
label: compiler:core | ||
- labelAdded: | ||
label: compiler:emitter-framework | ||
- labelAdded: | ||
label: ide | ||
- labelAdded: | ||
label: lib:http | ||
- labelAdded: | ||
label: lib:openapi | ||
- labelAdded: | ||
label: lib:rest | ||
- labelAdded: | ||
label: lib:versioning | ||
- labelAdded: | ||
label: meta:blog | ||
- labelAdded: | ||
label: meta:website | ||
- labelAdded: | ||
label: tspd | ||
- labelAdded: | ||
label: emitter:client:csharp | ||
- labelAdded: | ||
label: emitter:json-schema | ||
- labelAdded: | ||
label: emitter:protobuf | ||
- labelAdded: | ||
label: emitter:service:csharp | ||
- labelAdded: | ||
label: emitter:service:js | ||
- labelAdded: | ||
label: eng | ||
then: | ||
- removeLabel: | ||
label: needs-area | ||
- description: Add `needs-area` back when all area labels are removed | ||
if: | ||
- payloadType: Issues | ||
- not: | ||
hasLabel: | ||
label: needs-area | ||
- isOpen | ||
- or: | ||
- labelRemoved: | ||
label: compiler:core | ||
- labelRemoved: | ||
label: compiler:emitter-framework | ||
- labelRemoved: | ||
label: ide | ||
- labelRemoved: | ||
label: lib:http | ||
- labelRemoved: | ||
label: lib:openapi | ||
- labelRemoved: | ||
label: lib:rest | ||
- labelRemoved: | ||
label: lib:versioning | ||
- labelRemoved: | ||
label: meta:blog | ||
- labelRemoved: | ||
label: meta:website | ||
- labelRemoved: | ||
label: tspd | ||
- labelRemoved: | ||
label: emitter:client:csharp | ||
- labelRemoved: | ||
label: emitter:json-schema | ||
- labelRemoved: | ||
label: emitter:protobuf | ||
- labelRemoved: | ||
label: emitter:service:csharp | ||
- labelRemoved: | ||
label: emitter:service:js | ||
- labelRemoved: | ||
label: eng | ||
- not: | ||
or: | ||
- hasLabel: | ||
label: compiler:core | ||
- hasLabel: | ||
label: compiler:emitter-framework | ||
- hasLabel: | ||
label: ide | ||
- hasLabel: | ||
label: lib:http | ||
- hasLabel: | ||
label: lib:openapi | ||
- hasLabel: | ||
label: lib:rest | ||
- hasLabel: | ||
label: lib:versioning | ||
- hasLabel: | ||
label: meta:blog | ||
- hasLabel: | ||
label: meta:website | ||
- hasLabel: | ||
label: tspd | ||
- hasLabel: | ||
label: emitter:client:csharp | ||
- hasLabel: | ||
label: emitter:json-schema | ||
- hasLabel: | ||
label: emitter:protobuf | ||
- hasLabel: | ||
label: emitter:service:csharp | ||
- hasLabel: | ||
label: emitter:service:js | ||
- hasLabel: | ||
label: eng | ||
then: | ||
- removeLabel: | ||
label: needs-area |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,125 @@ | ||
# This file is generated by the sync-labels script DO NOT EDIT manually | ||
id: prs.triage | ||
name: Assign area labels to PRs | ||
description: Assign area labels to PR depending on path modified. | ||
resource: repository | ||
disabled: false | ||
configuration: | ||
resourceManagementConfiguration: | ||
eventResponderTasks: | ||
- description: Assign area labels to PRs based on modified files | ||
if: | ||
- payloadType: Pull_Request | ||
- isOpen | ||
then: | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/compiler | ||
then: | ||
- addLabel: | ||
label: compiler:core | ||
- if: | ||
- includesModifiedFiles: | ||
files: [] | ||
then: | ||
- addLabel: | ||
label: compiler:emitter-framework | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/typespec-vscode | ||
- packages/typespec-vs | ||
then: | ||
- addLabel: | ||
label: ide | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/http | ||
then: | ||
- addLabel: | ||
label: lib:http | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/openapi | ||
then: | ||
- addLabel: | ||
label: lib:openapi | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/rest | ||
then: | ||
- addLabel: | ||
label: lib:rest | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/versioning | ||
then: | ||
- addLabel: | ||
label: lib:versioning | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- blog | ||
then: | ||
- addLabel: | ||
label: meta:blog | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- website | ||
then: | ||
- addLabel: | ||
label: meta:website | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/tspd | ||
then: | ||
- addLabel: | ||
label: tspd | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/http-client-csharp | ||
then: | ||
- addLabel: | ||
label: emitter:client:csharp | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/json-schema | ||
then: | ||
- addLabel: | ||
label: emitter:json-schema | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- packages/protobuf | ||
then: | ||
- addLabel: | ||
label: emitter:protobuf | ||
- if: | ||
- includesModifiedFiles: | ||
files: [] | ||
then: | ||
- addLabel: | ||
label: emitter:service:csharp | ||
- if: | ||
- includesModifiedFiles: | ||
files: [] | ||
then: | ||
- addLabel: | ||
label: emitter:service:js | ||
- if: | ||
- includesModifiedFiles: | ||
files: | ||
- eng | ||
- .github | ||
then: | ||
- addLabel: | ||
label: eng |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.