From 990d93bb3368a58d09da9b79e0d46952d7502dda Mon Sep 17 00:00:00 2001 From: Matthias Gehre Date: Thu, 4 Jul 2024 08:43:26 +0200 Subject: [PATCH 1/2] dependabot: Automatically update llvm submodules --- .github/dependabot.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 000000000000..3ab6783bdb61 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,15 @@ +# To get started with Dependabot version updates, you'll need to specify which +# package ecosystems to update and where the package manifests are located. +# Please see the documentation for all configuration options: +# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates + +version: 2 +updates: + - package-ecosystem: "gitsubmodule" + directory: "/" + allow: + - dependency-name: "externals/llvm-project" + schedule: + interval: "daily" + time: "06:00" + timezone: "Europe/Berlin" From 005241a58b1e6078e6e888e4fd35612c31ed0aa0 Mon Sep 17 00:00:00 2001 From: Matthias Gehre Date: Thu, 4 Jul 2024 08:49:46 +0200 Subject: [PATCH 2/2] Auto-approve & auto-merge dependabot PRs --- .github/workflows/approve_dependabot.yml | 26 ++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .github/workflows/approve_dependabot.yml diff --git a/.github/workflows/approve_dependabot.yml b/.github/workflows/approve_dependabot.yml new file mode 100644 index 000000000000..05d8b0f2e72d --- /dev/null +++ b/.github/workflows/approve_dependabot.yml @@ -0,0 +1,26 @@ +name: Dependabot auto-approve & auto-merge +on: pull_request + +permissions: + pull-requests: write + +jobs: + dependabot: + runs-on: ubuntu-latest + if: github.actor == 'dependabot[bot]' + steps: + - name: Dependabot metadata + id: metadata + uses: dependabot/fetch-metadata@v2 + with: + github-token: "${{ secrets.GITHUB_TOKEN }}" + - name: Approve a PR + run: gh pr review --approve "$PR_URL" + env: + PR_URL: ${{github.event.pull_request.html_url}} + GH_TOKEN: ${{secrets.GITHUB_TOKEN}} + - name: Enable auto-merge for Dependabot PRs + run: gh pr merge --auto --merge "$PR_URL" + env: + PR_URL: ${{github.event.pull_request.html_url}} + GH_TOKEN: ${{secrets.GITHUB_TOKEN}}