Xcode is showing multiple working copies:
Working Copies
myProject - master
myProject_olderRepo
myProject_originalRepo
The second two are g
You might have used other project files. (it happens when you drag files to XCode and you forget to checkmark 'copy items if needed').
checkout: Xcode git showing multiple repositories
Solved this by deleting xccheckout file under
ProjectName.xcodeproj > project.xcworkspace > xcshareddata
This had contained references to the previous repos.
This solution helped me. Go to terminal and paste below code (this will show hidden files)
defaults write com.apple.finder AppleShowAllFiles YES.
Now go to your project folder and check if there is any .git files outside your working project folder.
.git file that is located outside project folder do not belong to your working project but other project. ( This is possible if you have made mistake in creating git for other project)
Either cut paste this .git file and save it some other location or you can delete it (if not so important). After deleting , reopen your project in xcode.
I am using Cocoapods and have a .xcworkspace along with my .xcodeproj.
This is what worked for me:
pod deintegrate
in Terminal.pod clean
pod install
to create it again.Now if you open the Workspace again, the other Working Copies should no longer exist.
If you have Git repositories showing up, then you must have a *.xcscmblueprint
file somewhere in your project. For me, it was in my workspace and not in a project. From terminal window:
% find . -name '*.xcscmblueprint'
./TaskMe.xcworkspace/xcshareddata/TaskMe.xcscmblueprint
Edit that file with care to keep just the entry you want. Or perhaps better, just delete the file and add back the repository you want.
I had forked a project and the new fork was still pointing to the original project files, so I was seeing Git for both the new and the original project. To fix I did the following:
Project.xcworkspace -> Show Package Contents
contents.xcworkspacedata -> Change Path