开发者

Is there a quick way to see if a commit hash is in a particular tree's history?

Can I compare a commit to a branch and see if ther开发者_StackOverflow社区e is a diff, or just get a yes / no answer to the question somehow?


If a commit is on a branch's history then this list of commits will be empty, otherwise there will be at least one commit (the given commit).

git rev-list <branch_id>..<commit_id>


Ah:

git log <commit hash>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜