run & debug projects [easily] with stable Xcode on beta iOS devices

Daniele Margutti
Jul 13, 2018 · 2 min read

This post is also available on my blog ;-)

June is passed and, as usual, the WWDC conference gave to us a new set of iOS beta versions to try.
While the first days of September are usually committed to test our apps on a pretty-usable iOS beta, these months are an irresistible opportunity to have fun (and swear) by playing with early iOS versions on our device.

If we can tolerate a certain amount of bugs and strage behaviours we should also to run our projects on these devices using the stable version of Xcode and not the beta one.
However “old” Xcode version are not able to run projects inside devices with iOS betas.

The trick is to dig inside the .../Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport of our Xcode-beta and copy/link desired SDK folders inside the old stable Xcode DeviceSupport’s folder. While it’s really easy it also a bit annoying procedure, so I’ve just created a really simple script in Swift.

xcbetarunner is a tool you can install in your terminal and allows you to sync SDKs between stable and beta versions of Xcode. It’s really simple to use.

Just type:

sudo xcbetarunner -a sync

and you’re done!
All stable SDKs are now available on stable Xcode version and you can run your project using your Xcode.app inside your iOS beta.
There are several other interesting commands; just checkout the github repository here.

Daniele Margutti

Written by

Senior Developer — Mobile Tech Lead @ Immobiliare.it— www.danielemargutti.com