1

I'm trying to use xcrun simctl to boot a device and uninstall an application, but it hangs on the uninstall step

xcrun simctl boot <deviceudid>
xcrun simctl uninstall <deviceudid> <bundleid>

and it hangs on uninstall and sits forever...however, if i have the simulator already running and execute

xcrun simctl uninstall <deviceudid> <bundleid>

it works fine...but i'm trying to do this in a script without opening the simulator manually

1 Answer 1

3

This happens because when you use 'xcrun simctl boot ...' you are not getting a full boot of the simulator. Some services (including those provided by the system app, like install or launch) are unavailable in this mode.

If you want to script booting the device in full, you'll probably want to refer to my answer in Xcode 6 - Launch simulator from command line

4
  • so the only way to actually uninstall an app from a device is by opening the simulator with open -a Simulator first?
    – VTS12
    Commented Mar 6, 2016 at 2:49
  • Either that, or you can use 'xcrun simctl erase ...' to erase the device to a default state. Commented Mar 7, 2016 at 4:23
  • thanks for the response...unfortunately i think that would erase everything...not just the app i'm trying to uninstall
    – VTS12
    Commented Mar 7, 2016 at 18:02
  • Yes. Those are your options at present. Commented Mar 9, 2016 at 3:07

Not the answer you're looking for? Browse other questions tagged or ask your own question.