Skip to content

Commit 4ec1de4

Browse files
authored
GODRIVER-3139 Automatically Add Labels to PRs (#1569)
1 parent 9755f4a commit 4ec1de4

File tree

2 files changed

+28
-0
lines changed

2 files changed

+28
-0
lines changed

.evergreen/config.yml

+13
Original file line numberDiff line numberDiff line change
@@ -383,6 +383,18 @@ functions:
383383
export HEAD_SHA=${github_commit}
384384
bash etc/api_report.sh
385385
386+
"add PR labels":
387+
- command: shell.exec
388+
type: test
389+
params:
390+
shell: "bash"
391+
working_dir: src/go.mongodb.org/mongo-driver
392+
script: |
393+
${PREPARE_SHELL}
394+
CONFIG=$PROJECT_DIRECTORY/.github/labeler.yml
395+
SCRIPT="$DRIVERS_TOOLS/.evergreen/github_app/apply-labels.sh"
396+
bash $SCRIPT -l $CONFIG -h ${github_commit} -o "mongodb" -n "mongo-go-driver"
397+
386398
send-perf-data:
387399
- command: perf.send
388400
params:
@@ -867,6 +879,7 @@ tasks:
867879
vars:
868880
targets: "check-fmt check-license check-modules lint"
869881
- func: "create-api-report"
882+
- func: "add PR labels"
870883

871884
- name: perf
872885
tags: ["performance"]

.github/labeler.yml

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
2+
priority-3-low:
3+
- changed-files:
4+
- any-glob-to-any-file: '*'
5+
6+
documentation:
7+
- changed-files:
8+
- any-glob-to-any-file:
9+
- docs/**
10+
- examples/**
11+
12+
dependencies:
13+
- changed-files:
14+
- any-glob-to-any-file:
15+
- go.mod

0 commit comments

Comments
 (0)