From f80889f27d8282e4678202c1a4eecdffefecfc2d Mon Sep 17 00:00:00 2001 From: Matthew Burket Date: Fri, 10 Jan 2025 13:40:00 -0600 Subject: [PATCH] Add workflow to ensure no merge commits are included --- .github/workflows/no_merge_commits.yaml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 .github/workflows/no_merge_commits.yaml diff --git a/.github/workflows/no_merge_commits.yaml b/.github/workflows/no_merge_commits.yaml new file mode 100644 index 00000000000..8f37744d927 --- /dev/null +++ b/.github/workflows/no_merge_commits.yaml @@ -0,0 +1,24 @@ +name: Merge Commit Check + +on: + pull_request: + +concurrency: + group: ${{ github.workflow }}-no-merges-${{ github.event.number || github.run_id }} + cancel-in-progress: true + +permissions: + contents: read + pull-requests: read + +jobs: + validate-merge-commits: + name: Ensure No Merge Commits + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 + - name: Check for Merge Commits + uses: NexusPHP/no-merge-commits@9754184b5234ed0c8ef57d63dc70f03f1f753cba # v2.1.0 + with: + token: ${{ secrets.GITHUB_TOKEN }}