From 81de8135266d70cbbf88cf779d8a744d5db27325 Mon Sep 17 00:00:00 2001 From: Rello Date: Sun, 14 Jun 2026 13:42:01 +0200 Subject: [PATCH] fix(perf): do not run CI on draft PRs Signed-off-by: Rello --- .github/workflows/block-unconventional-commits.yml | 4 ++-- .github/workflows/check-translations.yml | 4 +++- .github/workflows/clang-format.yml | 3 ++- .github/workflows/clang-tidy-review.yml | 3 ++- .github/workflows/fixup.yml | 4 ++-- .github/workflows/linux-appimage.yml | 3 ++- .github/workflows/linux-clang-compile-tests.yml | 3 ++- .github/workflows/linux-gcc-compile-tests.yml | 3 ++- .github/workflows/macos-craft-ci.yml | 4 +++- .github/workflows/nextcloudfileproviderkit.yml | 3 +++ .github/workflows/qml-label-check.yml | 3 ++- .github/workflows/reuse.yml | 5 ++++- .github/workflows/sonarcloud.yml | 3 ++- .github/workflows/windows-build-and-test.yml | 3 ++- 14 files changed, 33 insertions(+), 15 deletions(-) diff --git a/.github/workflows/block-unconventional-commits.yml b/.github/workflows/block-unconventional-commits.yml index defae192f8a07..ec07e88dc15a9 100644 --- a/.github/workflows/block-unconventional-commits.yml +++ b/.github/workflows/block-unconventional-commits.yml @@ -10,7 +10,7 @@ name: Block unconventional commits on: pull_request: - types: [opened, ready_for_review, reopened, synchronize] + types: [opened, reopened, synchronize, ready_for_review] permissions: contents: read @@ -21,6 +21,7 @@ concurrency: jobs: block-unconventional-commits: + if: ${{ !github.event.pull_request.draft }} name: Block unconventional commits runs-on: ubuntu-latest-low @@ -34,4 +35,3 @@ jobs: - uses: webiny/action-conventional-commits@7f91b1595ca1951cdb671ddc9f07a49081ec5b69 # v1.4.2 with: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - diff --git a/.github/workflows/check-translations.yml b/.github/workflows/check-translations.yml index d43f9e86ca3e4..64005f49170f9 100644 --- a/.github/workflows/check-translations.yml +++ b/.github/workflows/check-translations.yml @@ -4,13 +4,14 @@ name: Check translations on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] # Declare default permissions as read only. permissions: read-all jobs: checkGermanTranslations: + if: ${{ !github.event.pull_request.draft }} runs-on: ubuntu-latest steps: @@ -20,6 +21,7 @@ jobs: [[ $(grep "Benötigt keine Übersetzung" translations/client_de.ts -c) -gt 0 ]] && exit 1 || exit 0 checkTranslations: + if: ${{ !github.event.pull_request.draft }} runs-on: ubuntu-latest container: ghcr.io/nextcloud/continuous-integration-translations-desktop:latest diff --git a/.github/workflows/clang-format.yml b/.github/workflows/clang-format.yml index 72fc14141dd7d..d0b0e22b5a41f 100644 --- a/.github/workflows/clang-format.yml +++ b/.github/workflows/clang-format.yml @@ -3,9 +3,10 @@ name: Clang Format Checker on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] jobs: build: + if: ${{ !github.event.pull_request.draft }} runs-on: ubuntu-22.04 steps: - uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3 diff --git a/.github/workflows/clang-tidy-review.yml b/.github/workflows/clang-tidy-review.yml index fd0425ffd4ad9..0774518ae5297 100644 --- a/.github/workflows/clang-tidy-review.yml +++ b/.github/workflows/clang-tidy-review.yml @@ -4,10 +4,11 @@ name: clang-tidy-review on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] jobs: clang-tidy: + if: ${{ !github.event.pull_request.draft }} runs-on: ubuntu-latest container: ghcr.io/nextcloud/continuous-integration-client-qt6:client-sid-6.10.2-2 steps: diff --git a/.github/workflows/fixup.yml b/.github/workflows/fixup.yml index 69da2bbb039f2..812eab4d6b4e8 100644 --- a/.github/workflows/fixup.yml +++ b/.github/workflows/fixup.yml @@ -10,7 +10,7 @@ name: Block fixup and squash commits on: pull_request: - types: [opened, ready_for_review, reopened, synchronize] + types: [opened, reopened, synchronize, ready_for_review] permissions: contents: read @@ -21,7 +21,7 @@ concurrency: jobs: commit-message-check: - if: github.event.pull_request.draft == false + if: ${{ !github.event.pull_request.draft }} permissions: pull-requests: write diff --git a/.github/workflows/linux-appimage.yml b/.github/workflows/linux-appimage.yml index f1062f92f8396..c0780f733391d 100644 --- a/.github/workflows/linux-appimage.yml +++ b/.github/workflows/linux-appimage.yml @@ -3,10 +3,11 @@ name: Linux Appimage Package on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] jobs: build: + if: ${{ !github.event.pull_request.draft }} name: Linux Appimage Package runs-on: ubuntu-latest container: ghcr.io/nextcloud/continuous-integration-client-appimage-qt6:client-appimage-el8-6.10.2-4 diff --git a/.github/workflows/linux-clang-compile-tests.yml b/.github/workflows/linux-clang-compile-tests.yml index 83aaca5ba4139..bf2fed8957647 100644 --- a/.github/workflows/linux-clang-compile-tests.yml +++ b/.github/workflows/linux-clang-compile-tests.yml @@ -3,9 +3,10 @@ name: Linux Clang compilation and tests on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] jobs: build: + if: ${{ !github.event.pull_request.draft }} name: Linux Clang compilation and tests runs-on: ubuntu-latest container: ghcr.io/nextcloud/continuous-integration-client-qt6:client-sid-6.10.2-2 diff --git a/.github/workflows/linux-gcc-compile-tests.yml b/.github/workflows/linux-gcc-compile-tests.yml index 73433a4ee47e4..1653072fed080 100644 --- a/.github/workflows/linux-gcc-compile-tests.yml +++ b/.github/workflows/linux-gcc-compile-tests.yml @@ -3,9 +3,10 @@ name: Linux GCC compilation and tests on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] jobs: build: + if: ${{ !github.event.pull_request.draft }} name: Linux GCC compilation and tests runs-on: ubuntu-latest container: ghcr.io/nextcloud/continuous-integration-client-qt6:client-sid-6.10.2-2 diff --git a/.github/workflows/macos-craft-ci.yml b/.github/workflows/macos-craft-ci.yml index 10a1182b379fa..cfa39b3eda995 100644 --- a/.github/workflows/macos-craft-ci.yml +++ b/.github/workflows/macos-craft-ci.yml @@ -5,10 +5,11 @@ name: macOS CI on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] jobs: setup_craft: + if: ${{ !github.event.pull_request.draft }} name: Set up Craft and install dependencies timeout-minutes: 60 runs-on: macos-15 @@ -91,6 +92,7 @@ jobs: build: + if: ${{ !github.event.pull_request.draft }} name: Build and test ${{ matrix.buildFileProviderModule == 'True' && 'File Provider' || 'classic' }} client needs: setup_craft strategy: diff --git a/.github/workflows/nextcloudfileproviderkit.yml b/.github/workflows/nextcloudfileproviderkit.yml index 3a408d76a9e5c..f123b7ce2a7f9 100644 --- a/.github/workflows/nextcloudfileproviderkit.yml +++ b/.github/workflows/nextcloudfileproviderkit.yml @@ -9,9 +9,11 @@ on: branches: [ "master" ] pull_request: branches: [ "master" ] + types: [opened, reopened, synchronize, ready_for_review] jobs: Lint: + if: ${{ github.event_name != 'pull_request' || !github.event.pull_request.draft }} runs-on: macos-26 defaults: @@ -25,6 +27,7 @@ jobs: run: swiftformat --lint . --reporter github-actions-log Tests: + if: ${{ github.event_name != 'pull_request' || !github.event.pull_request.draft }} runs-on: macos-26 defaults: diff --git a/.github/workflows/qml-label-check.yml b/.github/workflows/qml-label-check.yml index d73a7fd3ab045..b634903f10013 100644 --- a/.github/workflows/qml-label-check.yml +++ b/.github/workflows/qml-label-check.yml @@ -3,9 +3,10 @@ name: QML Label component check on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] jobs: build: + if: ${{ !github.event.pull_request.draft }} name: QML Label component check runs-on: ubuntu-latest steps: diff --git a/.github/workflows/reuse.yml b/.github/workflows/reuse.yml index a60e9e262a844..6275f4a28e37b 100644 --- a/.github/workflows/reuse.yml +++ b/.github/workflows/reuse.yml @@ -9,13 +9,16 @@ name: REUSE Compliance Check -on: [pull_request] +on: + pull_request: + types: [opened, reopened, synchronize, ready_for_review] permissions: contents: read jobs: reuse-compliance-check: + if: ${{ !github.event.pull_request.draft }} runs-on: ubuntu-latest-low steps: - name: Checkout diff --git a/.github/workflows/sonarcloud.yml b/.github/workflows/sonarcloud.yml index 9026911c45245..caf01129b00f4 100644 --- a/.github/workflows/sonarcloud.yml +++ b/.github/workflows/sonarcloud.yml @@ -3,9 +3,10 @@ name: SonarCloud analysis on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] jobs: build: + if: ${{ !github.event.pull_request.draft }} name: SonarCloud analysis runs-on: [ubuntu-latest, self-hosted] container: ghcr.io/nextcloud/continuous-integration-client-qt6:client-sid-6.10.2-2 diff --git a/.github/workflows/windows-build-and-test.yml b/.github/workflows/windows-build-and-test.yml index f0b08dca6f4cc..724d5ed9b4f30 100644 --- a/.github/workflows/windows-build-and-test.yml +++ b/.github/workflows/windows-build-and-test.yml @@ -3,9 +3,10 @@ name: Windows Build and Test on: pull_request: - types: [opened, synchronize, reopened] + types: [opened, reopened, synchronize, ready_for_review] jobs: build: + if: ${{ !github.event.pull_request.draft }} name: Windows Build and Test runs-on: windows-2022 env: