Here's a way:
1. First, install the configuration file (not described here) for the project, and run it successfully in the ios device state.
2. Select products-> archives
3. Click the Distribute button to open a new window and select "Export as Xcode Archive", as shown below:
4. Save will pop up, and click Save.
5. Select the generated file XXX13-5-10at4.00pm4.00.xcarchive, right-click and select Show Package Contents.
6. Select products-> Application, you will see your. App file. The next step is to drag. Add the app file to the itunes application and make iTunes run. App file. Right-click the generated file and select Show in finder to view the corresponding. Ipa file.