From b3c36e264b2675a2d473470028ea24346e623192 Mon Sep 17 00:00:00 2001
From: Paul Abel
Date: Thu, 8 Aug 2024 13:43:44 +0100
Subject: [PATCH 1/2] add dependabot auto-merge workflow
---
.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 0000000..c73b0fd
--- /dev/null
+++ b/.github/workflows/dependabot-auto-merge.yml
@@ -0,0 +1,23 @@
+name: Dependabot auto-merge
+on: pull_request_target
+
+permissions:
+ contents: read
+
+jobs:
+ dependabot:
+ runs-on: ubuntu-22.04
+ if: ${{ github.event.pull_request.user.login == 'dependabot[bot]' }}
+ permissions:
+ pull-requests: write
+ contents: write
+ steps:
+ - name: Dependabot metadata
+ id: dependabot-metadata
+ uses: dependabot/fetch-metadata@dbb049abf0d677abbd7f7eee0375145b417fdd34 # v2.2.0
+
+ - name: Enable auto-merge for Dependabot PRs
+ run: gh pr merge --auto --squash "$PR_URL"
+ env:
+ PR_URL: ${{ github.event.pull_request.html_url }}
+ GITHUB_TOKEN: ${{ secrets.NGINX_PAT }}
From 87bb8a73dca85f5632d5113da992ccec3f08b2c5 Mon Sep 17 00:00:00 2001
From: Paul Abel
Date: Thu, 8 Aug 2024 13:44:01 +0100
Subject: [PATCH 2/2] update PR template to use main branch
---
.github/PULL_REQUEST_TEMPLATE.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
index c950838..8b97310 100644
--- a/.github/PULL_REQUEST_TEMPLATE.md
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -4,9 +4,9 @@ Describe the use case and detail of the change. If this PR addresses an issue on
### Checklist
Before creating a PR, run through this checklist and mark each as complete.
-- [ ] I have read the [CONTRIBUTING](https://github.com/nginxinc/nginx-ingress-operator/blob/master/CONTRIBUTING.md) doc
+- [ ] I have read the [CONTRIBUTING](https://github.com/nginxinc/nginx-ingress-operator/blob/main/CONTRIBUTING.md) doc
- [ ] I have added tests that prove my fix is effective or that my feature works
- [ ] I have checked that all unit tests pass after adding my changes
- [ ] I have updated necessary documentation
-- [ ] I have rebased my branch onto master
-- [ ] I will ensure my PR is targeting the master branch and pulling from my branch from my own fork
\ No newline at end of file
+- [ ] I have rebased my branch onto main
+- [ ] I will ensure my PR is targeting the main branch and pulling from my branch from my own fork
\ No newline at end of file