What is HEAD in Git?

后端 未结 22 2014
野的像风
野的像风 2020-11-22 10:02

You see the Git documentation saying things like

The branch must be fully merged in HEAD.

But what is Git HEAD exac

22条回答
  •  无人及你
    2020-11-22 10:36

    A branch is actually a pointer that holds a commit ID such as 17a5. HEAD is a pointer to a branch the user is currently working on.

    HEAD has a reference filw which looks like this:

    ref:

    You can check these files by accessing .git/HEAD .git/refs that are in the repository you are working in.

提交回复
热议问题