Search code examples
gitfetchbranchpull

Where is the fetched branch stored after a successful git pull?


When I execute a git pull is the fetched branch stored anywhere in my local repository? If yes, how can I reference its contents? If it is not, is there a way to make git pull do so?

I understand that I can use git fetch and git merge to achieve this. However, for reasons not worth mentioning here it would be really helpful to us if we could achieve the same using git pull.

Thank you for your help.


Solution

  • The keyword to reference the fetched commitid is FETCH_HEAD.