You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-**Release vs debug** — matrix runs both; each has separate artifacts (`debug` / `release` in the artifact name).
222
222
-**Retry** — Pre-Boot retries up to 3 times with 60s between attempts (clean shutdown + boot each time).
223
223
-**Do not boot the simulator only inside Detox** — historical races where the testee never sent “ready” to the Detox proxy; pre-boot remains mandatory.
224
+
225
+
### Pinned Homebrew utilities
226
+
227
+
CI installs macOS build helpers from **vendored formulae** in `.github/homebrew-rnfb/Formula/` instead of live taps (`wix/brew`, `homebrew-core`). Each formula file is frozen in git with pinned `url`, source `sha256`, and bottle hashes — similar in spirit to SHA-pinned GitHub Actions.
**Workflow install** — both workflows call `.github/workflows/scripts/install-homebrew-rnfb.sh` (from repo root). Homebrew 6+ refuses bare `brew install --formula path/to.rb`; the script copies formulae into a local `invertase/rnfb` tap, trusts it once per job, then installs:
**Why** — Third-party taps can change formula definitions on every `brew update`. Vendoring avoids supply-chain drift and Brew 6 untrusted-tap warnings for live third-party taps. We still `brew trust invertase/rnfb` for the ephemeral local tap copy each job creates. The install script **uninstalls any existing `homebrew-core` (or other tap) install** of the same formula name first — GHA macOS images often preinstall `xcbeautify`, and Brew refuses same-name formulae from two taps.
245
+
246
+
#### When to update a pinned formula
247
+
248
+
- CI **Install brew utilities** fails after a macOS runner / Xcode image bump (common for `xcbeautify` Swift/`on_sequoia` conditionals).
249
+
- You need a newer **applesimutils** or **xcbeautify** feature or bugfix.
250
+
- A security advisory affects the pinned upstream release (bump `url` / version and checksums).
251
+
252
+
#### How to update a pinned formula
253
+
254
+
1.**Fetch the upstream formula** you want to vendor (usually `master`, or a specific commit if you need a known-good revision):
2.**Record the upstream commit** (for the table above and the file header):
267
+
268
+
```bash
269
+
# applesimutils
270
+
gh api repos/wix/homebrew-brew/commits \
271
+
-f path=Formula/applesimutils.rb -f per_page=1 \
272
+
--jq '.[0].sha[:12]'
273
+
274
+
# xcbeautify
275
+
gh api repos/Homebrew/homebrew-core/commits \
276
+
-f path=Formula/x/xcbeautify.rb -f per_page=1 \
277
+
--jq '.[0].sha[:12]'
278
+
```
279
+
280
+
3.**Merge into `.github/homebrew-rnfb/Formula/<name>.rb`** — keep the RNFB header at the top (replace version + commit), then paste the upstream `class` body. Remove `head "..."` lines if present (frozen vendored formulae should not track moving branches). Example header:
281
+
282
+
```ruby
283
+
# frozen_string_literal: true
284
+
# RNFB CI vendored formula — do not install from third-party taps in workflows.
applesimutils --help # applesimutils (no --version)
295
+
```
296
+
297
+
If upgrading a formula already in your Cellar, uninstall first: `brew uninstall <name>`.
298
+
299
+
5.**Update this doc** — bump the version and upstream-commit columns in the table above.
300
+
301
+
6.**Open a PR** — CI will exercise the same install script as production workflows. Watch the **Install brew utilities** step timing (`applesimutils` often builds from source on `macos-26`).
302
+
303
+
#### Local dev (optional)
304
+
305
+
Match CI with the install script, or install a single formula file via the script:
**`applesimutils` on modern runners** — upstream bottles target older macOS releases; GHA `macos-26` typically **builds from source** (needs Xcode). Expect a longer “Install brew utilities” step than `xcbeautify`, which usually installs from a matching bottle.
0 commit comments