Xcode Source Control showing multiple Working Copies

后端 未结 12 1836
孤独总比滥情好
孤独总比滥情好 2020-11-28 09:17

Xcode is showing multiple working copies:

Working Copies
myProject - master
myProject_olderRepo
myProject_originalRepo

The second two are g

相关标签:
12条回答
  • 2020-11-28 09:42

    If this issue happens when using CocoaPods try:

    • Remove myProject.xcworkspace
    • Remove Pods/
    • Run pod install
    0 讨论(0)
  • 2020-11-28 09:46

    Not sure what happened here, I had one project but two working copies, similar to question. One of the working copies was synced with a repo on GitHub, and I had successfully pushed changes there. All I had to do, in the end, was to delete my local folder completely, then check out (clone?) from the remote repo on github again.

    (I'm not sure but I got the feeling that Xcode and/or the Xcode project was NOT handling multiple working copies, but that this was done like a top layer in the git structure itself. Maybe it is a feature of git?)

    0 讨论(0)
  • 2020-11-28 09:49

    I had two instances of the same project in my ProjectNavigator in XCode. One of them was marked with M and the other one with ?

    All I had to do to get rid of the copy, was delete the project marked with ? by control-clicking on it and selecting delete.

    0 讨论(0)
  • 2020-11-28 09:52

    Project.xcodeproj -> Show Package Contents

    Project.xcworkspace -> Show Package Contents

    xcshareddata

    Open .xcscmblueprint file

    Clean all content

    Save file and open Xcode again

    0 讨论(0)
  • 2020-11-28 09:57

    I have removed old repo using following steps.

    • ProjectName.xcodeproj -> Show Package Contents
    • project.xcworkspace -> Show Package Contents
    • xcshareddata
    • Open .xcscmblueprint file using any text editor
    • Remove all unrequited repo from following location DVTSourceControlWorkspaceBlueprintWorkingCopyRepositoryLocationsKey DVTSourceControlWorkspaceBlueprintWorkingCopyStatesKey DVTSourceControlWorkspaceBlueprintWorkingCopyPathsKey DVTSourceControlWorkspaceBlueprintRemoteRepositoriesKey
    • Save file and open Xcode again

    Note : If your project have WorkSpace then Direct click on ProjectName.xcworkspace instead of ProjectName.xcodeproj

    0 讨论(0)
  • 2020-11-28 09:57

    Follow the following steps:

    1.  Open terminal and go to your project directory
    2.  Run pod deintegrate in Terminal to remove Cocoapods from the project.
    3.  Run pod clean
    4.  Run pod install to create it again.
    

    Open .xcworkspace, worked for me.

    0 讨论(0)
提交回复
热议问题