Commit 3cfdd07
fix: make embed-runner-icon post-action work on device & sim builds
The icon-embed post-action re-codesigns the Runner.app after modifying
it. Two bugs in the identity-discovery step were caught running the PR
test plan on a real device:
- Piping `codesign -dvv` straight into `awk '... exit'` makes awk close
the pipe early, killing codesign with SIGPIPE. With `set -o pipefail`
that became a fatal error and failed the whole build. It triggered
whenever an Authority line exists -- i.e. every real-device build.
Simulator builds dodged it only because their ad-hoc signature has no
Authority line. Fix: capture codesign output once into a variable and
parse from the string, so no live pipe can be broken.
- Simulator builds are ad-hoc signed (no Authority line), so no identity
was discovered and the bundle was left with a stale signature that
failed `codesign --verify`. Fix: fall back to an ad-hoc identity ("-")
when the bundle reports `Signature=adhoc`.
Verified on iOS simulator and a real device: build succeeds, post-action
runs, and `codesign --verify --deep --strict` reports the Runner.app as
valid.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 29caa97 commit 3cfdd07
1 file changed
Lines changed: 11 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
65 | 70 | | |
66 | 71 | | |
67 | | - | |
68 | | - | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
69 | 78 | | |
70 | 79 | | |
71 | 80 | | |
| |||
0 commit comments