The operation could not be performed because “PROJECTNAME” has one or more tree conflicts

后端 未结 5 505
名媛妹妹
名媛妹妹 2020-12-17 09:30

I am using Git and when I tried to pull a newer development branch with my current branch using XCode\'s source control menu I received this error message:

T         


        
相关标签:
5条回答
  • 2020-12-17 09:46

    There is a conflict in the project file you need to pull using the command line or a GUI tool like SourceTree (Free) and manually resolve the conflict in a text editor or diff tool.

    See also:How to use Git properly with XCode?

    0 讨论(0)
  • 2020-12-17 09:52

    For me this error occurred when Xcode got confused on which branch the project was currently on. So I solved it by switching the branch to master and then back to the former branch again. So, try this simple fix first.

    0 讨论(0)
  • 2020-12-17 10:01

    I was in trouble with this problem. It often happens when I remove or change the directory of the project .For example, when I move one directory into another existing directory,both of the directory are real folder the warning will exist.

    In fact the meaning of tree conflict is that the directory level in your work repository is not same as it was on server.

    It's my way to resolve this problem :

    1. Check which directory in your local work repository differs from the server repository.
    2. If the local repository has extra directory Delete(local) -> update ->OK , if the local repository lacks of something and the extra elements in server is needless, Delete (server) -> update. NOTE After this the tree conflict is not existing any more.

    Hope helps.

    0 讨论(0)
  • 2020-12-17 10:07

    I had a similar issue. So I opened a terminal-windows and changed to the directory, verified my branch was clean with a git status, changed to master using git checkout master and merged my branch with git merge push-notifications. The Git Branching - Basic Branching and Merging page explains it in detail.

    0 讨论(0)
  • 2020-12-17 10:10

    My situation. Merging the master branch with minor changes into my current in-development or working version. I solved this issue by:

    1. Moving the in-development file with the tree conflict to my desktop (i.e. out of the repository controlled directory).
    2. Committing the most in-development version.
    3. Re-execute the merge from the master into the most recent version.
    4. Resolved actual merge conflicts.
    5. Confirmed that the file that was merged from main into the in-development branch was there and correct.
    0 讨论(0)
提交回复
热议问题