@@ -138,21 +138,17 @@ jobs:
138138 path : .turbo/runs
139139 retention-days : 5
140140
141- static-analysis :
141+ bundle-size :
142142 needs : [check-permissions, build-packages]
143- name : Static analysis
143+ name : Bundle size
144144 permissions :
145145 contents : read
146- actions : write # needed for actions/upload-artifact
147146 runs-on : " blacksmith-8vcpu-ubuntu-2204"
148147 defaults :
149148 run :
150149 shell : bash
151150 timeout-minutes : ${{ vars.TIMEOUT_MINUTES_NORMAL && fromJSON(vars.TIMEOUT_MINUTES_NORMAL) || 10 }}
152151
153- env :
154- TURBO_SUMMARIZE : false
155-
156152 steps :
157153 - name : Checkout Repo
158154 uses : actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
@@ -169,21 +165,57 @@ jobs:
169165 with :
170166 cache-enabled : true
171167 turbo-signature : ${{ secrets.TURBO_REMOTE_CACHE_SIGNATURE_KEY }}
172- turbo-summarize : ${{ env.TURBO_SUMMARIZE }}
173168 turbo-team : ${{ vars.TURBO_TEAM }}
174169 turbo-token : ${{ secrets.TURBO_TOKEN }}
175170
171+ # No continue-on-error: an over-budget chunk fails this job, which is the gate.
172+ # Enforcement rides on this job's exit code, not the `bundlewatch` commit status
173+ # (which collides across packages and can be masked by a sibling's pass).
176174 - name : Check size using bundlewatch
177- continue-on-error : true
178175 env :
179176 BUNDLEWATCH_GITHUB_TOKEN : ${{ secrets.BUNDLEWATCH_GITHUB_TOKEN }}
180- CI_BRANCH : ${{ github.ref }}
177+ CI_BRANCH : ${{ github.ref }}
181178 CI_BRANCH_BASE : refs/heads/main
182- CI_COMMIT_SHA : ${{ github.event.pull_request.head.sha }}
179+ CI_COMMIT_SHA : ${{ github.event_name == 'merge_group' && github.event.merge_group.head_sha || github. event.pull_request.head.sha }}
183180 CI_REPO_NAME : ${{ vars.REPO_NAME }}
184181 CI_REPO_OWNER : ${{ vars.REPO_OWNER }}
185182 run : pnpm turbo bundlewatch $TURBO_ARGS
186183
184+ static-analysis :
185+ needs : [check-permissions, build-packages]
186+ name : Static analysis
187+ permissions :
188+ contents : read
189+ actions : write # needed for actions/upload-artifact
190+ runs-on : " blacksmith-8vcpu-ubuntu-2204"
191+ defaults :
192+ run :
193+ shell : bash
194+ timeout-minutes : ${{ vars.TIMEOUT_MINUTES_NORMAL && fromJSON(vars.TIMEOUT_MINUTES_NORMAL) || 10 }}
195+
196+ env :
197+ TURBO_SUMMARIZE : false
198+
199+ steps :
200+ - name : Checkout Repo
201+ uses : actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
202+ with :
203+ persist-credentials : false
204+ fetch-depth : 1
205+ fetch-tags : false
206+ filter : " blob:none"
207+ show-progress : false
208+
209+ - name : Setup
210+ id : config
211+ uses : ./.github/actions/init-blacksmith
212+ with :
213+ cache-enabled : true
214+ turbo-signature : ${{ secrets.TURBO_REMOTE_CACHE_SIGNATURE_KEY }}
215+ turbo-summarize : ${{ env.TURBO_SUMMARIZE }}
216+ turbo-team : ${{ vars.TURBO_TEAM }}
217+ turbo-token : ${{ secrets.TURBO_TOKEN }}
218+
187219 - name : Lint packages using publint
188220 run : pnpm turbo lint:publint $TURBO_ARGS
189221
0 commit comments