From 20ab45b0b72bc31253dedc4e11774c043a489593 Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Fri, 16 May 2025 20:41:06 +0000 Subject: [PATCH 1/2] ci(workflow): add auto-merge notification workflow Co-Authored-By: Aaron Steers --- .github/workflows/auto_merge_notification.yml | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/auto_merge_notification.yml diff --git a/.github/workflows/auto_merge_notification.yml b/.github/workflows/auto_merge_notification.yml new file mode 100644 index 000000000..239d86552 --- /dev/null +++ b/.github/workflows/auto_merge_notification.yml @@ -0,0 +1,31 @@ +# When a PR is has the auto-merge feature enabled or disabled, this workflow adds or removes +# warning text at the bottom of the PR description. + +name: "Add Auto-Merge Notification Text" +on: + pull_request: + types: [auto_merge_enabled, auto_merge_disabled] + +jobs: + update-description: + runs-on: ubuntu-latest + permissions: + pull-requests: write + steps: + - name: Add Auto-Merge Notice + if: github.event.action == 'auto_merge_enabled' + uses: bcgov/action-pr-description-add@v2.0.0 + with: + add_markdown: | + > [!IMPORTANT] + > **Auto-merge enabled.** + > + > _This PR is set to merge automatically when all requirements are met._ + + - name: Remove Auto-Merge Notice + if: github.event.action == 'auto_merge_disabled' + uses: bcgov/action-pr-description-add@v2.0.0 + with: + add_markdown: | + > [!NOTE] + > **Auto-merge may have been disabled. Please check the PR status to confirm.** From 0990091ed651f5792c3df424f26ca88861774f3d Mon Sep 17 00:00:00 2001 From: "Aaron (\"AJ\") Steers" Date: Fri, 16 May 2025 13:45:33 -0700 Subject: [PATCH 2/2] Apply suggestions from code review --- .github/workflows/auto_merge_notification.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/auto_merge_notification.yml b/.github/workflows/auto_merge_notification.yml index 239d86552..540310953 100644 --- a/.github/workflows/auto_merge_notification.yml +++ b/.github/workflows/auto_merge_notification.yml @@ -1,4 +1,4 @@ -# When a PR is has the auto-merge feature enabled or disabled, this workflow adds or removes +# When a PR is has the auto-merge feature enabled or disabled, this workflow adds or updates # warning text at the bottom of the PR description. name: "Add Auto-Merge Notification Text"