Git error on git pull (unable to update local ref)

后端 未结 18 1913
鱼传尺愫
鱼传尺愫 2020-12-12 11:25

I only have branch master and im getting this error every time i try to \"git pull\":

error: Couldn\'t set refs/remotes/origin/master
From /var/lib/git/xxx/p         


        
18条回答
  •  旧时难觅i
    2020-12-12 12:22

    What happened over here? The local references to your remote branches were changed and hence when you run git pull, git doesn't find any corresponding remote branches and hence it fails.

    git remote prune origin
    

    actually cleans this local references and then run git pull again.

    Suggestion - Please run with --dry-run option for safety

提交回复
热议问题