Couldn't find remote ref HEAD in Git

倖福魔咒の 提交于 2019-12-03 08:01:59
VonC

Those settings allow git to know what to push to or what to pull from:

push the current branch to update a branch with the same name on the receiving end. Works in both central and non-central workflows.

It should only be:

git config --global push.default current

(I am not aware of that setting for pull)

I would recommend:

  • using the remote name instead of its url: origin
  • using a push with makes a tracking connection between your local and upstream branch:

So:

git push -u origin master
git pull origin

After that, a simple git push will be enough: see "Why do I need to explicitly push a new branch?" for more.

I tried this after push.

git config --global pull.default current
git config --global push.default current

I tried this command after i made pull..

Then when i pushed it it works.. Still i need to know the scene behind this ?

Really this is alone reason or ?

If someone figure it please give a reply..

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!