diff --git a/.github/workflows/mac-ci.yml b/.github/workflows/mac-ci.yml index 21cf3f2652f..93bf464d1fd 100644 --- a/.github/workflows/mac-ci.yml +++ b/.github/workflows/mac-ci.yml @@ -28,6 +28,11 @@ on: required: false type: boolean default: false + add-label: + description: 'Add a label to the PR' + required: false + type: boolean + default: false pull_request: types: @@ -55,3 +60,4 @@ jobs: ctest-args: ${{ inputs.ctest-args }} fastdds-branch: ${{ inputs.fastdds_branch || github.ref || 'master' }} use-ccache: ${{ ((inputs.use-ccache == true) && true) || false }} + add-label: ${{ (github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name == github.repository) && true || false }} diff --git a/.github/workflows/nightly-mac-ci.yml b/.github/workflows/nightly-mac-ci.yml index 74eaad24d64..dbd00595a8a 100644 --- a/.github/workflows/nightly-mac-ci.yml +++ b/.github/workflows/nightly-mac-ci.yml @@ -20,6 +20,7 @@ jobs: ctest-args: "-LE xfail" fastdds-branch: 'master' use-ccache: false + add-label: false nightly-mac-ci-2_14_x: strategy: @@ -35,6 +36,7 @@ jobs: ctest-args: "-LE xfail" fastdds-branch: '2.14.x' use-ccache: false + add-label: false nightly-mac-ci-2_10_x: strategy: @@ -50,4 +52,5 @@ jobs: ctest-args: "-LE xfail" fastdds-branch: '2.10.x' use-ccache: false + add-label: false diff --git a/.github/workflows/nightly-sanitizers-ci.yml b/.github/workflows/nightly-sanitizers-ci.yml index 8826ac0b91f..19bb04ac3e2 100644 --- a/.github/workflows/nightly-sanitizers-ci.yml +++ b/.github/workflows/nightly-sanitizers-ci.yml @@ -19,6 +19,7 @@ jobs: ctest_args: '' fastdds_ref: 'master' discovery_server_ref: 'master' + add-label: false nightly-sanitizers-ci-2_14_x: uses: eProsima/Fast-DDS/.github/workflows/reusable-sanitizers-ci.yml@2.14.x @@ -33,6 +34,7 @@ jobs: ctest_args: '' fastdds_ref: '2.14.x' discovery_server_ref: 'v1.2.2' + add-label: false nightly-sanitizers-ci-2_10_x: uses: eProsima/Fast-DDS/.github/workflows/reusable-sanitizers-ci.yml@2.10.x @@ -47,3 +49,4 @@ jobs: ctest_args: '' fastdds_ref: '2.10.x' discovery_server_ref: 'v1.2.1' + add-label: false diff --git a/.github/workflows/nightly-ubuntu-ci.yml b/.github/workflows/nightly-ubuntu-ci.yml index e5ae53df315..493ca1e0c03 100644 --- a/.github/workflows/nightly-ubuntu-ci.yml +++ b/.github/workflows/nightly-ubuntu-ci.yml @@ -25,6 +25,7 @@ jobs: run-build: true run-tests: true use-ccache: false + add-label: false nightly-ubuntu-ci-2_14_x: strategy: @@ -45,6 +46,7 @@ jobs: run-build: true run-tests: true use-ccache: false + add-label: false nightly-ubuntu-ci-2_10_x: strategy: @@ -65,4 +67,5 @@ jobs: run-build: true run-tests: true use-ccache: false + add-label: false diff --git a/.github/workflows/nightly-windows-ci.yml b/.github/workflows/nightly-windows-ci.yml index 956f0879885..f8cb8775fcb 100644 --- a/.github/workflows/nightly-windows-ci.yml +++ b/.github/workflows/nightly-windows-ci.yml @@ -19,6 +19,7 @@ jobs: cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" fastdds_branch: 'master' + add-label: false nightly-windows-ci-2_14_x: strategy: @@ -33,6 +34,7 @@ jobs: cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" fastdds_branch: '2.14.x' + add-label: false nightly-windows-ci-2_10_x: strategy: @@ -47,4 +49,5 @@ jobs: cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" fastdds_branch: '2.10.x' + add-label: false diff --git a/.github/workflows/reusable-mac-ci.yml b/.github/workflows/reusable-mac-ci.yml index 1dfebbd36fb..0d083ccf48d 100644 --- a/.github/workflows/reusable-mac-ci.yml +++ b/.github/workflows/reusable-mac-ci.yml @@ -28,6 +28,11 @@ on: required: false type: boolean default: false + add-label: + description: 'Add the CI-PENDING label to the PR' + required: false + type: boolean + default: true defaults: run: @@ -49,7 +54,7 @@ jobs: - 'RelWithDebInfo' steps: - name: Add ci-pending label if PR - if: ${{ github.event_name == 'pull_request' }} + if: ${{ github.event_name == 'pull_request' && inputs.add-label == true }} uses: eProsima/eProsima-CI/external/add_labels@v0 with: labels: ci-pending diff --git a/.github/workflows/reusable-sanitizers-ci.yml b/.github/workflows/reusable-sanitizers-ci.yml index 226795f7354..f27b94f6113 100644 --- a/.github/workflows/reusable-sanitizers-ci.yml +++ b/.github/workflows/reusable-sanitizers-ci.yml @@ -45,6 +45,11 @@ on: Required only if the Discovery Server job is requested required: false type: string + add-label: + description: 'Add the CI-PENDING label to the PR' + required: false + type: boolean + default: true defaults: run: @@ -56,7 +61,7 @@ jobs: runs-on: ubuntu-22.04 steps: - name: Add ci-pending label if PR - if: ${{ github.event_name == 'pull_request' }} + if: ${{ github.event_name == 'pull_request' && inputs.add-label == true }} uses: eProsima/eProsima-CI/external/add_labels@v0 with: labels: ci-pending @@ -343,7 +348,7 @@ jobs: CXX: g++-12 steps: - name: Add ci-pending label if PR - if: ${{ github.event_name == 'pull_request' }} + if: ${{ github.event_name == 'pull_request' && inputs.add-label == true }} uses: eProsima/eProsima-CI/external/add_labels@v0 with: labels: ci-pending diff --git a/.github/workflows/reusable-ubuntu-ci.yml b/.github/workflows/reusable-ubuntu-ci.yml index 1c44e356965..a69ec039ea6 100644 --- a/.github/workflows/reusable-ubuntu-ci.yml +++ b/.github/workflows/reusable-ubuntu-ci.yml @@ -52,6 +52,11 @@ on: required: false type: boolean default: false + add-label: + description: 'Add the CI-PENDING label to the PR' + required: false + type: boolean + default: true env: security-cmake-flag: ${{ inputs.security == true && '-DSECURITY=ON' || '-DSECURITY=OFF' }} @@ -71,7 +76,7 @@ jobs: - 'RelWithDebInfo' steps: - name: Add ci-pending label if PR - if: ${{ github.event_name == 'pull_request' }} + if: ${{ github.event_name == 'pull_request' && inputs.add-label == true }} uses: eProsima/eProsima-CI/external/add_labels@v0 with: labels: ci-pending diff --git a/.github/workflows/reusable-windows-ci.yml b/.github/workflows/reusable-windows-ci.yml index f7f9bfe0fe3..957349c7bf1 100644 --- a/.github/workflows/reusable-windows-ci.yml +++ b/.github/workflows/reusable-windows-ci.yml @@ -23,6 +23,11 @@ on: description: 'Branch or tag of Fast DDS repository (https://github.com/eProsima/Fast-DDS)' required: true type: string + add-label: + description: 'Add the CI-PENDING label to the PR' + required: false + type: boolean + default: true defaults: run: @@ -40,7 +45,7 @@ jobs: - 'v142' steps: - name: Add ci-pending label if PR - if: ${{ github.event_name == 'pull_request' }} + if: ${{ github.event_name == 'pull_request' && inputs.add-label == true }} uses: eProsima/eProsima-CI/external/add_labels@v0 with: labels: ci-pending diff --git a/.github/workflows/sanitizers-ci.yml b/.github/workflows/sanitizers-ci.yml index e4ec25ec298..5e464ad3203 100644 --- a/.github/workflows/sanitizers-ci.yml +++ b/.github/workflows/sanitizers-ci.yml @@ -43,6 +43,11 @@ on: Branch or tag of Discovery Server repository (https://github.com/eProsima/Discovery-Server) Required only if the Discovery Server job is requested required: false + add-label: + description: 'Add a label to the PR' + required: false + type: boolean + default: false pull_request: types: @@ -75,3 +80,4 @@ jobs: ctest_args: ${{ inputs.ctest_args || '' }} fastdds_ref: ${{ inputs.fastdds_ref || github.ref || 'master' }} discovery_server_ref: ${{ inputs.discovery_server_ref || 'master' }} + add-label: ${{ (github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name == github.repository) && true || false }} diff --git a/.github/workflows/ubuntu-ci.yml b/.github/workflows/ubuntu-ci.yml index a2601850577..c55eaeaa2b3 100644 --- a/.github/workflows/ubuntu-ci.yml +++ b/.github/workflows/ubuntu-ci.yml @@ -38,6 +38,11 @@ on: required: false type: boolean default: false + add-label: + description: 'Add a label to the PR' + required: false + type: boolean + default: false pull_request: types: @@ -69,3 +74,4 @@ jobs: run-build: ${{ !(github.event_name == 'pull_request') || !contains(github.event.pull_request.labels.*.name, 'skip-ci') }} run-tests: ${{ ((inputs.run-tests == true) && true) || (github.event_name == 'pull_request' && !contains(github.event.pull_request.labels.*.name, 'no-test')) }} use-ccache: ${{ ((inputs.use-ccache == true) && true) || false }} + add-label: ${{ (github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name == github.repository) && true || false }} diff --git a/.github/workflows/weekly-mac-ci.yml b/.github/workflows/weekly-mac-ci.yml index 3c244ee0669..b880754a20e 100644 --- a/.github/workflows/weekly-mac-ci.yml +++ b/.github/workflows/weekly-mac-ci.yml @@ -21,3 +21,4 @@ jobs: ctest-args: "-LE xfail" fastdds-branch: '2.6.x' use-ccache: false + add-label: false diff --git a/.github/workflows/weekly-sanitizers-ci.yml b/.github/workflows/weekly-sanitizers-ci.yml index b85ae85f31c..eb406c8c6ad 100644 --- a/.github/workflows/weekly-sanitizers-ci.yml +++ b/.github/workflows/weekly-sanitizers-ci.yml @@ -19,3 +19,4 @@ jobs: ctest_args: '' fastdds_ref: '2.6.x' discovery_server_ref: 'v1.2.1' + add-label: false diff --git a/.github/workflows/weekly-ubuntu-ci.yml b/.github/workflows/weekly-ubuntu-ci.yml index c742836d246..afdb1bbd2ba 100644 --- a/.github/workflows/weekly-ubuntu-ci.yml +++ b/.github/workflows/weekly-ubuntu-ci.yml @@ -28,6 +28,7 @@ jobs: run-build: true run-tests: true use-ccache: false + add-label: false weekly-ubuntu-ci-2_6_x: strategy: @@ -46,3 +47,4 @@ jobs: run-build: true run-tests: true use-ccache: false + add-label: false diff --git a/.github/workflows/weekly-windows-ci.yml b/.github/workflows/weekly-windows-ci.yml index ae0124533a5..c56b2f936a1 100644 --- a/.github/workflows/weekly-windows-ci.yml +++ b/.github/workflows/weekly-windows-ci.yml @@ -20,3 +20,4 @@ jobs: cmake-args: "-DSECURITY=${{ matrix.security }}" ctest-args: "-LE xfail" fastdds_branch: '2.6.x' + add-label: false diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index d33b39bb693..e690f5d007d 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -23,6 +23,11 @@ on: description: 'Branch or tag of Fast DDS repository (https://github.com/eProsima/Fast-DDS)' type: string required: true + add-label: + description: 'Add a label to the PR' + required: false + type: boolean + default: false pull_request: types: @@ -49,3 +54,4 @@ jobs: cmake-args: '-DSECURITY=ON ${{ inputs.cmake-args }}' ctest-args: ${{ inputs.ctest-args }} fastdds_branch: ${{ inputs.fastdds_branch || github.ref || 'master' }} + add-label: ${{ (github.event_name == 'pull_request') && (github.event.pull_request.head.repo.full_name == github.repository) && true || false }}