Add ability to run iOS app on a physical device
- Dominant language
- Python
- Stars
- 3.3k
- Forks
- 549
- Avg merge
- 1d 4h
- Merged PRs (30d)
- 40
Description
At present, you can use `briefcase run iOS` (with an optional `-d `) to run on an iOS simulator device. However, it is not possible to deploy to a *physical* iOS device that is attached by a USB cable.
**Describe the solution you'd like**
It should be possible to use `briefcase run iOS` to deploy to a physical device.
**Describe alternatives you've considered**
The current workaround is to:
1. Open the Xcode project generated by Briefcase (The dev version of Briefcase simplifies this with `briefcase open iOS`)
2. Select the root node of the Project in Xcode project explorer
3. Select "Signing & Capabilities"
4. Select a development team that has a Development or Distribution certificate
5. Select a physical device from the device pulldown at the top of the screen
6. Press the Run button.
**Additional context**
Xcode does a lot of automated management of signing identities and certificates, including automated registration of devices against the developer certificate. Any implementation of this feature will need to be careful about whether previous Xcode usage has "tainted" a clean developer environment.
`xcodebuild` provides a number of options for setting build properties (like signing identities). (e.g., passing in `CODE_SIGN_IDENTITY` as an option)
A list of physically attached devices can be obtained using `xcrun xctrace list devices`. This list also includes simulators; it may be possible to use a single call to list all available devices (simulator and physical).
Contributor guide
Research direction
Start with the `briefcase run iOS` entry point and compare its simulator-device handling with the physical devices listed by `xcrun xctrace list devices`. Review the generated Xcode project and the `xcodebuild` signing options, then verify that an attached device can be selected and deployed to without breaking simulator runs or unexpectedly altering signing state.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ios, python
- Domain
- build-system, cli, mobile-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100