How to link external diff tool(beyond compare) in source tree?
Asked Answered
O

3

11

I am using Source tree client for Git on windows 7. I have used beyond compare with tortoisehg client for mercurial and I like to use Beyond compare itself as diff too in SourceTree too. I set the diff tool to beyond compare in Tools -> Options but not sure how to launch diff too via source tree for any file. Double click on file should usually bring up diff view. Right-click -> Custom action also does nothing.

Beyond compare 3.3.13 & source tree 2.1.2.5

Please let me know how to configure this.

Oedipus answered 20/6, 2017 at 13:44 Comment(0)
T
13

It works for me:

  1. After the installation, check whether you have set this in SourceTree options:

Beyond Compare Link with SourceTree

  1. Right click on the file(s) you want to compare and fire up Beyond Compare:

Firing up BeyondCompare Tool

Beyond Compare 4.2.2 & SourceTree 2.1.2.5

Also please make sure your Beyond Compare trial period has not ended

Typecast answered 22/6, 2017 at 1:36 Comment(6)
No, its a licenced copy. And first part i have done. And just realized it works as you said in point 2 for unstaged files. Thanks. But doesnt it work for already committed files or already pushed file lets say if i want diffs for file in old revision ??Oedipus
I'm afraid that you can't do that to already committed or pushed files. In a scenario when I get merge conflicts after applying a stash on the pulled files, I usually use Beyond Compare because in that case, the files are in the unstaged area. If you want to check the diffs for old revisions there's side-by-side diff in Bitbucket's site (assuming you are using Bitbucket for your repo)Typecast
Oh ok. I will use Bitbucket one itself then. In tortoiseHg, I was able to see diffs in beyond compare itself on double click even for older commits. Was rather nice and easy there. Thanks for the info. I accepted your answer above.Oedipus
@Oedipus Yes, Even I tried to do the same, but I couldn't do it on SourceTree. Thanks for accepting it, so it would be helpful for others as well :)Typecast
We can see diffs for already pushed commits also. Select the required file in pushed commit in Log/History section and click on the settings icon with drop down option on extreme right center of the window that is on the bar which has sorting options for files. Then select external Diff. It opens up in selected diffs tool.Oedipus
In any case, with the file selected, you can click Ctrl+DOsmose
S
1

In addition of the file compare/merge, I use the sourcetree custom actions in order to compare two commits as folder comparison.

Assuming git & beyond compare in the PATH, you can add this following custom action in Sourcetree (Tools > Option > Custom Actions):

Script: git
Parameters: difftool -d --tool=bc4 $SHA

Tested with Sourcetree 3.4.8, git 2.35, beyond compare 4.4.2

Secular answered 31/3, 2022 at 23:46 Comment(0)
H
0

The following worked for me in few easy steps:

  1. Configured git to use beyond control as the diff and merge tools as per official documentation. https://www.scootersoftware.com/support.php?zz=kb_vcs#gitwindows

  2. Setup sourcetree custom command enabling diff using Beyond compare by selecting two commits similar to TortoiseHG.

SourceTree->Tools->Options->Custom Actions

Script to run: git

Parameters: difftool --dir-diff $SHA

Heirdom answered 4/10, 2022 at 15:12 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.