I know that this is not a new question, but I have tried many solution like edit Xcode project file manually or recreating new scheme for target after renaming it.
Can somebody help me with this question how copy target in right way and then rename it.
Right now I just rename scheme and it is displayed as is. But when Xcode is running app, under progress indicator it says: Running ProjectName-copy. But I have renamed target but seems product names or some build settings still has "...-copy" in the name.
Select your target from TARGETS(in left navigation bar) and double click, then rename it.
Select the project you want to rename in the “Project Navigator” which can be found on the left side of the Xcode view. On the right-hand side of the window, select the “File Inspector”. The name of your project should be in there under “Identity and Type”, change it to “NEW” and press Enter.
Go to project's settings in the Project Navigator panel. Under the Targets sections, right click the existing target and select Duplicate to copy your existing target.
Right-click on the class name in the interface ( . h ) file, choose Refactor->Rename , and Xcode will guide you through the process, allowing you to preview changes before you commit to them. Xcode will let you review the changes before you commit.
All done.
PS:
After Duplicating the target, Xcode make a new Info.plist file named 'xxx copy-Info.plist' in the root path of project. If you want to change its name and path, after doing this, you should go to 'New target -> Build Settings -> Packaging -> Info.plist file' and change the value to the path of new file.
Press on the target name in xcode ( in the same place where you want to select the sim/device type) and select "Manage Schemes...". Highlight the scheme with the copy inside name and press enter on keyboard. You can rename it there.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With