Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do i prevent Xcode from overwriting iTunes binary?

I have a really annoying problem. My app is published in the AppStore.

Everytime i run the app from Xcode, the iTunes binary just gets overwritten... and next time i need to test something with the production version of the app, i need to re-download it.

Is there any way to solve this?

Thanks in advance!

like image 848
Jorge Leandro Perez Avatar asked Nov 26 '25 06:11

Jorge Leandro Perez


2 Answers

You need to change your bundle identifier. Here's how I set it up in my projects

  • Select your Project
  • Select your target
  • Navigate to the Info tab
  • Change the bundle identifier to a custom build setting e.g. I have it as ${BUNDLE_IDENTIFIER}

enter image description here

  • Now click on Project - (you may wish to keep at target level your choice)
  • Navigate to the Build Settings tab
  • Scroll all the way to the bottom to see User-Defined
  • Click Add Build Setting
    • (1) Select Add User-Defined Setting
  • (2) Add Key as the name you chose earlier
  • Set a different bundle identifier for each scheme

enter image description here


Bonus

You can use the same trick for icons so you can easily tell apart your builds on one device

like image 187
Paul.s Avatar answered Nov 27 '25 20:11

Paul.s


Changing the bundle identifier, as Paul.s suggested, works — but it means your Release and Debug builds will diverge. Technically they will be different apps that use different containers. There can be good reasons to do this, but it has it's risks too: it's a bit more complicated, and you usually have to work a little harder to make sure you test that the development version properly handles data from the production version. You'll want to make sure any ad hoc builds you send to testers use the production bundle identifier.

Another way to approach the problem is to streamline installing the old version. If you Archive your production builds, then you can install them without downloading them again through the App Store. Just open-up a previously exported IPA and sync.

like image 21
Vincent Gable Avatar answered Nov 27 '25 19:11

Vincent Gable



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!