Git: refname 'master' is ambiguous

后端 未结 3 1999
故里飘歌
故里飘歌 2020-12-04 18:59

I\'ve looked at all of the other ambiguous refname questions and none of them seem to help. Why am I getting this warning?

$ git checkout master
warning: ref         


        
3条回答
  •  孤城傲影
    2020-12-04 19:53

    Although this doesn't apply to the OP's situation, I got myself a refname is ambiguous warning after accidentally doing a git branch origin/branch instead of a git checkout origin/branch. This created a local branch named origin/branch, which made it ambiguous with the remote branch. Solving the problem was as simple as git branch -D origin/branch (safe because -D operates on local branches).

提交回复
热议问题