add an action to auto-label PRs (#67)
* add an action to auto-label PRs
* add comment to config file
* updates
diff --git a/.github/labeler.yml b/.github/labeler.yml
new file mode 100644
index 0000000..a25c66b
--- /dev/null
+++ b/.github/labeler.yml
@@ -0,0 +1,16 @@
+# This configures the .github/workflows/pull_request_label.yml workflow.
+
+'infra':
+ - '.github/**'
+
+'package:blast_repo':
+ - pkgs/blast_repo/**/*
+
+'package:corpus':
+ - pkgs/corpus/**/*
+
+'package:dart_flutter_team_lints':
+ - pkgs/dart_flutter_team_lints/**/*
+
+'package:firehose':
+ - pkgs/firehose/**/*
diff --git a/.github/workflows/pull_request_label.yml b/.github/workflows/pull_request_label.yml
new file mode 100644
index 0000000..26758a5
--- /dev/null
+++ b/.github/workflows/pull_request_label.yml
@@ -0,0 +1,22 @@
+# This workflow applies labels to pull requests based on the paths that are
+# modified in the pull request.
+#
+# Edit `.github/labeler.yml` to configure labels. For more information, see
+# https://github.com/actions/labeler.
+
+name: Pull Request Labeler
+permissions: read-all
+
+on:
+ pull_request_target
+
+jobs:
+ label:
+ permissions:
+ pull-requests: write
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/labeler@5c7539237e04b714afd8ad9b4aed733815b9fab4
+ with:
+ repo-token: "${{ secrets.GITHUB_TOKEN }}"
+ sync-labels: true