Apple could be in the process of developing a version of XCode to run on iPhones and iPads in iOS 14 and iPadOS 14, a leaker claims, a rumor that could lead to mobile apps being developed on the. Now by using Xcode 9 and iOS 11 it is possible to run apps by using Wi-Fi. Connect the iPhone via USB, go into the device window (Cmd-Shift-2), select your phone, and check the connect via networkbox. More thorough instructions with screenshots here Pre-Xcode 9 answer. On your Mac, launch Xcode. On Xcode, create a new iOS application. With your new Xcode iOS application open, select iOS Device as your target. Click and hold Run, and select Analize from the context menu that appears. You can now close Xcode and continue using your iOS device to. To prepare your proprietary in-house app for wireless distribution, you build an archived version (a.ipa file), and a manifest file that enables wireless distribution and installation of the app. Use Xcode to create a versioned archive of your app, and then export the app for distribution to the organization. Once you wire your iOS device to the Mac for the first time and have your Mac trust the device, your device will be recognized by iTunes and Xcode. Now I'm not sure about Xcode, but with iTunes, once you wired the iOS device once, you can connect wirelessly and still sync your device, but you have to wire it.
NOTE: this is a companion article to the adHocGenerate script available at https://github.com/gknops/adHocGenerate
Wireless AdHoc Distribution allows your testers to install your iOS application by simply clicking a link on a web page or in an email. There is no longer a need for your testers to drag any packages to iTunes, connect their device, sync etc.
Note that this does not allow you to distribute your app to anyone. You still need your testers device UDIDs and add those to a mobileprovision.
The below procedure assume you use Xcode4 and have a web server available to upload your application to. Otherwise you may want to look into services offering support for iOS beta testing such as testflightapp.com (I have no experiences with them, so this is not an endorsement).
Three components are required to make this work:
Magic Link
OK, not really anything magic about it, just a specially crafted URL. The link in the above sample page (index.html
) looks like this (note that the newline after the semicolon in the first line was inserted for display here only, it should not be there):
You could also send this link in an email.
Manifest
You'll notice how the above link references a file named WirelessAdHocDemo.plist
. This is a manifest in property list format. It can be generated by Xcode or by some custom script and looks like this:
The keys in the above file that need to be modified for your app are:
- items.assets.[1].url
- items.assets.metadata.bundle-identifier
- items.assets.metadata.bundle-version
- items.assets.metadata.title
IPA
The WirelessAdHocDemo.ipa
contains your application along with the embedded mobileprovision
. Xcode creates this for you.
In any case you will need a Distribution Provisioning Profile. Go to the iOS Provisioning Portal, select Provisioning/Distibution
and create an adHoc profile for your app. Remember to select the Ad Hoc Distribution Method, and include the Devices of your beta testers. Download the Distribution Provisioning Profile (it will have a .mobileprovision
extension) and drag it onto iTunes.
Xcode4 actually provides a relatively easy way to produce the Manifest and the IPA (you will still have to create a web page with that Magic Link).
Start by selecting the scheme for your app, and select iOS Device in the scheme drop down. Now select Archive from the Product menu. In the Xcode default setting the Archive tab of the Organizer will appear. If not (and the archival process did not have any errors) select Organizer from the Window menu and select the Archive tab.
Select the Share button:
Select iOS App Store Package (.ipa) and from the drop down select your ad hoc mobileprovision. Click Next.
Xcode Deploy To Iphone Wireless Printer Driver
Your save panel may not include the extra fields shown above. Check the Save for Enterprise Distribution checkbox to bring those fields up. Using this option tells Xcode to also create the Manifest plist file for us.
Make sure to enter at least the name for your IPA, the Application URL and the Title, and of course selecting a folder for the files to be created.
Note that the Application URLmust be an absolute URL indicating the eventual location of the IPA at your web server.
Finally click Save.
Inspect the folder you selected in the Save panel, it will contain:
- .ipa (the IPA, signed and including the embedded mobileprovision)
- .plist (the Manifest plist file)
Create an index.html
file containing the Magic Link and add it to that folder, the upload the folder to your web site.
That's it, contact your testers to download and test the app.
For the occasional test release the above method is perfectly fine. However if your testing will be a longer process, or if you generate frequent milestone releases to solicit feedback from your customer or testers, the above procedure will become bothersome. Hp officejet 4632 scan to computer.
Fortunately Xcode provides a way to use the command line to generate, sign and embed the mobileprovision from an archive (for details do a Google search for xcrun
and PackageApplication
).
This allows us to use a script to generate the IPA, Manifest and a web page containing the Magic Link. As an example we will use the adHocGenerate
script available at github.
The script is controlled via environment variables and an optional template for the HTML
page.
We will call this script from a Post Action of the Archive action, so that it is run every time you archive your product (optionally duplicate your Scheme first if you do want control over when the AdHoc distribution data is generated). Bring up the Scheme Editor, click the disclosure triangle before the Archive action, and click the +
button. Select New Run Script Action from the drop down menu, and fill it in like in this example:
Here a template suitable for copy/paste:
The AdHoc_*
variables to fill out are:
A title for your app (human readable)
Download Xcode
This is the Identity Name of your developer profile used for distribution. You can find it in the Origanizer's Devices tab, on the left select Developer Profile in the LIBRARY group.
The path of your AdHoc distribution profile. To find that select the Origanizer's Devices tab, on the left select Provisioning Profiles in the LIBRARY group. Right- or Control-click on the correct Profile, and select Reveal Profile in Finder from the context menu. Tip: drag the file onto a Terminal window, the full path will appear and you can easily copy it. Sublime text 2 for python.
A directory on your disk where to place the generated files.
The absolute URL the IPA file will have on your web server.
Finally depending on where you placed the adHocGenerate
script you may need to include a path, See the adHocGenerate
README file for more information. That file will also explain other optional variables and how to customize the web page that is generated.
Now any time you select Archive from the Product menu all files needed for wireless distribution will be generated automatically.
More automation: copy files to web server
For further automation you could add an additional script to copy the produced files to your web server. Like above add another New Run Script Action, and add whatever commands are needed to copy the files to your web server. For example if you have ssh
access to that server, a command might look similar to this:
Use he same value for AdHoc_DESTDIR
as in the previous action.
Xcode Iphone Emulator
More automation: email beta testers
Lastly you could even automate sending an email to your testers. Add another action, but this time select New Send Email Action. Add the email addresses of your testers, and the link to your web page.
Unfortunately this action does not let you reference groups in Address Book, which would be rather useful. I filed an enhancement request. You can just leave the email address field empty. That way when Mail.app tries to send an email it will produce an error and offer you to edit the message. Video watching program. This allows you to check that everything is on the server, and also now you can use a group name in the compose window.
By default all apps you deploy from Xcode will make it to your device with the Debug Build Configuration. This is useful during development, but it doesn't optimise your code. It's therefore easier to debug, but your app doesn't run as fast as the final release version would.
Especially on older devices this can make a huge difference, particularly for your own personal apps that may never make it to the App Store.
There is a painless way to change how apps are deployed to your devices in Xcode. All we need is a distribution profile, just like the one we need for App Store submission. Next we'll change the Run Scheme to use the Release Build Configuration. Here's how to do that in Xcode 6.1.1:
- with your device selected, head over to Product – Scheme – Edit Scheme
- select Run from the list on the left
- change the Build Configuration from Debug to Release
- untick the 'Debug executable' option
- deploy your app using the usual playback button
Users have reported a 60% speed increase on their devices.
Make sure the distribution profile is imported into Xcode and selected as explained here.
Further reading: