Is there a way to get a visual diff on two branches in SourceTree?

时光怂恿深爱的人放手 提交于 2019-12-02 15:40:57
Anton Glukhov

Use (OSX) or CTRL (Windows and Linux) and choose any two commits you like in log view. It does not matter what branch the commits belong to.

As a result you will see something like...

Displaying all changes between f03a18bf0370c62bb5fb5c6350589ad8def13aea and 4a4b176b852e7c8e83fffe94ea263042c59f0548

...down below.

Gan

Another way to do this is to right-click on a branch and select the "Diff against current" context menu command (current refers to the branch you are currently working on). This will give you the diff between the head commits of the two branches.

Source: https://answers.atlassian.com/questions/167126/sourcetree-diff-against-current-behavior#

Screenshot (based on Sourcetree v1.9.5):

After choosing "Diff against Current" from the context menu, you should see a message to the effect of:

Displaying all changes between {commit_hash} and working copy

Taran

You can also do this by ctrl + clicking the two branches commits you want to diff.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!