How to find last merge in git?

后端 未结 7 1418
野的像风
野的像风 2020-12-29 04:31

For a web site, I have master and staging, I have worked on staging for about 10 days. How do I tell for sure what has changed since my last merge, or when that merge was? M

7条回答
  •  别那么骄傲
    2020-12-29 04:54

    It looks like you don't really want to know what is changed since last merge, but what have I on branch staging that is not yet on branch master? (or the other way around). If so, look at the command git cherry.

    Though I must confess I never used this command because of the output format, which is not really helpful. Maybe there is a way to feed this output to git log/git show or such.


    Edit: As I understand, you don't need a tag to use git whatchanged. Try simply git whatchanged master..staging to see what changed on staging since you last merged from staging to master.

提交回复
热议问题