stefanvodita commented on code in PR #14101:
URL: https://github.com/apache/lucene/pull/14101#discussion_r1934819611


##########
.github/workflows/label-pull-request.yml:
##########
@@ -0,0 +1,21 @@
+# This file defines the workflow for labeling pull requests with module tags 
based on the changed files in the PR.
+# It uses the `actions/labeler` GitHub Action to achieve the same.
+#
+# The workflow is triggered on the `pull_request_target` event which ensures 
workflow is only run from the master branch.
+# The job `labeler` runs on `ubuntu-latest` and has permissions to read 
contents and write pull requests.
+#
+# For more information on the `actions/labeler` GitHub Action, refer to 
https://github.com/actions/labeler
+
+name: "Pull Request Labeler"
+run-name: Labelling pull request with module tags based on changed files in 
the PR
+on:
+  - pull_request_target
+
+jobs:
+  labeler:

Review Comment:
   Can we add `sync-labels` to make it so labels get removed when they are no 
longer valid after an update to the PR?



##########
.github/labeler.yml:
##########
@@ -0,0 +1,134 @@
+# This file defines module label mappings for the Lucene project.
+# Each module is associated with a set of file globs that, when matched,
+# will trigger the corresponding label to be applied to pull requests.
+#
+# This configuration is used by the workflow defined in 
.github/workflows/label-pull-request.yml.
+# If we are adding new labels or refactoring modules, we will need to modify 
this file globs here to ensure that the correct labels are applied.
+
+# For more information on how to use the `actions/checkout` action, visit:

Review Comment:
   Is this relevant? I don't see us using `checkout` here.



##########
.github/labeler.yml:
##########
@@ -0,0 +1,134 @@
+# This file defines module label mappings for the Lucene project.
+# Each module is associated with a set of file globs that, when matched,
+# will trigger the corresponding label to be applied to pull requests.
+#
+# This configuration is used by the workflow defined in 
.github/workflows/label-pull-request.yml.
+# If we are adding new labels or refactoring modules, we will need to modify 
this file globs here to ensure that the correct labels are applied.
+
+# For more information on how to use the `actions/checkout` action, visit:
+# https://github.com/actions/checkout
+
+module:analysis:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/analysis/**'
+
+module:benchmark:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/benchmark/**'
+
+module:classification:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/classification/**'
+
+module:core/codecs:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/codecs/**', 
'lucene/core/src/test/org/apache/lucene/codecs/**']
+
+module:core/FSTs:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/util/fst/**', 
'lucene/core/src/test/org/apache/lucene/util/fst/**']
+
+module:core/hnsw:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/util/hnsw/**', 
'lucene/core/src/test/org/apache/lucene/util/hnsw/**']
+
+module:core/index:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/index/**', 
'lucene/core/src/test/org/apache/lucene/index/**']
+
+module:core/search:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/search/**', 
'lucene/core/src/test/org/apache/lucene/search/**']
+
+module:core/store:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/store/**', 
'lucene/core/src/test/org/apache/lucene/store/**']
+
+module:core/other:
+  - changed-files:
+      - any-glob-to-any-file: ['lucene/core/**']
+      - all-globs-to-all-files:
+            - '!lucene/core/src/java/org/apache/lucene/codecs/**'
+            - '!lucene/core/src/test/org/apache/lucene/codecs/**'
+            - '!lucene/core/src/java/org/apache/lucene/util/fst/**'
+            - '!lucene/core/src/test/org/apache/lucene/util/fst/**'
+            - '!lucene/core/src/java/org/apache/lucene/util/hnsw/**'
+            - '!lucene/core/src/test/org/apache/lucene/util/hnsw/**'
+            - '!lucene/core/src/java/org/apache/lucene/index/**'
+            - '!lucene/core/src/test/org/apache/lucene/index/**'
+            - '!lucene/core/src/java/org/apache/lucene/search/**'
+            - '!lucene/core/src/test/org/apache/lucene/search/**'
+            - '!lucene/core/src/java/org/apache/lucene/store/**'
+            - '!lucene/core/src/test/org/apache/lucene/store/**'
+
+module:demo:
+    - changed-files:
+        - any-glob-to-any-file: 'lucene/demo/**'
+
+module:expressions:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/expressions/**'
+
+module:facet:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/facet/**'
+
+module:grouping:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/grouping/**'
+
+module:highlighter:
+    - changed-files:
+        - any-glob-to-any-file: 'lucene/highlighter/**'
+
+module:join:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/join/**'
+
+module:luke:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/luke/**'
+
+module:misc:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/misc/**'
+
+module:monitor:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/monitor/**'
+
+module:queries:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/queries/**'
+
+module:queryparser:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/queryparser/**'
+
+module:replicator:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/replicator/**'
+
+module:sandbox:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/sandbox/**'
+
+module:spatial:
+    - changed-files:
+        - any-glob-to-any-file: ['lucene/spatial-extras/**', 
'lucene/spatial-test-fixtures/**']
+
+module:spatial3d:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/spatial3d/**'
+
+module:spatial-extras:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/spatial-extras/**'

Review Comment:
   Curious - why give this its own label and the `module:spatial` label as well?



##########
.github/labeler.yml:
##########
@@ -0,0 +1,134 @@
+# This file defines module label mappings for the Lucene project.
+# Each module is associated with a set of file globs that, when matched,
+# will trigger the corresponding label to be applied to pull requests.
+#
+# This configuration is used by the workflow defined in 
.github/workflows/label-pull-request.yml.
+# If we are adding new labels or refactoring modules, we will need to modify 
this file globs here to ensure that the correct labels are applied.
+
+# For more information on how to use the `actions/checkout` action, visit:
+# https://github.com/actions/checkout
+
+module:analysis:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/analysis/**'
+
+module:benchmark:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/benchmark/**'
+
+module:classification:
+  - changed-files:
+      - any-glob-to-any-file: 'lucene/classification/**'
+
+module:core/codecs:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/codecs/**', 
'lucene/core/src/test/org/apache/lucene/codecs/**']
+
+module:core/FSTs:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/util/fst/**', 
'lucene/core/src/test/org/apache/lucene/util/fst/**']
+
+module:core/hnsw:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/util/hnsw/**', 
'lucene/core/src/test/org/apache/lucene/util/hnsw/**']
+
+module:core/index:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/index/**', 
'lucene/core/src/test/org/apache/lucene/index/**']
+
+module:core/search:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/search/**', 
'lucene/core/src/test/org/apache/lucene/search/**']
+
+module:core/store:
+  - changed-files:
+      - any-glob-to-any-file: 
['lucene/core/src/java/org/apache/lucene/store/**', 
'lucene/core/src/test/org/apache/lucene/store/**']
+
+module:core/other:
+  - changed-files:
+      - any-glob-to-any-file: ['lucene/core/**']
+      - all-globs-to-all-files:

Review Comment:
   Cool!



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to