iPhone Apps built for the simulator are stored here:
/Users/<username>/Library/Application Support/iPhone Simulator/User/Applications
Is it possible to copy the <GUID>.sb and <GUID> directory and install them on a different computer (with Development tools installed)?
This would be very useful for testing/demoing with out having to buy iPhones for all the managers and external clients.
We just put up a little tool that will help you through this process for the latest version of Xcode.
It basically creates a zip of the app so that you can pass to the tester and it'll install the app in the right Xcode directory. It will also open it up for the user with the right device selected in iOS Simulator.
Here it is
http://blog.placeit.net/ios-app-packager/
Hopefully it's useful to you guys.
I found a way that requires just a little more setup, but is much easier for non-developers:
Instructions for your users/testers:
How to set it up:
Done. This will create a self-contained Mac OS X yourAppDisplayName.app file in the same folder (with your app's icon as the icon) that you can stick up on an FTP server or email to your users/testers.
--
I think it's much neater/slicker than having to explain where to copy files, how to launch the simulator and so on.. And if anything gets messed up they can just uninstall via the familiar tap-and-hold + (x) gesture in the simulator UI, then double-click the app you sent them again.
You can also produce several of these packages changing the bundle identifier between builds, allowing them to be installed side by side in your testers' simulators; say for getting some user feedback on different UI designs, or configure one for Production and one for Staging/QA servers, so your content editors can check their changes before they go live or whatever..
The ability to reinstall the app from a desktop icon is also very convenient for localisation testing: launch the simulator, uninstall the app if present, set the required region format and language, double click the icon on your desktop, test; repeat for each required locale. (guarantees a fresh install each time, I've found that switching language with the app installed can result in all sorts of strange behaviour)
Yes, if you send those files to another person, and they put them into that directory, they can test the applications in the iPhone Simulator as well :)
You are able to use
simctl
binary to interact with iOS simulators from command line.Build app
Variant 1 (Preferable):
Build a project
Pattern:
xcodebuild -project "path_to_fileName.xcodeproj" -target "targetName" -sdk "targetSDK" -configuration buildConfig CODE_SIGN_IDENTITY="NameOfCertificateIdentity" PROVISIONING_PROFILE="ProvisioningProfileName" OTHER_CODE_SIGN_FLAGS="--keychain keyChainName"
Build a worksapce
Pattern:
xcodebuild -workspace "path_to_fileName.xcworkspace" -scheme "schemeName" -sdk "targetSDK" -configuration buildConfig CODE_SIGN_IDENTITY="NameOfCertificateIdentity" PROVISIONING_PROFILE="ProvisioningProfileName" OTHER_CODE_SIGN_FLAGS="--keychain keyChainName"
Example:
xcodebuild -workspace "/Users/name.xcworkspace" -scheme "MyShemeName" -sdk iphonesimulator CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
Find .app file inside derived data folder.
/Users/alex/Library/Developer/Xcode/DerivedData/../Build/Products/Debug-iphonesimulator/AppName.app
Variant 2:
Activity Monitor
and find the<App Name>
you are running(Not Xcode, the actual App you are building). Double click on the<App Name> -> Open Files and Ports -> Find <App Name.app> path -> find and copy a file <App Name.app> by path -> save the file locally
.Install app
xcrun simctl install booted <path to App Name.app>
The original instruction here -
https://coderwall.com/p/rv2lgw/use-xcodebuild-to-build-workspace-vs-project
https://www.webdigi.co.uk/blog/2016/how-to-transfer-your-app-to-an-ios-simulator-on-another-machine-using-app-file-and-xcrun/