From c0491cfdd5cf2f10b843dd7881bf0789bc525863 Mon Sep 17 00:00:00 2001 From: JP-Ellis Date: Thu, 9 Jan 2025 11:28:07 +1100 Subject: [PATCH] chore(ci): prevent duplicate ci triggers Triggering on all 'push' and 'pull_request' events will result in duplicated CI runs in PRs (due to both conditions being met). Instead, trigger only on pushes to `master`, or updates to PRs targetting `master`. Signed-off-by: JP-Ellis --- .github/workflows/test.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 630f5fa..ca159a3 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,6 +1,12 @@ name: Test -on: [push, pull_request] +on: + push: + branches: + - master + pull_request: + branches: + - master jobs: test: @@ -19,4 +25,4 @@ jobs: with: ruby-version: ${{ matrix.ruby_version }} - run: "bundle install" - - run: "bundle exec rake" \ No newline at end of file + - run: "bundle exec rake"