Jap/simple forms/s3 spike #2169
Workflow file for this run
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
name: Label Pull Request Reviewers | |
on: | |
pull_request: | |
types: [opened, reopened, review_requested, synchronize, ready_for_review, unlabeled] | |
jobs: | |
label-pr-codeowners: | |
permissions: write-all | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Require require-backend-approval label | |
if: github.event.action == 'unlabeled' && github.event.label.name == 'require-backend-approval' | |
uses: actions-ecosystem/action-add-labels@v1 | |
with: | |
number: ${{ github.event.pull_request.number }} | |
labels: | | |
require-backend-approval | |
- name: Require omit-backend-approval label | |
if: github.event.action == 'unlabeled' && github.event.label.name == 'omit-backend-approval' | |
uses: actions-ecosystem/action-add-labels@v1 | |
with: | |
number: ${{ github.event.pull_request.number }} | |
labels: | | |
omit-backend-approval | |
- name: Add omit-backend-approval label | |
if: | | |
!contains(github.event.pull_request.labels.*.name, 'require-backend-approval') && | |
!contains(github.event.pull_request.labels.*.name, 'omit-backend-approval') && | |
( | |
contains(toJSON(github.event.pull_request.requested_teams.*.name), 'mobile') || | |
contains(toJSON(github.event.pull_request.requested_teams.*.name), 'lighthouse') || | |
contains(toJSON(github.event.pull_request.requested_teams.*.name), 'identity') | |
) | |
uses: actions-ecosystem/action-add-labels@v1 | |
with: | |
number: ${{ github.event.pull_request.number }} | |
labels: | | |
omit-backend-approval | |
- name: Add require-backend-approval label | |
uses: actions-ecosystem/action-add-labels@v1 | |
if: | | |
!contains(github.event.pull_request.labels.*.name, 'require-backend-approval') && | |
!contains(github.event.pull_request.labels.*.name, 'omit-backend-approval') && | |
!contains(toJSON(github.event.pull_request.requested_teams.*.name), 'mobile') && | |
!contains(toJSON(github.event.pull_request.requested_teams.*.name), 'lighthouse') && | |
!contains(toJSON(github.event.pull_request.requested_teams.*.name), 'identity') | |
with: | |
number: ${{ github.event.pull_request.number }} | |
labels: | | |
require-backend-approval |