Github Windows 'Failed to sync this branch'

前端 未结 17 1204
南旧
南旧 2020-12-22 21:59

I am using Github Windows 1.0.38.1 and when I click the \'Sync\' button after committing, I get the error

\"ent

相关标签:
17条回答
  • 2020-12-22 22:37

    I had this problem and found it was to do with the proxy. I fixed the problem using this command:

     git config --global http.proxy %HTTP_PROXY%
    
    0 讨论(0)
  • 2020-12-22 22:37

    check "git status" and "git pull" in the shell and find out what's wrong. and my problem is http.proxy node in config, therefore Github Windows should much more smart like just pop the shell and give more tips after the error(s) emit.

    0 讨论(0)
  • 2020-12-22 22:39

    This error comes because of a merge conflict in files. I faced it after I had updated my Maven Project's pom.xml but didn't commit it. Using

    git status
    error: Your local changes to the following files would be overwritten by merge:
    <my project>/pom.xml
    Please, commit your changes or stash them before you can merge.
    Aborting
    

    as the above post suggested helped finding any conflicting changes and you can decide to discard or commit.

    0 讨论(0)
  • 2020-12-22 22:42

    This error also occurs if the branch you're trying to sync has been deleted.

    git status won't tell you that, but you'll get a "no such ref was fetched" message if you try git pull.

    0 讨论(0)
  • 2020-12-22 22:46

    I had the same problem when I tried from inside Visual Studio and "git status" in shell showed no problem. But I managed to push the local changes with "git push" via shell.

    0 讨论(0)
  • 2020-12-22 22:46

    This is probably an edge case, but every time I've got this specific error it is because I've recently mapped a drive in Windows, and powershell cannot find it.

    A computer restart (of all things) fixes the error for me, as powershell can now pick up the newly mapped drive. Just make sure you connect to the mapped drive BEFORE opening the github client.

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