Skip to content

Commit 17cf714

Browse files
committed
Bug 2003628 - Support Github pull requests in Enterprise Firefox
1 parent 4216e3e commit 17cf714

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

.taskcluster.yml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ tasks:
340340
then:
341341
matrixBody: "${repository.project} push notification: https://treeherder.mozilla.org/#/jobs?repo=${repository.project}&revision=${push.revision}"
342342
# Decision task for events originating from Github
343-
- $if: 'tasks_for in ["github-push"]'
343+
- $if: 'tasks_for in ["github-push", "github-pull-request"]'
344344
then:
345345
$let:
346346
$merge:
@@ -355,6 +355,14 @@ tasks:
355355
ref: '${event.ref}'
356356
baseRev: '${event.before}'
357357
headRev: '${event.after}'
358+
'tasks_for[:19] == "github-pull-request"':
359+
ownerEmail: '${event.pull_request.user.login}@users.noreply.github.com'
360+
baseRepoUrl: '${event.pull_request.base.repo.html_url}'
361+
repoUrl: '${event.pull_request.head.repo.html_url}'
362+
project: '${event.pull_request.base.repo.name}'
363+
ref: '${event.pull_request.head.ref}'
364+
baseRev: '${event.pull_request.base.sha}'
365+
headRev: '${event.pull_request.head.sha}'
358366
in:
359367
$let:
360368
shortRef:
@@ -363,7 +371,8 @@ tasks:
363371
else: ${ref}
364372
in:
365373
$if: >
366-
tasks_for == "github-push" && shortRef in ["enterprise-main", "enterprise-try"]
374+
tasks_for == "github-push" && shortRef == "enterprise-main"
375+
|| (isPullRequest && pullRequestAction in ["opened", "reopened", "synchronize"])
367376
then:
368377
$let:
369378
level:

0 commit comments

Comments
 (0)