From 57113d31e3ba3fcec421e85fd5efda971783ab4a Mon Sep 17 00:00:00 2001 From: Thiago Brezinski Date: Sat, 5 Sep 2026 18:40:18 +0100 Subject: [PATCH] ci: trim the fast lane to PR-only and align the main ruleset (#73) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fast workflows stop running on push to main and in merge groups; the ruleset's strict up-to-date policy makes those runs redundant. - ci.yml: drop the push/merge_group triggers, delete the build-library job (strict subset of test), drop --coverage (collected twice, enforced nowhere), and add the Pods cache step in build-ios so the existing cocoapods-cache condition is live. With pull_request the only event left, drop the event name from the concurrency group. - docs.yml: drop the push/merge_group triggers and the separate typecheck step — per ADR 0006, typecheck's one owning workflow is ci.yml's lint job and the docs gate is the documentation build alone. - performance.yml: drop the merge_group trigger and the display names on geometry/render-regressions so their check contexts match the ruleset entries by job id. - docs/releasing.md: required checks become lint, test, build-android, build-ios, docs build, geometry, render-regressions, and Changeset requirement. The matching ruleset edit is applied via gh api immediately before this merges, per ADR 0006. Co-Authored-By: Claude Fable 5 --- .github/workflows/ci.yml | 35 +++++++++++-------------------- .github/workflows/docs.yml | 7 ------- .github/workflows/performance.yml | 4 ---- docs/releasing.md | 4 ++-- 4 files changed, 14 insertions(+), 36 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f964656..2081fad 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,19 +1,11 @@ name: CI on: - push: - branches: - - main pull_request: branches: - main - merge_group: - types: - - checks_requested concurrency: - # Keep the event name in the group: sharing one group across events once let - # a release-authorizing push run deadlock behind other events for 13 hours. - group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true jobs: @@ -47,24 +39,11 @@ jobs: run: yarn prepare - name: Run unit tests - run: yarn test --maxWorkers=2 --coverage + run: yarn test --maxWorkers=2 - name: Run release-policy tests run: yarn test:release - build-library: - runs-on: ubuntu-latest - - steps: - - name: Checkout - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 - - - name: Setup - uses: ./.github/actions/setup - - - name: Build package - run: yarn prepare - build-android: runs-on: ubuntu-latest @@ -162,6 +141,16 @@ jobs: with: xcode-version: ${{ env.XCODE_VERSION }} + - name: Cache cocoapods + if: env.turbo_cache_hit != 1 + id: cocoapods-cache + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3 + with: + path: example/ios/Pods + key: ${{ runner.os }}-cocoapods-${{ hashFiles('example/ios/Podfile.lock') }} + restore-keys: | + ${{ runner.os }}-cocoapods- + - name: Install cocoapods if: env.turbo_cache_hit != 1 && steps.cocoapods-cache.outputs.cache-hit != 'true' run: | diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index a6abfd0..2c6757f 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,12 +1,8 @@ name: Documentation on: - push: - branches: [main] pull_request: branches: [main] - merge_group: - types: [checks_requested] workflow_dispatch: permissions: @@ -28,8 +24,5 @@ jobs: - name: Setup uses: ./.github/actions/setup - - name: Typecheck guides and examples - run: yarn typecheck - - name: Build canonical documentation run: yarn docs:build diff --git a/.github/workflows/performance.yml b/.github/workflows/performance.yml index 675edcb..1f03345 100644 --- a/.github/workflows/performance.yml +++ b/.github/workflows/performance.yml @@ -3,8 +3,6 @@ name: Performance publication gates on: pull_request: branches: [main] - merge_group: - types: [checks_requested] workflow_dispatch: concurrency: @@ -13,7 +11,6 @@ concurrency: jobs: geometry: - name: Production geometry budgets runs-on: ubuntu-latest steps: - name: Checkout @@ -26,7 +23,6 @@ jobs: run: yarn benchmark:issue40 render-regressions: - name: Reassure children, list, and section-list paths runs-on: ubuntu-latest steps: - name: Checkout candidate with baseline history diff --git a/docs/releasing.md b/docs/releasing.md index 6bce818..bcaff13 100644 --- a/docs/releasing.md +++ b/docs/releasing.md @@ -24,9 +24,9 @@ GitHub only offers status checks that have run recently. Let the workflows run o 5. Under **Target branches**, select **Add target**, choose **Include default branch**, and confirm that it resolves to `main`. 6. Under **Branch rules**, enable **Require a pull request before merging**. 7. Enable **Require status checks to pass**. Use **Add checks** to require: - - The five `CI` jobs: `lint`, `test`, `build-library`, `build-android`, and `build-ios`. + - The four `CI` jobs: `lint`, `test`, `build-android`, and `build-ios`. - The `Documentation` workflow's `build` job. Select the entry whose source is GitHub Actions and whose workflow is `Documentation` if GitHub shows multiple `build` checks. - - `Approve exact tarball for publication workflow` from `Exact package candidate`. This final job depends on every required package, performance, consumer, and device-contract job in that workflow. + - The two `Performance publication gates` jobs: `geometry` and `render-regressions`. - `Changeset requirement`, the commit-specific check created by the release-intent workflow. 8. Enable **Require branches to be up to date before merging** so checks from an older head commit cannot authorize a merge. 9. Leave bypass permissions empty unless the repository has a separately documented emergency policy, then select **Create**.