Compare ext: Setting different path to compare tool?

Advertisement

Pathduck
Donor
Pathduck avatar
Joined:
Posts:
83
Location:
Oslo

Compare ext: Setting different path to compare tool?

Hello!
I like the new file comparison extension - I've been using something similar as a custom command for years, but this is more elegant.

I have WinMerge installed as a portable application, and I thought maybe WinSCP would look in the registry to find the install path. However, looking at the code for the extension, it appears to expect the tool to be installed in the directory specified by %PF%. I assume this is the WinSCP directory, and we would install the tools in sub-folders there.

I have hacked the file to give the full path to WinMerge - however, it's not elegant. Is there another way to specify this path?

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
32,072
Location:
Prague, Czechia

Re: Compare ext: Setting different path to compare tool?

OK, I'll consider that.
Though:
The scripts looks for Program Files\WinMerge (or Program Files (x86)) (not WinSCP folder).
If you do not want to copy your portable WinMerge there, you can create a directory junction from Program Files\WinMerge to your "portable" location.

Reply with quote

Pathduck
Donor
Pathduck avatar
Joined:
Posts:
83
Location:
Oslo

Thanks for your reply Martin, as always very clear :)

No need to think too much about it - for me it works now and anyway I usually use the portable version so my hacked compare script won't get overwritten on update. Creating a link is a good idea though.

Maybe a solution would be to have it in the ini, by default blank, and uses either Program Files or WinSCP sub-directory. Then let advanced users edit if they want.

[Configuration\CustomCommandOptions]
commonext\CompareFiles\Tool=WinMerge
commonext\CompareFiles\ToolPath=d:\bin\winmerge

Oh, and won't most compare tools behave the same? I.e. "tool.exe %file1% %file2%" ? So what tool used should not matter, just the path to a compare binary.

Reply with quote

Advertisement

You can post new topics in this forum