Understanding git branch all

て烟熏妆下的殇ゞ 提交于 2019-12-11 10:26:01

问题


What does the the arrow (->) mean here:

* development
  master
  production
  remotes/origin/HEAD -> origin/production
  remotes/origin/development
  remotes/origin/master
  remotes/origin/production

I'm just trying to get a real handle on git, so I'm diggin' deep and finding out that the further I go, the less I know about git, haha.


回答1:


remotes/origin/HEAD -> origin/production

means

remotes/origin/HEAD is pointing to origin/production


origin/HEAD is not a self-contained branch. It is just a pointer to the "main" branch, the one you get after a clone.

Try git symbolic-ref refs/heads/foo refs/heads/master. Afterwards git branch will show:

foo -> master

Then foo is just another name for master.



来源:https://stackoverflow.com/questions/22363543/understanding-git-branch-all

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