Skip to content

Commit

Permalink
addition of the auto-approve bot PRs workflow (#105)
Browse files Browse the repository at this point in the history
  • Loading branch information
frouioui authored Oct 24, 2023
1 parent 0592de4 commit 6ee0081
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/auto_approve_pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Auto Approval of Bot Pull Requests
on:
pull_request:
types: [opened, reopened]

jobs:
auto_approve:
name: Approve Pull Request
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Approve Pull Request
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
if [[ "${{github.event.pull_request.user.login}}" == "bot-vitess[bot]" ]] && [[ "${{github.event.pull_request.draft}}" == "false" ]]; then
gh pr review ${{ github.event.pull_request.number }} --approve
fi

0 comments on commit 6ee0081

Please sign in to comment.