Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to rename XCode5 project that has an attached Pods?

I'm trying to rename an XCode5 project that has an attached CocoaPods (Pods project).
(I've attached the CocoaPods using the following tutorial: http://www.raywenderlich.com/12139/introduction-to-cocoapods)

I've tried the standard renaming technique: https://stackoverflow.com/a/19442868/173623
But it breaks the build, since the rename only takes place for App project.

How can I accomplish this task?


Thank you.

like image 767
thedp Avatar asked Feb 11 '14 16:02

thedp


People also ask

How do I change the project name and target name in Xcode?

Select the project from the project navigator to open the project editor and see a list of the app's targets. To rename a target, select it, press the Return key, and enter the new name. If all you want to do is rename the app, you're finished.


1 Answers

After viewing your provided tutorial, I would like to suggest you the following:

  • First follow the standard renaming technique that you got in another post
  • Now if you have enough time and patience, then it'd be best to start over from the section Installing Your First Dependency

If you don't do that, then you may follow the next steps, but I can't guarantee for success.

  • Replace all the occurrence of CocoaPodsExample.xcworkspace with <NEW_PROJ_NAME>.xcworkspace in the Pods folder and possible places
  • Close the Xcode project (if you had it open) and open <NEW_PROJ_NAME>.xcworkspace to continue and test if it worked
  • Now, switch to ViewController.m and replace CocoaPodsExample with <NEW_PROJ_NAME> if exists

Thats it! The project should now build successfully.

like image 76
Wasif Hossain Avatar answered Oct 24 '22 06:10

Wasif Hossain