From c519dc5738e36189348b9c86c196bf078194ddef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francesco=20Borz=C3=AC?= Date: Wed, 10 Nov 2021 16:31:42 +0100 Subject: [PATCH] fix(CI): re-run builds if label is present (#9114) --- .github/workflows/core_matrix_build.yml | 4 ++-- .github/workflows/core_modules_build.yml | 4 ++-- .github/workflows/cpp20.yml | 2 +- .github/workflows/docker_build.yml | 4 ++-- .github/workflows/macos_build.yml | 4 ++-- .github/workflows/windows_build.yml | 4 ++-- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/core_matrix_build.yml b/.github/workflows/core_matrix_build.yml index 8ce384aa6..00b3c770d 100644 --- a/.github/workflows/core_matrix_build.yml +++ b/.github/workflows/core_matrix_build.yml @@ -4,7 +4,7 @@ on: branches: - 'master' pull_request: - types: ['labeled'] + types: ['labeled', 'labeled', 'opened', 'synchronize', 'reopened'] concurrency: group: ${{ github.head_ref }} || concat(${{ github.ref }}, ${{ github.workflow }}) @@ -33,7 +33,7 @@ jobs: name: ${{ matrix.os }}-${{ matrix.compiler }} env: COMPILER: ${{ matrix.compiler }} - if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.event.label.name == 'run-build' || github.event.label.name == 'file-cpp' || github.ref == 'refs/heads/master') + if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.ref == 'refs/heads/master' || contains(github.event.pull_request.labels.*.name, 'file-cpp') || github.event.label.name == 'file-cpp' || contains(github.event.pull_request.labels.*.name, 'run-build') || github.event.label.name == 'run-build') steps: - uses: actions/checkout@v2 - name: Cache diff --git a/.github/workflows/core_modules_build.yml b/.github/workflows/core_modules_build.yml index 61413c8df..da71c68d3 100644 --- a/.github/workflows/core_modules_build.yml +++ b/.github/workflows/core_modules_build.yml @@ -4,7 +4,7 @@ on: branches: - 'master' pull_request: - types: ['labeled'] + types: ['labeled', 'labeled', 'opened', 'synchronize', 'reopened'] concurrency: group: ${{ github.head_ref }} || concat(${{ github.ref }}, ${{ github.workflow }}) @@ -23,7 +23,7 @@ jobs: name: ${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.modules }}-modules env: COMPILER: ${{ matrix.compiler }} - if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.event.label.name == 'file-cpp' || github.event.label.name == 'run-build' || github.ref == 'refs/heads/master') + if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.ref == 'refs/heads/master' || contains(github.event.pull_request.labels.*.name, 'file-cpp') || github.event.label.name == 'file-cpp' || contains(github.event.pull_request.labels.*.name, 'run-build') || github.event.label.name == 'run-build') steps: - uses: actions/checkout@v2 - name: Checkout modules diff --git a/.github/workflows/cpp20.yml b/.github/workflows/cpp20.yml index 597215fd5..3fcd885b7 100644 --- a/.github/workflows/cpp20.yml +++ b/.github/workflows/cpp20.yml @@ -17,7 +17,7 @@ jobs: env: COMPILER: clang ENABLE_CPP_20: 1 - if: github.repository == 'azerothcore/azerothcore-wotlk' && (contains(github.event.pull_request.labels.*.name, 'file-cpp') || github.event.label.name == 'file-cpp' || github.event.label.name == 'run-build' || github.ref == 'refs/heads/master') + if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.ref == 'refs/heads/master' || contains(github.event.pull_request.labels.*.name, 'file-cpp') || github.event.label.name == 'file-cpp' || contains(github.event.pull_request.labels.*.name, 'run-build') || github.event.label.name == 'run-build') steps: - uses: actions/checkout@v2 - name: Cache diff --git a/.github/workflows/docker_build.yml b/.github/workflows/docker_build.yml index 6b24116f8..6c56c39ff 100644 --- a/.github/workflows/docker_build.yml +++ b/.github/workflows/docker_build.yml @@ -4,7 +4,7 @@ on: branches: - 'master' pull_request: - types: ['labeled'] + types: ['labeled', 'labeled', 'opened', 'synchronize', 'reopened'] concurrency: group: ${{ github.head_ref }} || concat(${{ github.ref }}, ${{ github.workflow }}) @@ -17,7 +17,7 @@ jobs: matrix: os: [ubuntu-20.04] runs-on: ${{ matrix.os }} - if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.event.label.name == 'run-build' || github.ref == 'refs/heads/master') + if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.ref == 'refs/heads/master' || contains(github.event.pull_request.labels.*.name, 'file-cpp') || github.event.label.name == 'file-cpp' || contains(github.event.pull_request.labels.*.name, 'run-build') || github.event.label.name == 'run-build') env: COMPOSE_DOCKER_CLI_BUILD: 1 DOCKER_BUILDKIT: 1 diff --git a/.github/workflows/macos_build.yml b/.github/workflows/macos_build.yml index f3ea0cf6b..67ed13481 100644 --- a/.github/workflows/macos_build.yml +++ b/.github/workflows/macos_build.yml @@ -4,7 +4,7 @@ on: branches: - 'master' pull_request: - types: ['labeled'] + types: ['labeled', 'labeled', 'opened', 'synchronize', 'reopened'] concurrency: group: ${{ github.head_ref }} || concat(${{ github.ref }}, ${{ github.workflow }}) @@ -20,7 +20,7 @@ jobs: - macos-11 runs-on: ${{ matrix.os }} name: ${{ matrix.os }} - if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.event.label.name == 'run-build' || github.ref == 'refs/heads/master') + if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.ref == 'refs/heads/master' || contains(github.event.pull_request.labels.*.name, 'file-cpp') || github.event.label.name == 'file-cpp' || contains(github.event.pull_request.labels.*.name, 'run-build') || github.event.label.name == 'run-build') steps: - uses: actions/checkout@v2 - name: Cache diff --git a/.github/workflows/windows_build.yml b/.github/workflows/windows_build.yml index 937f76a5a..980894bea 100644 --- a/.github/workflows/windows_build.yml +++ b/.github/workflows/windows_build.yml @@ -4,7 +4,7 @@ on: branches: - 'master' pull_request: - types: ['labeled'] + types: ['labeled', 'labeled', 'opened', 'synchronize', 'reopened'] concurrency: group: ${{ github.head_ref }} || concat(${{ github.ref }}, ${{ github.workflow }}) @@ -20,7 +20,7 @@ jobs: name: ${{ matrix.os }}-MSVC16 env: BOOST_ROOT: C:\local\boost_1_74_0 - if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.event.label.name == 'run-build' || github.ref == 'refs/heads/master') + if: github.repository == 'azerothcore/azerothcore-wotlk' && (github.ref == 'refs/heads/master' || contains(github.event.pull_request.labels.*.name, 'file-cpp') || github.event.label.name == 'file-cpp' || contains(github.event.pull_request.labels.*.name, 'run-build') || github.event.label.name == 'run-build') steps: - uses: actions/checkout@v2 - name: Configure OS