git pull displays “fatal: Couldn't find remote ref refs/heads/xxxx” and hangs up

前端 未结 9 915
醉话见心
醉话见心 2021-01-31 06:58

I created a branch called \'6796\', then I pushed it to remote, checked it out on another machine, made other edits, pushed it, then merged it with the master, and deleted it -

9条回答
  •  时光说笑
    2021-01-31 07:22

    This error could be thrown in the following situation as well.

    You want to checkout branch called feature from remote repository but the error is thrown because you already have branch called feature/ in your local repository.

    Simply checkout the feature branch under a different name:

    git checkout -b  /feature
    

提交回复
热议问题