The `refs/master` and `refs/heads/master` will be two different references.
The `refs/heads/` directory (under the .git directory) contains the branches (by name). These can often be DWIMmed (Do What I Mean) on the command line by omitting the `refs/heads/` part when Git knows you will be typing a branch name. If the `refs/master` is really in the .git directory, then it is probably from some tool that has kept a special copy of a reference ... which then depends on what that support tool is. There is a potential that `refs/master` is a short name for `refs/heads/refs/master` and there has been finger trouble... So, check which files are really there in the .git/refs/ directory, and have a look at their contents (but do not change them! let Git do that) They should contain a single line of text, either a sha1 object ID, or a gitref pointing at another ref. Philip On Wednesday, August 12, 2020 at 6:36:42 PM UTC+1, Akshay Sarraf wrote: > > Hello All, > > > > This is my first question here, Hope I am using the right group. Please > correct me if I am wrong. > > Question : > > What is the difference between refs/master and refs/heads/master? > > When I run “git pull origin master” on git version 2.21.0.windows.1 it > points “refs/master” instead of “refs/heads/master”, If I run the same > command in version 2.28 it points to “refs/heads/master”. Why is it > pointing to “refs/master” in 2.21? > > > > “refs/master” is not a branch on my repo, I am not sure what it is. How > can I locate it? > > > > Thank You > > Akshay > -- You received this message because you are subscribed to the Google Groups "Git for human beings" group. To unsubscribe from this group and stop receiving emails from it, send an email to git-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/git-users/6ab8c830-5918-4f84-a487-80991814e653o%40googlegroups.com.