How do I get the id of the last push in git?

I would like to get the id for the received last click (not git rev-parse HEAD

).

For example, if I do git diff-tree --name-status master

, it will show me all the changes since the last click, but I want to see the changes on a specific click.

+3


source to share


1 answer


If you are talking about the last push you (i.e. your repo) received from a given remote, for a given branch (e.g. master):

 git rev-parse origin/master

      

(this blog post illustrates it by listing the changes since the last click:
git log origin/master.. --stat



The command is also used in the question " git wrongly states that I am ahead of start / master by 1 commit )

Once you have the correct SHA1, you can look at " How can I see all the files that were changed / added / removed in the received last pushed? " For more.

+4


source







All Articles