From d63ba440ba38469610f6e259a78d7f84a5149751 Mon Sep 17 00:00:00 2001 From: Michael Yankelev Date: Tue, 24 Feb 2026 02:21:54 +0100 Subject: [PATCH 1/2] ci: skip expensive jobs on docs/planning-only PRs Add dorny/paths-filter to detect changed paths and conditionally skip heavy CI jobs (tests, builds, desktop builds) when only docs/planning files change. Lint and typecheck always run. Push to main always runs all jobs. Co-Authored-By: Claude Opus 4.6 --- .github/workflows/ci.yml | 62 +++++++++++++++++++++++++++++++++++---- .github/workflows/e2e.yml | 28 ++++++++++++++++++ 2 files changed, 84 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 12075cd184..e5a92fd11d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,6 +7,35 @@ on: branches: [main] jobs: + changes: + name: Detect Changes + runs-on: ubuntu-latest + permissions: + pull-requests: read + outputs: + src: ${{ steps.filter.outputs.src }} + desktop: ${{ steps.filter.outputs.desktop }} + steps: + - uses: actions/checkout@v4 + - uses: dorny/paths-filter@v3 + id: filter + with: + filters: | + src: + - '**' + - '!.planning/**' + - '!.learnings/**' + - '!docs/**' + - '!designs/**' + - '!00-Preliminary-R&D/**' + - '!.claude/**' + - '!**/*.md' + - '!LICENSE' + desktop: + - 'apps/desktop/**' + - 'packages/crypto/**' + - '.github/workflows/ci.yml' + lint: name: Lint runs-on: ubuntu-latest @@ -51,6 +80,9 @@ jobs: api-spec: name: Verify API Spec & Client + needs: [changes] + if: | + github.event_name == 'push' || needs.changes.outputs.src == 'true' runs-on: ubuntu-latest services: postgres: @@ -117,7 +149,10 @@ jobs: test: name: Test - needs: [lint, typecheck] + needs: [changes, lint, typecheck] + if: | + !failure() && !cancelled() && + (github.event_name == 'push' || needs.changes.outputs.src == 'true') runs-on: ubuntu-latest services: postgres: @@ -185,7 +220,10 @@ jobs: build: name: Build - needs: [lint, typecheck, api-spec, test] + needs: [changes, lint, typecheck, api-spec, test] + if: | + !failure() && !cancelled() && + (github.event_name == 'push' || needs.changes.outputs.src == 'true') runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -207,7 +245,10 @@ jobs: cargo-check-windows: name: Cargo Check (Windows) - needs: [lint] + needs: [changes, lint] + if: | + !failure() && !cancelled() && + (github.event_name == 'push' || needs.changes.outputs.desktop == 'true') runs-on: windows-latest steps: - uses: actions/checkout@v4 @@ -244,7 +285,10 @@ jobs: cargo-check-macos: name: Cargo Check (macOS) - needs: [lint] + needs: [changes, lint] + if: | + !failure() && !cancelled() && + (github.event_name == 'push' || needs.changes.outputs.desktop == 'true') runs-on: macos-latest steps: - uses: actions/checkout@v4 @@ -270,7 +314,10 @@ jobs: build-desktop-windows: name: Build Windows Desktop - needs: [cargo-check-windows, typecheck] + needs: [changes, cargo-check-windows, typecheck] + if: | + !failure() && !cancelled() && + (github.event_name == 'push' || needs.changes.outputs.desktop == 'true') runs-on: windows-latest steps: - uses: actions/checkout@v4 @@ -323,7 +370,10 @@ jobs: build-desktop-macos: name: Build macOS Desktop - needs: [cargo-check-macos, typecheck] + needs: [changes, cargo-check-macos, typecheck] + if: | + !failure() && !cancelled() && + (github.event_name == 'push' || needs.changes.outputs.desktop == 'true') runs-on: macos-latest steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 3dfb3db2ba..3b927faee9 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -8,8 +8,36 @@ on: workflow_dispatch: jobs: + changes: + name: Detect Changes + runs-on: ubuntu-latest + permissions: + pull-requests: read + outputs: + src: ${{ steps.filter.outputs.src }} + steps: + - uses: actions/checkout@v4 + - uses: dorny/paths-filter@v3 + id: filter + with: + filters: | + src: + - '**' + - '!.planning/**' + - '!.learnings/**' + - '!docs/**' + - '!designs/**' + - '!00-Preliminary-R&D/**' + - '!.claude/**' + - '!**/*.md' + - '!LICENSE' + e2e: name: E2E Tests + needs: [changes] + if: | + github.event_name == 'push' || github.event_name == 'workflow_dispatch' || + needs.changes.outputs.src == 'true' runs-on: ubuntu-latest timeout-minutes: 15 From 3f123a7d375cdef035b628e97f160db5cec31140 Mon Sep 17 00:00:00 2001 From: Michael Yankelev Date: Tue, 24 Feb 2026 02:30:00 +0100 Subject: [PATCH 2/2] ci: re-trigger CI after allowing dorny/paths-filter action Co-Authored-By: Claude Opus 4.6 Entire-Checkpoint: b28daa873b9e