Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Auto-approve API docs sync PRs
name: Auto-approve generated docs sync PRs

on:
pull_request:
Expand All @@ -11,7 +11,7 @@ permissions:
pull-requests: write

jobs:
approve:
approve-api-docs-sync:
runs-on: ubuntu-latest
if: >-
github.event.pull_request.user.login == 'team-backend-foundations-bot'
Expand All @@ -26,3 +26,19 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PR_URL: ${{ github.event.pull_request.html_url }}
run: gh pr review --approve "$PR_URL"

approve-cli-docs-sync:
runs-on: ubuntu-latest
if: >-
github.event.pull_request.user.login == 'team-miscellaneous-branch-protections'
&& github.actor == 'team-miscellaneous-branch-protections'
&& github.event.pull_request.head.repo.full_name == github.repository
&& github.event.pull_request.head.ref == 'cli-docs-sync'
&& github.event.pull_request.base.ref == 'main'
&& contains(github.event.pull_request.labels.*.name, 'cli-docs-sync')
steps:
- name: Approve PR
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PR_URL: ${{ github.event.pull_request.html_url }}
run: gh pr review --approve "$PR_URL"