From 3efe374ff68da50a0a4b338c0123d0c459820e35 Mon Sep 17 00:00:00 2001 From: Aaron Pham Date: Mon, 27 Jan 2025 10:13:21 -0500 Subject: [PATCH] chore(ci): update auto-merge dependabot Signed-off-by: Aaron Pham --- .github/workflows/dependabot-auto-merge.yml | 23 +++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .github/workflows/dependabot-auto-merge.yml diff --git a/.github/workflows/dependabot-auto-merge.yml b/.github/workflows/dependabot-auto-merge.yml new file mode 100644 index 000000000..3df89558d --- /dev/null +++ b/.github/workflows/dependabot-auto-merge.yml @@ -0,0 +1,23 @@ +name: dependabot-auto-merge +on: pull_request + +permissions: + contents: write + pull-requests: write + +jobs: + dependabot: + runs-on: ubuntu-latest + if: github.event.pull_request.user.login == 'dependabot[bot]' && github.repository == 'bentoml/OpenLLM' + steps: + - name: Dependabot metadata + id: metadata + uses: dependabot/fetch-metadata@v2.3.0 + with: + github-token: "${{ secrets.GITHUB_TOKEN }}" + - name: Enable auto-merge for Dependabot PRs + if: steps.dependabot-metadata.outputs.dependency-group == 'actions-dependencies' || steps.dependabot-metadata.outputs.dependency-group == 'production-dependencies' + run: gh pr merge --auto --squash "$PR_URL" + env: + PR_URL: ${{github.event.pull_request.html_url}} + GH_TOKEN: ${{secrets.GITHUB_TOKEN}}