Skip to content

Commit 8150e2b

Browse files
committed
devbox ios devices lists the devices the box sees over USB, starting the usbmuxd of the box first unless USBMUXD_SOCKET_ADDRESS points at the one of another machine, and says to answer Trust on the device and run it again when none shows up; scripts/devbox-build.sh devices runs it from the host. What is written for the user now names the devbox commands rather than xtool: devbox ios for the SDK and the Apple sign-in (run again, it builds nothing twice and only signs in; mode 0, an API key, for USB and Wi-Fi, mode 1, any Apple ID, a free one included, for USB), devbox ios devices instead of sudo usbmuxd and xtool devices, and a first app made of a project.yml for XcodeGen and devbox ios xcode instead of xtool new and xtool dev, in devbox help ios, ios-usb and ios-wifi, the messages of devbox ios and of devbox-build.sh, docs/dev-envs.md, docs/commands.md and the skill of the box. Checked in a throwaway box: devbox ios --help, devbox ios devices with no usbmuxd and with no device seen; not yet with a device, which another box holds; shellcheck clean, devbox help --check passes
1 parent eaa0c79 commit 8150e2b

9 files changed

Lines changed: 164 additions & 72 deletions

File tree

‎docs/commands.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ devbox commands # bare list, one name per line, for completions
3636
| `changelog` | `dev-box-changelog` | what changed in the box, newest first; the 3 latest, `-n N`, `--all`, `--upcoming` for what the next image brings |
3737
| `tour` | `dev-box-tour` | a guided tour of the box, two minutes, commands run under your eyes |
3838
| `desktop` | `dev-box-desktop` | the graphical session of `devbox dev-env desktop`, reached with gliff, started at connection and stopped by hand: in the menu and the list once `devbox dev-env desktop` is installed; a menu without an argument, `status`, `start`, `stop`, and its graphical apps (VS Code, Chromium): `apps`, `install`, `remove`, `open` |
39-
| `ios` | `dev-box-ios` | the iOS SDK of `devbox dev-env ios` in one go: a `.xip` of Xcode picked with gum among the ones of the home, `install-toolchain.sh` run on it in the right form, the SDK checked, the `.xip` deleted if you say so, then `xtool auth`; `sdk <xip>` without the list, `status`; `pair` pairs the device on USB for Wi-Fi, once (iOS 27); `kmp [dir]` links the iOS framework of a Kotlin Multiplatform project on Linux, which Gradle skips, through `kmp/build-framework.sh` of omarchy-apple-dev (`--target ios_simulator_arm64`, `--module`, `--out`, `--dynamic`, `--xcframework`), also as root from the host for a project mounted with rootless Docker; `xcode [dir] [run|project|build|install|launch|logs]` builds the app of an Xcode project on Linux, then signs it for the device plugged in, or over Wi-Fi with `--wifi <address>` once paired (`IOS_WIFI`, `devbox help ios-wifi`), installs and launches it (`--project` for an `.xcodeproj` or an XcodeGen `project.yml`, `--target`, `--configuration`, `--package name=path[@ref]`, `--kmp :module` for a Kotlin Multiplatform app, `--signed-id`, `--signed-suffix`, `--out`, `--min-ios`, `--no-darwin-manifests`), also as root from the host. Needs the omarchy-apple-dev release the image pins: after an image update, `devbox dev-env ios` first (`status` shows it). In the menu and the list once `devbox dev-env ios` is installed |
39+
| `ios` | `dev-box-ios` | the iOS SDK of `devbox dev-env ios` in one go: a `.xip` of Xcode picked with gum among the ones of the home, `install-toolchain.sh` run on it in the right form, the SDK checked, the `.xip` deleted if you say so, then the Apple sign-in (run again, it only signs in); `sdk <xip>` without the list, `status`; `devices` lists the devices seen over USB, `usbmuxd` started first (answer Trust on the device the first time); `pair` pairs the device on USB for Wi-Fi, once (iOS 27); `kmp [dir]` links the iOS framework of a Kotlin Multiplatform project on Linux, which Gradle skips, through `kmp/build-framework.sh` of omarchy-apple-dev (`--target ios_simulator_arm64`, `--module`, `--out`, `--dynamic`, `--xcframework`), also as root from the host for a project mounted with rootless Docker; `xcode [dir] [run|project|build|install|launch|logs]` builds the app of an Xcode project on Linux, then signs it for the device plugged in, or over Wi-Fi with `--wifi <address>` once paired (`IOS_WIFI`, `devbox help ios-wifi`), installs and launches it (`--project` for an `.xcodeproj` or an XcodeGen `project.yml`, `--target`, `--configuration`, `--package name=path[@ref]`, `--kmp :module` for a Kotlin Multiplatform app, `--signed-id`, `--signed-suffix`, `--out`, `--min-ios`, `--no-darwin-manifests`), also as root from the host. Needs the omarchy-apple-dev release the image pins: after an image update, `devbox dev-env ios` first (`status` shows it). In the menu and the list once `devbox dev-env ios` is installed |
4040
| `help` | `dev-box-help` | step by step help for what a command cannot do alone: without a topic, a list to pick from; `--list`, `--check` |
4141
| `migrate` | `dev-box-migrate` | run the migrations shipped by the image, once each |
4242
| `mise-install` | `dev-box-mise-install` | write a mise-backed wrapper into `~/.local/bin` |
@@ -139,7 +139,7 @@ devbox help --check # hold every topic to the layout
139139

140140
| Topic | Steps for |
141141
| --- | --- |
142-
| `ios` | what is left to you after `devbox dev-env ios`: Xcode and the SDK, `xtool auth`, the device, a first app, debugging and TestFlight, a newer Swift |
142+
| `ios` | what is left to you after `devbox dev-env ios`: Xcode and the SDK, the Apple sign-in, the device, a first app, debugging and TestFlight, a newer Swift |
143143
| `ios-usb` | an iPhone or iPad plugged into your machine while the box runs on another |
144144
| `ios-wifi` | an iPhone or iPad under iOS 27 over Wi-Fi, without the cable: `devbox ios pair`, then `devbox ios xcode --wifi` |
145145
| `gpu` | giving `/dev/dri` to the box on the host, then the drivers and the test |

‎docs/dev-envs.md‎

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -125,14 +125,17 @@ they find the Swift of mise: `install-toolchain.sh` (always `--user-only`),
125125
TestFlight). Flutter apps and the experimental mode without an Xcode download
126126
are in the clone. `libimobiledevice`, which the xtool build links, comes
127127
through `devbox pkg`. One step is left to you, since it takes your Apple account:
128-
`XCODE_XIP=~/Xcode.xip install-toolchain.sh` builds the iOS SDK from an
129-
`Xcode.xip` downloaded from developer.apple.com, and `xtool auth` signs in;
130-
`devbox ios` chains both, the `.xip` picked in a list.
128+
`devbox ios` builds the iOS SDK from an `Xcode.xip` downloaded from
129+
developer.apple.com, picked in a list (`install-toolchain.sh` underneath), then
130+
signs in to Apple (`xtool auth`). Run again, it builds nothing twice and only
131+
signs in. Mode 0, an App Store Connect API key, takes a paid Apple Developer
132+
Program membership and gives `devbox ios xcode` USB and Wi-Fi; mode 1, the
133+
password of any Apple ID, a free one included, gives it USB only.
131134
There is no simulator: an app runs on a real device, plugged into the host
132135
and given to the box by the USB block of `compose.override.example.yaml`, with
133-
`devbox pkg add usbmuxd` and `sudo usbmuxd` in the box (below). The install ends on
136+
`devbox pkg add usbmuxd` and `devbox ios devices` in the box (below). The install ends on
134137
those steps, one by one (the Xcode download and the SDK, the device,
135-
`xtool new` and `xtool dev` or `device-run.sh` for a first app, what to answer
138+
a `project.yml` and `devbox ios xcode` for a first app, what to answer
136139
on the device, debugging, TestFlight, moving to a newer Swift), and
137140
`devbox help ios` shows them again. A box that had `ios` before
138141
omarchy-apple-dev keeps its xtool AppImage until `devbox dev-env ios` runs
@@ -171,10 +174,12 @@ sudo systemctl mask --now usbmuxd
171174
docker compose up -d
172175
# in the box, the device plugged in and unlocked
173176
devbox pkg add usbmuxd
174-
sudo usbmuxd # again after each restart of the box
175-
xtool devices # answer Trust on the device, then run it again
177+
devbox ios devices # answer Trust on the device, then run it again
176178
```
177179

180+
`devbox ios devices` starts the usbmuxd of the box when it is not running, as
181+
every command that reaches the device does, then lists the devices it sees.
182+
178183
`devbox ios pair`, for Wi-Fi afterwards, needs this once too.
179184

180185
A Kotlin Multiplatform app needs one more piece: Gradle builds its klibs on
@@ -190,7 +195,7 @@ then runs as on a Mac, with its Apple parts swapped:
190195
in `~/.cache/omarchy-apple-dev/kmp`;
191196
- LLVM for Linux;
192197
- the `ld64.lld` of the SDK's toolset;
193-
- the SDK built by `devbox ios sdk`.
198+
- the SDK built by `devbox ios`.
194199

195200
The output is `<module>/build/omarchy-kmp/<target>` (`ios_arm64`, or
196201
`ios_simulator_arm64` with `--target`), with `<Name>.xcframework` next to it
@@ -395,7 +400,7 @@ runs in the box.
395400
```bash
396401
ssh -R 27015:/var/run/usbmuxd <user>@<box> # from your machine, device plugged in
397402
export USBMUXD_SOCKET_ADDRESS=127.0.0.1:27015 # in the box, in that session
398-
xtool devices
403+
devbox ios devices # starts no usbmuxd in the box then
399404
```
400405

401406
`devbox help ios-usb` has the whole of it, checked as far as xtool opening

‎plans/ios-upstream.md‎

Lines changed: 28 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,16 @@
11
# iOS sans Mac : contributions en amont et nettoyage de dev-box
22

3-
État au 6/11/2026, 12 h 15. **dev-box v1.55 est publiée** : `devbox ios xcode` / `kmp` appellent les outils
4-
d'omarchy-apple-dev, épinglé par commit (`OAD_REF` = `031155f`, main après #139, pas encore de version
5-
publiée), et `ios_piped` est retiré. La box locale est à jour (`devbox dev-env ios` fait, caches
6-
`devbox-ios-kmp` supprimés), Aero et l'app KMP construites, installées et lancées depuis elle sur l'iPhone 11 Pro.
7-
Application-ios : exemple `--no-asset-extensions` retiré (`777245f`).
3+
État au 8/11/2026, 19 h 30. **dev-box v1.63 est publiée** : omarchy-apple-dev épinglé par commit
4+
(`OAD_REF` = `c6eb9d5`, main après #144, pas encore de version publiée), dont le pin xtool est le main
5+
d'xtool (`7cc56c3` : amont `a2875dd`, avec RCodesign #389 et le contournement #432, plus les 11 commits du
6+
fork, tag `omarchy-main-pin`). Plus aucun correctif d'xtool porté à la main par cherry-pick. La box locale est
7+
à jour (`devbox dev-env ios` fait, appairages restaurés) ; Aero et l'app KMP construites, installées et
8+
lancées depuis elle sur l'iPhone 14 de Laureline (iOS 27.2).
9+
10+
Relecture du 8/11 : dev-box ne réimplémente rien de ce qu'offrent omarchy-apple-dev ou xtool. Ce qui lui est
11+
propre (XcodeGen, `--package`, `binaryTarget` et `compose-resources` du framework KMP, `--min-ios`) automatise
12+
des étapes que le README KMP d'omarchy fait faire à la main. Règle : pas de script maison dans dev-box quand
13+
l'amont a l'outil, seulement des wrappers.
814

915
Des contournements ont été ajoutés dans `devbox ios xcode` / `devbox ios kmp` pour construire Aero
1016
(application-ios) et l'app KMP (application-android/iosApp). Chacun a été proposé en amont. Une fois les
@@ -23,10 +29,12 @@ correctifs publiés, dev-box peut les retirer.
2329
| #133 | #134 | `kmp/build-framework.sh` (framework Kotlin lié sous Linux) | ✅ fusionnée |
2430
| #132 | #135 | xtool épinglé : passage à 1.24.0 plus les correctifs du fork | ✅ fusionnée le 5/11 à 23 h 48 (squash 7ce8f58), pin `a8a5a40`, tag `omarchy-1.24.0-pin` du fork |
2531
| | joshuaswarren/xtool#3 | Branche 1.24.0 plus les 11 commits du fork (pour `omarchy/1.24.0-fixes`) | ⏳ ouverte (le pin de main est déjà ce commit) |
26-
| #132 | **#138** | xtool épinglé : main d'xtool (`4ec0e96`, contient #375, #430, #422) plus le contournement #432 et les 11 commits du fork (pin `86925e8`) | ⏳ ouverte (6/11, mise à jour le même jour) |
27-
| | joshuaswarren/xtool#4 | Maintenant main + #432 + fork (`86925e8`), à proposer comme nouveau pin quand #432 sera fusionnée | ⏳ ouverte |
32+
| #132 | #138 | xtool épinglé sur main + #432 (pin `86925e8`) | fermée, remplacée par #139 |
33+
| #132 | #139 | xtool épinglé sur main avant #389, plus #430, #422 et les commits du fork (pin `c9f4363`, tag `omarchy-main-pre389-pin`) | ✅ fusionnée le 6/11 (`031155f`) ; #132 fermé le 8/11 |
34+
| (suite de #132) | **#144** | xtool épinglé sur main (`7cc56c3` : `a2875dd` + les 11 commits du fork, tag `omarchy-main-pin`) | ✅ fusionnée le 8/11 à 16 h 54 (`c6eb9d5`), après deux verdicts GREEN de leurs agents |
35+
| | joshuaswarren/xtool#4 | Branche de suivi : main + commits du fork, tête `7cc56c3` | ⏳ ouverte (sert de référence au pin, le tag suffit) |
2836

29-
Aucune version d'omarchy publiée ne contient encore ces correctifs : la dernière est v0.4.4, du 5/11 à 00 h 16. #132 reste ouvert pour #375 et #430 : le mainteneur a dit qu'il reporterait #430 dans le fork une fois fusionnée, et déciderait pour #375 (report dans le fork ou attente de la prochaine version).
37+
Aucune version d'omarchy publiée ne contient encore ces correctifs : la dernière est v0.4.4, du 5/11 à 00 h 16. À la prochaine version, `OAD_REF` pourra reprendre un tag.
3038

3139
### xtool (xtool-org/xtool)
3240

@@ -36,8 +44,8 @@ Aucune version d'omarchy publiée ne contient encore ces correctifs : la derniè
3644
| #426 | #428 | 409 « Multiple profiles found » | fermée par le mainteneur, reprise dans **#430** |
3745
| #425, #426 | **#430** (kabiroberai) | « ds: fix profile creation conflicts » : pagination, appareils désactivés exclus, vérification d'annulation, suppression du profil `XTL profile <id>` de ce bundle après la lecture des pages | ✅ fusionnée le 6/11 à 05 h 15 (`ac40282`), dans aucune version publiée |
3846
| (amont) | #375 | Arrêt sur une entrée standard qui n'est pas un tube | ✅ fusionnée le 28/10, mais dans **aucune version publiée** (après 1.24.0) |
39-
| **#431** (le nôtre) | | La compilation release plante le compilateur sous Linux depuis #389 (RCodesign), bissecté, reproduit dans leur image ; cause : bug du compilateur Swift (swiftlang/swift#94055, CoroSplit), déclenché par deux `unimplemented()` | ⏳ ouvert (6/11) |
40-
| #431 | **#432** (la nôtre, brouillon niveau 2) | Contournement : `reportIssue` + `throw UnimplementedFailure` dans `UnimplementedSigner` | ✅ approuvée par le mainteneur (6/11), relue, niveau 1, pas encore fusionnée |
47+
| **#431** (le nôtre) | | La compilation release plante le compilateur sous Linux depuis #389 (RCodesign) ; cause : bug du compilateur Swift (swiftlang/swift#94055, CoroSplit, sans réponse), déclenché par deux `unimplemented()` | ✅ fermé le 8/11 |
48+
| #431 | **#432** (la nôtre) | Contournement : `reportIssue` + `throw UnimplementedFailure` dans `UnimplementedSigner` | ✅ fusionnée le 8/11 (`a2875dd`) |
4149

4250
Le mainteneur a fermé #427 et #428 le 5/11 pour reprendre leur contenu dans #430, qui contient tous nos points
4351
sauf la tolérance d'un 404 à la suppression (deux installations simultanées du même bundle), un point mineur.
@@ -197,6 +205,16 @@ Le détail des retraits, pour mémoire :
197205
`lib/ios-common.sh`. Le garder pour `xtool devices` si besoin, puisque `timeout` reste utile.
198206
3. Retester une installation complète.
199207

208+
### C bis. Passage au main d'xtool (fait le 8/11, dev-box v1.63)
209+
210+
Ce que `7cc56c3` apporte par rapport à `c9f4363` : signature RCodesign (#389, seul chemin maintenu en
211+
amont), correctifs de connexion Apple et double authentification par SMS (#415-#417), sortie des
212+
sous-processus (#413), contournement du plantage du compilateur (#432). Testé dans un conteneur jetable puis
213+
dans la box : xtool reconstruit en 3 min, Aero et l'app KMP signées par `provision-dev.py` / `sign-dev.sh`,
214+
installées et lancées ; le chemin `xtool install` (Apple ID par mot de passe, ajouté en v1.63 par
215+
2bab208) forcé avec la clé API : Aero installé depuis le `.app`, identifiant relu, lancé par
216+
`devbox ios xcode launch`. Pas encore essayé avec un vrai Apple ID gratuit.
217+
200218
### D. Ménage, une fois tout fusionné
201219

202220
- Supprimer les branches des forks : `c4software/omarchy-apple-dev` (`xcodeproj2xtool-configuration`,

0 commit comments

Comments
 (0)